Hello community,

here is the log from the commit of package ghc for openSUSE:Factory checked in 
at 2015-09-24 06:15:16
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/ghc (Old)
 and      /work/SRC/openSUSE:Factory/.ghc.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "ghc"

Changes:
--------
--- /work/SRC/openSUSE:Factory/ghc/ghc.changes  2015-08-23 17:38:38.000000000 
+0200
+++ /work/SRC/openSUSE:Factory/.ghc.new/ghc.changes     2015-09-24 
06:15:20.000000000 +0200
@@ -1,0 +2,7 @@
+Sun Sep 20 16:30:09 UTC 2015 - [email protected]
+
+- remove llvm from requires
+- add ncurses6.patch to fix build with ncurses6, all thanks goes to 
+  Tomas Cech - [email protected]
+
+-------------------------------------------------------------------

New:
----
  ncurses6.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ ghc.spec ++++++
--- /var/tmp/diff_new_pack.DRaMj4/_old  2015-09-24 06:15:21.000000000 +0200
+++ /var/tmp/diff_new_pack.DRaMj4/_new  2015-09-24 06:15:21.000000000 +0200
@@ -34,9 +34,11 @@
 BuildRequires:  gmp-devel
 BuildRequires:  libelf-devel
 BuildRequires:  libffi-devel
-%ifnarch ppc aarch64
-BuildRequires:  llvm
-%endif
+#TODO ghc-7.10.2 supports only llvm-3.5, need talk with llvm packagers about 
+# versioned build of llvm
+#%%ifnarch ppc aarch64
+#BuildRequires:  llvm
+#%%endif
 BuildRequires:  ncurses-devel
 BuildRequires:  pkg-config
 BuildRequires:  xz
@@ -63,6 +65,8 @@
 Patch19:        0001-implement-native-code-generator-for-ppc64.patch
 # PATCH-FIX-UPSTREAM [email protected] -- GNU ld does not work 
with ghc on aarch64 so use Gold. Adapted from Fedora patch 24.
 Patch23:        ghc-7.8-arm-use-ld-gold.patch
+# PATCH-FIX-OPENSUSE [email protected] -- ncurses6 doesn't export cur_term function
+Patch24:           ncurses6.patch
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
 
@@ -153,6 +157,9 @@
 %prep
 %setup -q
 %patch19 -p1
+%if 0%{?suse_version} > 1320
+%patch24 -p1
+%endif 
 
 #%%ifarch armv7hl aarch64
 #%%patch23 -p1 -b .24~

++++++ ncurses6.patch ++++++
Index: ghc-7.10.2/libraries/terminfo/System/Console/Terminfo/Base.hs
===================================================================
--- ghc-7.10.2.orig/libraries/terminfo/System/Console/Terminfo/Base.hs
+++ ghc-7.10.2/libraries/terminfo/System/Console/Terminfo/Base.hs
@@ -63,7 +63,7 @@ import Data.Typeable
 data TERMINAL
 newtype Terminal = Terminal (ForeignPtr TERMINAL)
 
-foreign import ccall "&" cur_term :: Ptr (Ptr TERMINAL)
+foreign import ccall "&" _nc_cur_term :: Ptr (Ptr TERMINAL)
 foreign import ccall set_curterm :: Ptr TERMINAL -> IO (Ptr TERMINAL)
 foreign import ccall "&" del_curterm :: FunPtr (Ptr TERMINAL -> IO ())
 
@@ -73,7 +73,7 @@ foreign import ccall setupterm :: CStrin
 -- 
 -- Throws a 'SetupTermError' if the terminfo database could not be read.
 setupTerm :: String -> IO Terminal
-setupTerm term = bracket (peek cur_term) (poke cur_term) $ \_ -> 
+setupTerm term = bracket (peek _nc_cur_term) (poke _nc_cur_term) $ \_ -> 
     withCString term $ \c_term ->
     with 0 $ \ret_ptr -> do
         -- NOTE: I believe that for the way we use terminfo
@@ -85,7 +85,7 @@ setupTerm term = bracket (peek cur_term)
         terminal names are the same).  This prevents problems
         when calling del_term on a struct shared by more than one
         Terminal. --}
-        poke cur_term nullPtr
+        poke _nc_cur_term nullPtr
         -- Call setupterm and check the return value.
         setupterm c_term stdOutput ret_ptr
         ret <- peek ret_ptr
@@ -93,7 +93,7 @@ setupTerm term = bracket (peek cur_term)
             then throwIO $ SetupTermError
                 $ "Couldn't look up terminfo entry " ++ show term
             else do
-                cterm <- peek cur_term
+                cterm <- peek _nc_cur_term
                 fmap Terminal $ newForeignPtr del_curterm cterm
 
 data SetupTermError = SetupTermError String
@@ -120,7 +120,7 @@ setupTermFromEnv = do
 -- TODO: this isn't really thread-safe...
 withCurTerm :: Terminal -> IO a -> IO a
 withCurTerm (Terminal term) f = withForeignPtr term $ \cterm -> do
-        old_term <- peek cur_term
+        old_term <- peek _nc_cur_term
         if old_term /= cterm
             then do
                     _ <- set_curterm cterm

Reply via email to