tags 536959 + pending
thanks

Dear maintainer,

I've prepared an NMU for helium (versioned as 1.6-4.1) and uploaded it
to DELAYED/2, according to devref §5.11.1. The patch ports readline
support to the editline library and has been contributed by Chris Lamb
in this bug log (thanks to him!).

Cheers.

-- 
Stefano Zacchiroli -o- PhD in Computer Science \ PostDoc @ Univ. Paris 7
z...@{upsilon.cc,pps.jussieu.fr,debian.org} -<>- http://upsilon.cc/zack/
Dietro un grande uomo c'è ..|  .  |. Et ne m'en veux pas si je te tutoie
sempre uno zaino ...........| ..: |.... Je dis tu à tous ceux que j'aime
diff -u helium-1.6/debian/patches/03_add-readline-support.dpatch helium-1.6/debian/patches/03_add-readline-support.dpatch
--- helium-1.6/debian/patches/03_add-readline-support.dpatch
+++ helium-1.6/debian/patches/03_add-readline-support.dpatch
@@ -13,7 +13,7 @@
  endif
  HC_OPTS = -static -fglasgow-exts -fallow-undecidable-instances -fallow-overlapping-instances \
 -		$(PACKAGENET) -package lang -package text -i$(IFACES) $(EXTRA_HC_OPTS)
-+		$(PACKAGENET) -package lang -package text -package readline -i$(IFACES) $(EXTRA_HC_OPTS)
++		$(PACKAGENET) -package lang -package text -package editline -i$(IFACES) $(EXTRA_HC_OPTS)
  
  AG      = @WithAG@
  AG_OPTS = -mscfr
@@ -24,27 +24,24 @@
  import Monad(when)
  import IO(stdout, hFlush)
  import System(system, getEnv, getArgs, exitWith, ExitCode(..))  
-+import System.Console.SimpleLineEditor(initialise,restore,getLineEdited)
++import qualified System.Console.Editline.Readline as RL
  import OSSpecific(slash)
  import Directory
- 
-@@ -75,8 +76,14 @@
+
+@@ -75,8 +76,11 @@
          else
              return initialState
              
 -    -- Enter read-eval-print loop            
-+    -- Initialize readline
-+    initialise
++    -- Initialize editline
++    RL.initialize
 +
 +    -- Enter read-eval-print loop 
      loop stateAfterLoad
-+
-+    -- Restore normal terminal behaviour
-+    restore
      
      return ()
- 
-@@ -89,21 +96,21 @@
+
+@@ -89,21 +89,24 @@
  
  loop :: State -> IO State
  loop state = do
@@ -52,11 +49,12 @@
 -    hFlush stdout
 -    command' <- getLine
 -    let command = trim command'
-+    command' <- getLineEdited (prompt state)
++    command' <- RL.readline (prompt state)
 +    let command = fmap trim command'
      newState <- case command of
 -        (':':cmd:rest) -> 
-+        (Just (':':cmd:rest)) -> 
++        (Just (':':cmd:rest)) -> do
++            RL.addHistory (':':cmd:rest)
              processCommand (toLower cmd) (trim rest) state
 -        (':':_) -> do
 +        (Just (':':_)) -> do
@@ -69,7 +67,11 @@
-                 else processExpression expression state
+-                else processExpression expression state
++                else do
++                    RL.addHistory expression
++                    processExpression expression state
              return state
 +        (Nothing) -> do
-+            return state
++            do return state
      loop newState
    where
      prompt :: State -> String
+
diff -u helium-1.6/debian/patches/04_fixes-for-ghc6.dpatch helium-1.6/debian/patches/04_fixes-for-ghc6.dpatch
--- helium-1.6/debian/patches/04_fixes-for-ghc6.dpatch
+++ helium-1.6/debian/patches/04_fixes-for-ghc6.dpatch
@@ -49,8 +49,8 @@
  PACKAGENET = 
  endif
  HC_OPTS = -static -fglasgow-exts -fallow-undecidable-instances -fallow-overlapping-instances \
--		$(PACKAGENET) -package lang -package text -package readline -i$(IFACES) $(EXTRA_HC_OPTS)
-+		$(PACKAGENET) -package containers -package mtl -package parsec -package readline -i$(IFACES) $(EXTRA_HC_OPTS)
+-		$(PACKAGENET) -package lang -package text -package editline -i$(IFACES) $(EXTRA_HC_OPTS)
++		$(PACKAGENET) -package containers -package mtl -package parsec -package editline -i$(IFACES) $(EXTRA_HC_OPTS)
  
  AG      = @WithAG@
  AG_OPTS = -mscfr
diff -u helium-1.6/debian/changelog helium-1.6/debian/changelog
--- helium-1.6/debian/changelog
+++ helium-1.6/debian/changelog
@@ -1,3 +1,11 @@
+helium (1.6-4.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Switch to System.Console.Editline.Readline for readline capabilities,
+    fixes FTBFS. Patch by Chris Lamb. (Closes: #536959)
+
+ -- Stefano Zacchiroli <z...@debian.org>  Fri, 09 Oct 2009 10:51:27 +0200
+
 helium (1.6-4) unstable; urgency=low
   
   * Make helium compile with GHC 6.8.2:
diff -u helium-1.6/debian/control helium-1.6/debian/control
--- helium-1.6/debian/control
+++ helium-1.6/debian/control
@@ -3,7 +3,7 @@
 Priority: optional
 Maintainer: Arjan Oosting <ar...@debian.org>
 Build-Depends: autotools-dev, debhelper (>= 5), dpatch, 
- ghc6 (>= 6.8.2), haddock, libghc6-mtl-dev, libghc6-parsec-dev, uuagc
+ ghc6 (>= 6.8.2), haddock, libghc6-mtl-dev, libghc6-parsec-dev, uuagc, libghc6-editline-dev
 Standards-Version: 3.7.3
 Vcs-Svn: svn://svn.debian.org/svn/pkg-haskell/packages/helium
 Vcs-Browser: http://svn.debian.org/wsvn/pkg-haskell/packages/helium

Reply via email to