summaryrefslogtreecommitdiff
path: root/p/c2hs
diff options
context:
space:
mode:
authorJoachim Breitner <mail@joachim-breitner.de>2010-04-23 16:29:36 +0400
committerJoachim Breitner <mail@joachim-breitner.de>2010-04-23 16:29:36 +0400
commit18013a97475e12dabe5fdeab576f03960db7804f (patch)
tree10715b29dbe50e84d9063ed6dc6042dd9fe8d0cb /p/c2hs
parentec945cfda25e62bd37fdb698ef3bcf956b436e91 (diff)
downloadDHG_packages-18013a97475e12dabe5fdeab576f03960db7804f.tar.gz
c2hs: Remove patch 04_ghc6-6.12.diff
Diffstat (limited to 'p/c2hs')
-rw-r--r--p/c2hs/debian/changelog1
-rw-r--r--p/c2hs/debian/patches/04_ghc6-6.12.diff99
-rw-r--r--p/c2hs/debian/patches/series1
3 files changed, 1 insertions, 100 deletions
diff --git a/p/c2hs/debian/changelog b/p/c2hs/debian/changelog
index 880ea3563..0c30f4b31 100644
--- a/p/c2hs/debian/changelog
+++ b/p/c2hs/debian/changelog
@@ -7,6 +7,7 @@ c2hs (0.16.2-1) UNRELEASED; urgency=low
[ Joachim Breitner ]
* New upstream release.
+ * Remove patch 04_ghc6-6.12.diff
-- Joachim Breitner <nomeata@debian.org> Fri, 23 Apr 2010 14:27:03 +0200
diff --git a/p/c2hs/debian/patches/04_ghc6-6.12.diff b/p/c2hs/debian/patches/04_ghc6-6.12.diff
deleted file mode 100644
index d59d41b4d..000000000
--- a/p/c2hs/debian/patches/04_ghc6-6.12.diff
+++ /dev/null
@@ -1,99 +0,0 @@
-# Description: Patch to work with ghc6-6.12
-# This patch was based on a patch by Duncan Coutts for the internal c2hs of
-# gtk2hs. It's available at
-# http://sourceforge.net/mailarchive/forum.php?thread_name=1260471581.13548.13986.camel%40localhost&forum_name=gtk2hs-devel .
-# Bug-Debian: 569411
-# Forwarded: http://haskell.org/pipermail/c2hs/2010-February/000993.html
-# Author: Marco TĂșlio Gontijo e Silva <marcot@debian.org>
-# Last-Update: 2010-02-12
-Index: c2hs-0.16.0/src/C2HS/C/Info.hs
-===================================================================
---- c2hs-0.16.0.orig/src/C2HS/C/Info.hs 2010-02-12 16:04:15.000000000 -0200
-+++ c2hs-0.16.0/src/C2HS/C/Info.hs 2010-02-12 16:04:38.000000000 -0200
-@@ -114,7 +114,7 @@
- size CULLongPT = Storable.sizeOf (undefined :: CLLong)
- size CFloatPT = Storable.sizeOf (undefined :: CFloat)
- size CDoublePT = Storable.sizeOf (undefined :: CDouble)
--size CLDoublePT = Storable.sizeOf (undefined :: CLDouble)
-+--size CLDoublePT = Storable.sizeOf (undefined :: CLDouble)
- size (CSFieldPT bs) = -bs
- size (CUFieldPT bs) = -bs
-
-@@ -139,7 +139,7 @@
- alignment CULLongPT = return $ Storable.alignment (undefined :: CULLong)
- alignment CFloatPT = return $ Storable.alignment (undefined :: CFloat)
- alignment CDoublePT = return $ Storable.alignment (undefined :: CDouble)
--alignment CLDoublePT = return $ Storable.alignment (undefined :: CLDouble)
-+--alignment CLDoublePT = return $ Storable.alignment (undefined :: CLDouble)
- alignment (CSFieldPT bs) = fieldAlignment bs
- alignment (CUFieldPT bs) = fieldAlignment bs
-
-Index: c2hs-0.16.0/src/C2HS/Gen/Bind.hs
-===================================================================
---- c2hs-0.16.0.orig/src/C2HS/Gen/Bind.hs 2010-02-12 16:05:16.000000000 -0200
-+++ c2hs-0.16.0/src/C2HS/Gen/Bind.hs 2010-02-12 16:06:40.000000000 -0200
-@@ -793,10 +793,12 @@
- --
- foreignImport :: String -> String -> String -> Bool -> ExtType -> String
- foreignImport header ident hsIdent isUnsafe ty =
-- "foreign import ccall " ++ safety ++ " " ++ show (header ++ " " ++ ident) ++
-+ "foreign import ccall " ++ safety ++ " " ++ show entity ++
- "\n " ++ hsIdent ++ " :: " ++ showExtType ty ++ "\n"
- where
- safety = if isUnsafe then "unsafe" else "safe"
-+ entity | null header = ident
-+ | otherwise = header ++ " " ++ ident
-
- -- | Haskell code for the foreign import dynamic declaration needed by a call hook
- --
-Index: c2hs-0.16.0/src/System/CIO.hs
-===================================================================
---- c2hs-0.16.0.orig/src/System/CIO.hs 2010-02-12 15:58:34.000000000 -0200
-+++ c2hs-0.16.0/src/System/CIO.hs 2010-02-12 16:03:27.000000000 -0200
-@@ -1,3 +1,5 @@
-+{-# LANGUAGE CPP #-}
-+{-# OPTIONS_GHC -cpp #-}
- -- Compiler Toolkit: Compiler I/O
- --
- -- Author : Manuel M T Chakravarty
-@@ -63,7 +63,7 @@
- )
- where
-
--import Prelude (Bool, Char, String, FilePath, (.), Show)
-+import Prelude (Bool, Char, String, FilePath, (.), ($), Show, return)
- import qualified System.IO as IO
- import qualified System.Directory as IO (doesFileExist, removeFile)
- import qualified System.Environment as IO (getArgs, getProgName)
-@@ -75,7 +77,12 @@
- -- -------------
-
- openFile :: FilePath -> IO.IOMode -> PreCST e s IO.Handle
--openFile p m = liftIO (IO.openFile p m)
-+openFile p m = liftIO $ do
-+ hnd <- IO.openFile p m
-+#if __GLASGOW_HASKELL__ >= 612
-+ IO.hSetEncoding hnd IO.latin1
-+#endif
-+ return hnd
-
- hClose :: IO.Handle -> PreCST e s ()
- hClose h = liftIO (IO.hClose h)
-@@ -99,10 +106,15 @@
- hPutStrLn h s = liftIO (IO.hPutStrLn h s)
-
- writeFile :: FilePath -> String -> PreCST e s ()
--writeFile fname contents = liftIO (IO.writeFile fname contents)
-+writeFile fname contents = do
-+ hnd <- openFile fname IO.WriteMode
-+ hPutStr hnd contents
-+ hClose hnd
-
- readFile :: FilePath -> PreCST e s String
--readFile fname = liftIO (IO.readFile fname)
-+readFile fname = do
-+ hnd <- openFile fname IO.ReadMode
-+ liftIO (IO.hGetContents hnd)
-
- print :: Show a => a -> PreCST e s ()
- print a = liftIO (IO.print a)
diff --git a/p/c2hs/debian/patches/series b/p/c2hs/debian/patches/series
index 8143e1f14..2493b13c4 100644
--- a/p/c2hs/debian/patches/series
+++ b/p/c2hs/debian/patches/series
@@ -1,4 +1,3 @@
01_fix-stylesheet-path-for-debian.diff
02_fix-docbookx-dtd.diff
03_fix-man-page.diff
-04_ghc6-6.12.diff