diff options
author | Oliver Braun <obraun@FreeBSD.org> | 2003-10-21 21:56:23 +0000 |
---|---|---|
committer | Oliver Braun <obraun@FreeBSD.org> | 2003-10-21 21:56:23 +0000 |
commit | fd737c39b74109bc718e40b7eb06bfc014b0f5cf (patch) | |
tree | d2d370dbc3f13dc2e93e1248a63f8a501e456386 /devel/hs-tclhaskell-ghc | |
parent | 6bfe18a3d28138c8deb3d620f66194758e7091e4 (diff) | |
download | ports-fd737c39b74109bc718e40b7eb06bfc014b0f5cf.tar.gz ports-fd737c39b74109bc718e40b7eb06bfc014b0f5cf.zip |
Notes
Diffstat (limited to 'devel/hs-tclhaskell-ghc')
-rw-r--r-- | devel/hs-tclhaskell-ghc/Makefile | 29 | ||||
-rw-r--r-- | devel/hs-tclhaskell-ghc/files/patch-TclPrimGhc.hs | 11 | ||||
-rw-r--r-- | devel/hs-tclhaskell-ghc/pkg-install.in | 4 |
3 files changed, 36 insertions, 8 deletions
diff --git a/devel/hs-tclhaskell-ghc/Makefile b/devel/hs-tclhaskell-ghc/Makefile index 024cedd6fc7d..c25928ced294 100644 --- a/devel/hs-tclhaskell-ghc/Makefile +++ b/devel/hs-tclhaskell-ghc/Makefile @@ -4,8 +4,9 @@ # # $FreeBSD$ -PORTNAME= tclhaskell-ghc +PORTNAME= tclhaskell PORTVERSION= 1.2 +PORTREVISION= 1 CATEGORIES= devel haskell tcl83 MASTER_SITES= http://www.dcs.gla.ac.uk/~meurig/TclHaskell/ PKGNAMEPREFIX= hs- @@ -14,20 +15,36 @@ DISTNAME= TclHaskell1_2 MAINTAINER= stolz@i2.informatik.rwth-aachen.de COMMENT= Tcl/Tk binding for Haskell +.if defined(WITH_GHC5) +GHC= ghc-5.04.3 +GHCDEP= ghc +.else +GHC= ghc-6.0.1 +GHCDEP= ghc6 +.endif +PKGNAMESUFFIX= -${GHCDEP} + LIB_DEPENDS= tk83.1:${PORTSDIR}/x11-toolkits/tk83 -BUILD_DEPENDS= ghc:${PORTSDIR}/lang/ghc -RUN_DEPENDS= ghc:${PORTSDIR}/lang/ghc +BUILD_DEPENDS= ${GHC}:${PORTSDIR}/lang/${GHCDEP} +RUN_DEPENDS= ${GHC}:${PORTSDIR}/lang/${GHCDEP} WRKSRC= ${WRKDIR}/TclHaskell1.2/src USE_GMAKE= YES USE_REINPLACE= YES -GHC_VERSION= `${LOCALBASE}/bin/ghc --numeric-version` -GHC_LIB= ${LOCALBASE}/lib/ghc-${GHC_VERSION} +GHC_VERSION= `${LOCALBASE}/bin/${GHC} --numeric-version` +GHC_LIB= ${LOCALBASE}/lib/${GHC} PLIST_SUB+= GHC_VERSION="${GHC_VERSION}" PKGINSTALL= ${WRKDIR}/pkg-install MAKE_ENV+= INSTALL_DATA="${INSTALL_DATA}" \ - MKDIR="${MKDIR}" + MKDIR="${MKDIR}" GHC="${GHC}" + +pre-everything:: + @${ECHO} + @${ECHO} "This port prefers lang/ghc6. To build this port with" + @${ECHO} "the Glasgow Haskell Compiler 5.x, restart this build with" + @${ECHO} "WITH_GHC5=YES." + @${ECHO} post-patch: ${REINPLACE_CMD} -e "s,/local.*tclhaskell,${GHC_LIB}," ${WRKSRC}/Makefile diff --git a/devel/hs-tclhaskell-ghc/files/patch-TclPrimGhc.hs b/devel/hs-tclhaskell-ghc/files/patch-TclPrimGhc.hs new file mode 100644 index 000000000000..bc183fc496a2 --- /dev/null +++ b/devel/hs-tclhaskell-ghc/files/patch-TclPrimGhc.hs @@ -0,0 +1,11 @@ +--- TclPrimGhc.hs.orig Tue Oct 21 17:29:21 2003 ++++ TclPrimGhc.hs Tue Oct 21 17:29:43 2003 +@@ -42,7 +42,7 @@ + writeElt pstr 0 str + return pstr + where +- len = Word.intToWord32 (length str + 1) ++ len = fromIntegral (length str + 1) + + writeElt addr n [] = writeCharOffAddr addr n '\0' + writeElt addr n (v :vs) = do diff --git a/devel/hs-tclhaskell-ghc/pkg-install.in b/devel/hs-tclhaskell-ghc/pkg-install.in index 16cbef5544a6..ec009b71e3b4 100644 --- a/devel/hs-tclhaskell-ghc/pkg-install.in +++ b/devel/hs-tclhaskell-ghc/pkg-install.in @@ -13,10 +13,10 @@ Package extra_libraries = ["tcl83","tk83","HSTclHaskell_cbits"], include_dirs = ["$GHC_LIB/include"], c_includes = [], - package_deps = [ "rts","lang","concurrent" ], + package_deps = [ "rts","lang","concurrent","data" ], extra_ghc_opts = [ "-fglasgow-exts", "-fvia-C" ], extra_cc_opts = [], - extra_ld_opts = [ "-L$PKG_PREFIX/lib -lncurses" ] + extra_ld_opts = [ "-L$PKG_PREFIX/lib", "-lncurses" ] } CONFEOF fi |