failed when trying to compile FranTk with ghc
Jan Kort
kort@science.uva.nl
Mon, 09 Apr 2001 11:01:08 +0200
luc wrote:
>
> I tried FranTk with ghc 4.08 and got :
> (this is the "fixed" FrankTk, alledged working with 4.06, if im not
> wrong)
>
> are there any difference with 4.06 and 4.08 ?
Below is a list of fixes to get FranTk working with ghc4.08.
Jan
Run configure like normal, i.e.:
./configure --prefix=/scratch/kort/pkgs/frantk
Change the file FranTk/src/FranSrc/Compatibility.ghc.hs to
========================================================================
-- this module is for GHC; GSL
module Compatibility
( double2Float
, yield
, debugMsgLn
, setDebug
, mkWeakIORef
, toInt
, fromInt
) where
import GlaExts
import NumExts(doubleToFloat)
import PrelRead(readDec)
import IOExts
import Concurrent
import Exception
double2Float = doubleToFloat
setDebug :: Bool -> IO ()
setDebug _ = return ()
debugMsgLn :: String -> IO ()
debugMsgLn s = assert (trace s `seq` True) $ return ()
========================================================================
In the file FranTk/src/FranTkSrc/Makefile change the line:
HC_OPTS+= -i../FranSrc:../TclHaskellSrc -fallow-overlapping-instances -fallow-undecidable-instances
-syslib misc
to:
HC_OPTS+= -i../FranSrc:../TclHaskellSrc -fallow-overlapping-instances -fallow-undecidable-instances
-syslib data
In the file FranTk/demos/Makefile change the line:
HC_OPTS+= -i../src/FranTkSrc:../src/FranSrc:../src/TclHaskellSrc -fallow-overlapping-instances
-fallow-undecidable-instances -syslib misc
to:
HC_OPTS+= -i../src/FranTkSrc:../src/FranSrc:../src/TclHaskellSrc -fallow-overlapping-instances
-fallow-undecidable-instances -syslib data
If the compiler complains about not finding the file "tcl.h", in the
file FranTk/src/TclHaskellSrc/Makefile change the rule:
tclhaskell.o: tclhaskell.c tclhaskell.h
$(HC) -c tclhaskell.c
to:
tclhaskell.o: tclhaskell.c tclhaskell.h
$(HC) -I/opt/arch/lib/tk8.3/include -c tclhaskell.c
where /opt/arch... is the place "tcl.h" and "tk.h" are.
In the directory FranTk/src/TclHaskellSrc do:
rm *.hi *.o
In the file FranTk/src/TclHaskellSrc/Makefile add TclPrim.hs to
the HS_SRCS list.
In the directory FranTk/src/FranSrc do:
rm *.hi
In the directory FranTk/demos do:
rm *.hi
And then continue the normal installation with:
gmake boot
gmake all