Page MenuHomeFreeBSD

D12043.1794436503.diff
No OneTemporary

Authored By
Unknown
Size
4 KB
Referenced Files
None
Subscribers
None

D12043.1794436503.diff

Index: devel/hs-c2hs/files/patch-src_C2HS_Config.hs
===================================================================
--- devel/hs-c2hs/files/patch-src_C2HS_Config.hs
+++ devel/hs-c2hs/files/patch-src_C2HS_Config.hs
@@ -23,8 +23,8 @@
("openbsd","cpp") -> ["-xc"]
- (_,"cpp") -> ["-x", "c"]
- (_,"gcc") -> ["-E", "-x", "c"]
-+ (_,"cpp") -> ["-x", "c", "-std=c99"]
-+ (_,"gcc") -> ["-E", "-x", "c", "-std=c99"]
++ (_,"cpp") -> ["-x", "c"]
++ (_,"gcc") -> ["-E", "-x", "c"]
_ -> []
-- | C2HS Library file name
Index: devel/hs-ncurses/files/patch-lib_UI_NCurses.chs
===================================================================
--- /dev/null
+++ devel/hs-ncurses/files/patch-lib_UI_NCurses.chs
@@ -0,0 +1,26 @@
+--- lib/UI/NCurses.chs.orig 2016-08-29 01:09:37 UTC
++++ lib/UI/NCurses.chs
+@@ -435,12 +435,12 @@ setColor (ColorID pair) = withWindow_ "s
+ -- | Add some text to the window, at the current cursor position.
+ drawString :: String -> Update ()
+ drawString str = withWindow_ "drawString" $ \win ->
+- withCWString str ({# call waddwstr #} win)
++ withCWString str $ \s -> ({# call waddwstr #} win) (castPtr s)
+
+ -- | Add some text to the window, at the current cursor position.
+ drawText :: T.Text -> Update ()
+ drawText txt = withWindow_ "drawText" $ \win ->
+- withCWString (T.unpack txt) ({# call waddwstr #} win)
++ withCWString (T.unpack txt) $ \s -> ({# call waddwstr #} win) (castPtr s)
+
+ drawGlyph :: Glyph -> Update ()
+ drawGlyph glyph = withWindow_ "drawGlyph" $ \win ->
+@@ -718,7 +718,7 @@ withGlyph (Glyph char attrs) io =
+ let cAttrs = foldl' (\acc a -> acc .|. attrToInt a) 0 attrs in
+ withCWStringLen [char] $ \(cChars, cCharsLen) ->
+ allocaBytes {# sizeof cchar_t #} $ \pBuf -> do
+- {# call hsncurses_init_cchar_t #} (CCharT pBuf) cAttrs cChars (fromIntegral cCharsLen)
++ {# call hsncurses_init_cchar_t #} (CCharT pBuf) cAttrs (castPtr cChars) (fromIntegral cCharsLen)
+ io (CCharT pBuf)
+
+ -- | Upper left corner
Index: lang/ghc/Makefile
===================================================================
--- lang/ghc/Makefile
+++ lang/ghc/Makefile
@@ -99,7 +99,7 @@
# https://ghc.haskell.org/trac/ghc/wiki/Commentary/Compiler/Backends/LLVM/Installing
# We should however investigate whether base's clang is enough to build ghc&co.
# This will likely require some modifications to compiler/main/*hs
-USE_GCC= yes
+#USE_GCC= yes
CONFIGURE_ARGS+= -with-gcc=${CC}
.if empty(PORT_OPTIONS:MBOOT)
CONFIGURE_ARGS_BOOT+= --with-gcc=${CC}
Index: lang/ghc/bsd.cabal.mk
===================================================================
--- lang/ghc/bsd.cabal.mk
+++ lang/ghc/bsd.cabal.mk
@@ -101,7 +101,7 @@
# So for now, stick to GCC -- this might change with ghc-8.4.
# https://ghc.haskell.org/trac/ghc/wiki/Commentary/Compiler/Backends/LLVM/Installing
# We should however investigate whether base's clang is enough to build ghc&co.
-USE_GCC= yes
+#USE_GCC= yes
CONFIGURE_ARGS+= --with-gcc=${CC} --with-ld=${LD} --with-ar=${AR}
Index: lang/ghc/files/patch-compiler_main_SysTools.hs
===================================================================
--- /dev/null
+++ lang/ghc/files/patch-compiler_main_SysTools.hs
@@ -0,0 +1,12 @@
+--- compiler/main/SysTools.hs.orig 2017-08-12 09:25:57 UTC
++++ compiler/main/SysTools.hs
+@@ -907,6 +907,9 @@ getCompilerInfo' dflags = do
+ -- Regular clang
+ | any ("clang version" `isInfixOf`) stde =
+ return Clang
++ -- FreeBSD clang
++ | any ("FreeBSD clang version" `isInfixOf`) stde =
++ return Clang
+ -- XCode 5.1 clang
+ | any ("Apple LLVM version 5.1" `isPrefixOf`) stde =
+ return AppleClang51
Index: lang/ghc/files/patch-rts_Linker.c
===================================================================
--- /dev/null
+++ lang/ghc/files/patch-rts_Linker.c
@@ -0,0 +1,11 @@
+--- rts/Linker.c.orig 2017-08-12 09:22:13 UTC
++++ rts/Linker.c
+@@ -797,7 +797,7 @@ initLinker_ (int retain_cafs)
+ # endif /* RTLD_DEFAULT */
+
+ compileResult = regcomp(&re_invalid,
+- "(([^ \t()])+\\.so([^ \t:()])*):([ \t])*(invalid ELF header|file too short)",
++ "(([^ \t()])+\\.so([^ \t:()])*):([ \t])*(invalid ELF header|file too short|invalid file format)",
+ REG_EXTENDED);
+ if (compileResult != 0) {
+ barf("Compiling re_invalid failed");

File Metadata

Mime Type
text/plain
Expires
Wed, Nov 11, 10:35 PM (4 h, 20 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
41666705
Default Alt Text
D12043.1794436503.diff (4 KB)

Event Timeline