diff options
author | Gabor Pali <pgj@FreeBSD.org> | 2012-06-03 20:52:29 +0000 |
---|---|---|
committer | Gabor Pali <pgj@FreeBSD.org> | 2012-06-03 20:52:29 +0000 |
commit | 46e9ab0ca5e504d3509678b4d43a41d938650e75 (patch) | |
tree | a34afe36b374e7894e236fb8cee020928d36c967 /lang | |
parent | be44ec14c77de91f8ac86e25372545e0e39e9bcb (diff) | |
download | ports-46e9ab0ca5e504d3509678b4d43a41d938650e75.tar.gz ports-46e9ab0ca5e504d3509678b4d43a41d938650e75.zip |
Notes
Diffstat (limited to 'lang')
19 files changed, 320 insertions, 242 deletions
diff --git a/lang/ghc/Makefile b/lang/ghc/Makefile index e5990fde8ca3..b9837f194bd0 100644 --- a/lang/ghc/Makefile +++ b/lang/ghc/Makefile @@ -5,12 +5,10 @@ # $FreeBSD$ PORTNAME= ghc -PORTVERSION= 7.0.4 +PORTVERSION= 7.4.1 CATEGORIES= lang haskell MASTER_SITES= http://www.haskell.org/ghc/dist/${PORTVERSION}/:source \ - ${MASTER_SITE_LOCAL:S/$/:boot/} \ - http://www.autistici.org/jacula/FreeBSD/:boot \ -# http://haskell.org/ghc/dist/${PORTVERSION}/freebsd/:boot + ${MASTER_SITE_LOCAL:S/$/:boot/} MASTER_SITE_SUBDIR= pgj/:boot DISTFILES= ghc-${PORTVERSION}-src${EXTRACT_SUFX}:source @@ -20,14 +18,13 @@ COMMENT= A Compiler for the functional language Haskell ONLY_FOR_ARCHS= i386 amd64 GHC_VERSION= ${PORTVERSION} -BOOT_GHC_VERSION= 6.10.4 -HSCOLOUR_VERSION= 1.16 -GHCPATH_VERSION= 0.1.0.6 +BOOT_GHC_VERSION= 7.4.1 +HSCOLOUR_VERSION= 1.19 DATADIR= ${PREFIX}/share/ghc-${GHC_VERSION} EXAMPLESDIR= ${PREFIX}/share/examples/ghc-${GHC_VERSION} -CONFLICTS= ghc-6.8.* ghc-6.10.* ghc-6.12.* +CONFLICTS= ghc-6.8.* ghc-6.10.* ghc-6.12.* ghc-7.0.* ghc-7.2.* USE_BZIP2= yes LIB_DEPENDS+= gmp.10:${PORTSDIR}/math/gmp @@ -105,7 +102,7 @@ BOOT_HSC2HS= ${BOOT_DIR}/bin/hsc2hs HACKAGE_SITE?= http://hackage.haskell.org/ HACKAGE_ARCH?= packages/archive/ -CONFIGURE_ARGS_BOOT= --prefix=${BOOT_DIR}) +CONFIGURE_ARGS_BOOT= --prefix=${BOOT_DIR} CC=${CC} CONFIGURE_ARGS+= --with-ghc=${BOOT_GHC} --with-gcc=${CC} \ --with-gmp-includes=${LOCALBASE}/include \ --with-gmp-libraries=${LOCALBASE}/lib \ @@ -128,12 +125,10 @@ MAKE_ENV+= TMPDIR=${TMPDIR} # you could view the output of: ${BOOT_GHC} describe hscolour .if defined(WITH_DOCS) -MASTER_SITES+= ${HACKAGE_SITE}${HACKAGE_ARCH}hscolour/${HSCOLOUR_VERSION}/:docs \ - ${HACKAGE_SITE}${HACKAGE_ARCH}ghc-paths/${GHCPATH_VERSION}/:docs -DISTFILES+= hscolour-${HSCOLOUR_VERSION}.tar.gz:docs \ - ghc-paths-${GHCPATH_VERSION}.tar.gz:docs +MASTER_SITES+= ${HACKAGE_SITE}${HACKAGE_ARCH}hscolour/${HSCOLOUR_VERSION}/:docs +DISTFILES+= hscolour-${HSCOLOUR_VERSION}.tar.gz:docs -EXTRACT_ONLY= ${_DISTFILES:C/ghc-paths.*$//g:C/hscolour.*$//g} +EXTRACT_ONLY= ${_DISTFILES:C/hscolour.*$//g} MAN1= ghc.1 @@ -179,7 +174,6 @@ post-extract: @${ECHO} >> ${WRKSRC}/mk/build.mk "EXTRA_CABAL_CONFIGURE_FLAGS += --extra-lib-dirs=${LOCALBASE}/lib" # @${ECHO} >> ${WRKSRC}/mk/build.mk "BIN_DIST_NAME = ghc-\$$(ProjectVersion)-boot" # @${ECHO} >> ${WRKSRC}/mk/build.mk "BIN_DIST_TAR = ghc-\$$(ProjectVersion)-amd64-ash0-freebsd8-boot.tar" - -@${RM} -f ${BOOT_DIR}/mk/build.mk post-install-script: @${FIND} -ds ${GHC_LIBDIR} -type f -print | ${SED} -E -e \ @@ -227,22 +221,18 @@ post-patch: pre-configure: @${MKDIR} ${TMPDIR} - @(cd ${BOOT_DIR} && ${CONFIGURE_ENV} ./${CONFIGURE_SCRIPT} ${CONFIGURE_ARGS_BOOT} + @(cd ${BOOT_DIR} && ${CONFIGURE_ENV} ./${CONFIGURE_SCRIPT} ${CONFIGURE_ARGS_BOOT}) @(cd ${BOOT_DIR} && PACKAGES='' ${GMAKE} install) -# @(${BOOT_GHC-PKG} unregister haddock-${BOOT_HADDOCK_VERSION}) -# @(cd ${BOOT_DIR} && ${RM} -rf utils/haddock && ${RM} -f bin/haddock \ -# && ${RM} -f ${GHC_LIBDIR_REL}/haddock && ${RM} -rf ${GHC_LIBDIR_REL}/haddock-${BOOT_HADDOCK_VERSION}) # Defining WITH_DOCS: -# Defining "SLAVE" in devel/hs-ghc-paths devel/hs-haddock and -# print/hs-hscolour flips the building process +# Defining "SLAVE" in devel/hs-haddock and print/hs-hscolour flips the building process # functionally to this port. .if defined(WITH_DOCS) @${ECHO_MSG} -e "\a" @${ECHO_MSG} "======================================================================" - @${ECHO_MSG} " WARNING: Now (Ghc-Paths, Haddock and) HsColour will be " - @${ECHO_MSG} " built, the respective ports won't be installed, but an " - @${ECHO_MSG} " in-place installation and registration of both takes place." + @${ECHO_MSG} " WARNING: Now HsColour will be built, the respective port will not " + @${ECHO_MSG} " be installed, but an in-place installation and " + @${ECHO_MSG} " registration of both takes place. " @${ECHO_MSG} "======================================================================" @${ECHO_MSG} "" @sleep 3 @@ -251,22 +241,6 @@ pre-configure: @${MKDIR} ${SLAVES_WRKDIRPREFIX} @(cd ${SLAVES_WRKDIRPREFIX} && \ - ${TAR} xvf ${DISTDIR}/ghc-paths-${GHCPATH_VERSION}.tar.gz && \ - cd ghc-paths-${GHCPATH_VERSION} && \ - ${SLAVE_CMD} ghc --make -o Setup Setup.hs -package Cabal && \ - ${SLAVE_CMD} ./Setup configure --ghc --prefix=${SLAVES_PREFIX} && \ - ${SLAVE_CMD} ./Setup build && \ - ${SLAVE_CMD} ./Setup install) - - # @(cd ${SLAVES_WRKDIRPREFIX} && \ - # ${TAR} xvf ${DISTDIR}/haddock-${HADDOCK_VERSION}.tar.gz && \ - # cd haddock-${HADDOCK_VERSION} && \ - # ${SLAVE_CMD} ghc --make -o Setup Setup.lhs -package Cabal && \ - # ${SLAVE_CMD} ./Setup configure --ghc --prefix=${SLAVES_PREFIX} && \ - # ${SLAVE_CMD} ./Setup build && \ - # ${SLAVE_CMD} ./Setup install) - - @(cd ${SLAVES_WRKDIRPREFIX} && \ ${TAR} xvf ${DISTDIR}/hscolour-${HSCOLOUR_VERSION}.tar.gz && \ cd hscolour-${HSCOLOUR_VERSION} && \ ${SLAVE_CMD} ghc --make -o Setup Setup.hs -package Cabal && \ diff --git a/lang/ghc/bsd.cabal.mk b/lang/ghc/bsd.cabal.mk index 871db7b439a4..825b138e373a 100644 --- a/lang/ghc/bsd.cabal.mk +++ b/lang/ghc/bsd.cabal.mk @@ -26,18 +26,7 @@ DIST_SUBDIR?= cabal FILE_LICENSE?= LICENSE -.if !defined(DOCUMENTATION) && \ - (${PORTNAME} == haddock || ${PORTNAME} == ghc-paths || \ - ${PORTNAME} == hscolour || ${PORTNAME} == mtl || \ - ${PORTNAME} == transformers || ${PORTNAME} == xhtml) -NOPORTDOCS= yes -.endif - -.if defined(NOPORTDOCS) && defined(DOCUMENTATION) -IGNORE+= is a documentation-only port, do not install if no documentation needed -.endif - -.if !defined(DOCUMENTATION) && !defined(STANDALONE) +.if !defined(STANDALONE) BUILD_DEPENDS+= ghc:${PORTSDIR}/lang/ghc BUILD_DEPENDS+= ghc>=${GHC_VERSION}:${PORTSDIR}/lang/ghc RUN_DEPENDS+= ghc:${PORTSDIR}/lang/ghc @@ -47,7 +36,7 @@ BUILD_DEPENDS+= ghc:${PORTSDIR}/lang/ghc BUILD_DEPENDS+= ghc>=${GHC_VERSION}:${PORTSDIR}/lang/ghc .endif -GHC_VERSION?= 7.0.4 +GHC_VERSION?= 7.4.1 GHC_VERSION_N= ${GHC_VERSION:S/./0/g} GHC_CMD?= ${LOCALBASE}/bin/ghc @@ -59,14 +48,10 @@ HAPPY_CMD?= ${LOCALBASE}/bin/happy HADDOCK_CMD?= ${LOCALBASE}/bin/haddock C2HS_CMD?= ${LOCALBASE}/bin/c2hs -.if !defined(DOCUMENTATION) CABAL_DIRS+= ${DATADIR} ${EXAMPLESDIR} ${CABAL_LIBDIR}/${CABAL_LIBSUBDIR} -.endif GHC_HADDOCK_CMD=${LOCALBASE}/bin/haddock-ghc-${GHC_VERSION} -HADDOCK_PORT= ${PORTSDIR}/devel/hs-haddock - CABAL_DOCSDIR= ${PREFIX}/share/doc/ghc-${GHC_VERSION}/cabal CABAL_DOCSDIR_REL= ${CABAL_DOCSDIR:S,^${PREFIX}/,,} @@ -114,26 +99,10 @@ LIB_DEPENDS+= gmp.10:${PORTSDIR}/math/gmp USE_ICONV= yes .endif -.if defined(EXECUTABLE) || defined(DOCUMENTATION) +.if defined(EXECUTABLE) HADDOCK_EXE?= --executables .endif -.if defined(DOCUMENTATION) - -.if defined(PORTREVISION) && ${PORTREVISION} != 0 -_SUF1= _${PORTREVISION} -.endif - -.if defined(PORTEPOCH) && ${PORTEPOCH} != 0 -_SUF2= ,${PORTEPOCH} -.endif - -PKGVERSION= ${PORTVERSION:C/[-_,]/./g}${_SUF1}${_SUF2} - -PKGNAMESUFFIX= -docs -USE_CABAL+= ${PORTNAME}==${PKGVERSION} -.endif - .if defined(USE_CABAL) .include "bsd.hackage.mk" @@ -175,9 +144,7 @@ PLIST_SUB+= NOPORTDOCS="@comment " .endif .if !defined(NOPORTDOCS) -.if !defined(XMLDOCS) || defined(DOCUMENTATION) -BUILD_DEPENDS+= ${HADDOCK_CMD}:${HADDOCK_PORT} - +.if !defined(XMLDOCS) HADDOCK_OPTS= ${HADDOCK_EXE} .if defined(WITH_HSCOLOUR_DOCS) @@ -198,10 +165,6 @@ USE_GMAKE= yes .endif # !XMLDOCS -.if defined(DOCUMENTATION) -DOCSDIR= ${CABAL_DOCSDIR}/${DISTNAME}/html -.endif - .if !defined(METAPORT) PORTDOCS= * .endif # !METAPORT @@ -214,7 +177,7 @@ __handle_datadir__= --datadir='' --datasubdir='' --docdir='${DOCSDIR}' __handle_datadir__= --datadir='${DATADIR}' --datasubdir='' --docdir='${DOCSDIR}' .endif -.if (!defined(XMLDOCS) || defined(DOCUMENTATION)) && !defined(NOPORTDOCS) +.if !defined(XMLDOCS) && !defined(NOPORTDOCS) CONFIGURE_ARGS+= --haddock-options=-w --with-haddock=${HADDOCK_CMD} .endif @@ -242,6 +205,22 @@ post-patch:: ${WRKSRC}/doc/configure.ac .endif +# Purge Haskell 98 (required for GHC 7.2 or later) +.if defined(HASKELL98) + @${REINPLACE_CMD} -E 's|haskell98[,]?||' \ + ${WRKSRC}/${PORTNAME}.cabal + + @${REINPLACE_CMD} 's|import List|import Data.List| ; \ + s|import Char|import Data.Char| ; \ + s|import Ratio|import Data.Ratio| ; \ + s|import Monad|import Control.Monad| ; \ + s|import IO|import System.IO.Error| ; \ + s|import Directory|import System.Directory| ; \ + s|import Maybe|import Data.Maybe| ; \ + s|import Array|import Data.Array|' \ + `${FIND} ${WRKSRC} -name '*.hs'` +.endif + .if !target(do-configure) do-configure: .if !defined(METAPORT) @@ -262,15 +241,13 @@ do-configure: .if !target(do-build) do-build: .if !defined(METAPORT) -.if !defined(DOCUMENTATION) cd ${WRKSRC} && ${SETUP_CMD} build .if !defined(STANDALONE) cd ${WRKSRC} && ${SETUP_CMD} register --gen-script .endif -.endif # !DOCUMENTATION .if !defined(NOPORTDOCS) -.if (!defined(XMLDOCS) && !defined(STANDALONE)) || defined(DOCUMENTATION) +.if !defined(XMLDOCS) && !defined(STANDALONE) cd ${WRKSRC} && ${SETUP_CMD} haddock ${HADDOCK_OPTS} .endif # STANDALONE .if defined(XMLDOCS) @@ -285,7 +262,6 @@ do-build: .if !target(do-install) do-install: .if !defined(METAPORT) -.if !defined(DOCUMENTATION) cd ${WRKSRC} && ${SETUP_CMD} install .if !defined(STANDALONE) @@ -308,12 +284,6 @@ do-install: .endfor .endif # MAN1SRC -.else - - @(cd ${WRKSRC}/dist/doc/html/${PORTNAME} && ${COPYTREE_SHARE} \* ${DOCSDIR}/html) - -.endif # !DOCUMENTATION - .if !defined(NOPORTDOCS) .if !empty(XMLDOCS) .for xmldoc in ${XMLDOCS} @@ -343,13 +313,11 @@ post-install-script: add-plist-post: add-plist-cabal add-plist-cabal: .if !defined(METAPORT) -.if !defined(DOCUMENTATION) @if [ -f ${CABAL_LIBDIR}/${CABAL_LIBSUBDIR}/register.sh ]; then \ (${ECHO_CMD} '@exec ${SH} %D/${CABAL_LIBDIR_REL}/${CABAL_LIBSUBDIR}/register.sh'; \ ${ECHO_CMD} '@exec ${RM} -f %D/lib/ghc-${GHC_VERSION}/package.conf.old'; \ ${ECHO_CMD} '@unexec %D/bin/ghc-pkg unregister --force ${PORTNAME}-${PORTVERSION}'; \ ${ECHO_CMD} '@unexec ${RM} -f %D/lib/ghc-${GHC_VERSION}/package.conf.old') >> ${TMPPLIST}; fi -.endif .if defined(NOPORTDOCS) @if [ -f ${DOCSDIR}/${FILE_LICENSE} ]; then \ (${ECHO_CMD} '${DOCSDIR_REL}/${FILE_LICENSE}'; \ @@ -374,7 +342,7 @@ post-install:: fi .endif -.if !defined(STANDALONE) && !defined(DOCUMENTATION) +.if !defined(STANDALONE) ${RM} -f ${PREFIX}/lib/ghc-${GHC_VERSION}/package.conf.old .endif diff --git a/lang/ghc/distinfo b/lang/ghc/distinfo index aa62aad6b075..2a469dbefc02 100644 --- a/lang/ghc/distinfo +++ b/lang/ghc/distinfo @@ -1,18 +1,16 @@ -SHA256 (ghc-7.0.4-src.tar.bz2) = 1a9b78d9d66c9c21de6c0932e36bb87406a4856f1611bf83bd44539bdc6ed0ed -SIZE (ghc-7.0.4-src.tar.bz2) = 24205070 -SHA256 (hscolour-1.16.tar.gz) = 206fa8c7e2b69d16d401feec2049bf5b392b1ac4c3628baf8b172b00cc7857f5 -SIZE (hscolour-1.16.tar.gz) = 57057 -SHA256 (ghc-paths-0.1.0.6.tar.gz) = 95d8c0e6ce2f182d792e910149b3c81c381b7d2c2052ffc6d96128b071c55243 -SIZE (ghc-paths-0.1.0.6.tar.gz) = 2291 -SHA256 (ghc-6.10.4-i386-freebsd7-boot.tar.bz2) = bf9f983785a56538ab234b29316b01c0510a6f1c30e3e5cd43878f65d5e5d9b3 -SIZE (ghc-6.10.4-i386-freebsd7-boot.tar.bz2) = 39561575 -SHA256 (ghc-6.10.4-i386-freebsd8-boot.tar.bz2) = bd14311612459764f06dbad80492e69f771cac1dfa37f8bd84f7e2c9b826c762 -SIZE (ghc-6.10.4-i386-freebsd8-boot.tar.bz2) = 39575088 -SHA256 (ghc-6.10.4-i386-freebsd9-boot.tar.bz2) = 98cb2c4015b1d99940560cd1206358d568ca2e7779aacbf44901a7541cbfb129 -SIZE (ghc-6.10.4-i386-freebsd9-boot.tar.bz2) = 39578143 -SHA256 (ghc-6.10.4-amd64-freebsd7-boot.tar.bz2) = 94aebe9b4163de908463c51d923aa4b9de001fafa6a43625f32f14d9f0ba5f65 -SIZE (ghc-6.10.4-amd64-freebsd7-boot.tar.bz2) = 39398495 -SHA256 (ghc-6.10.4-amd64-freebsd8-boot.tar.bz2) = 4297776df0204f40a960521870ba10165f3ab0602df2f431a31af316fc238e1a -SIZE (ghc-6.10.4-amd64-freebsd8-boot.tar.bz2) = 39414489 -SHA256 (ghc-6.10.4-amd64-freebsd9-boot.tar.bz2) = dddb9e8b14c326ca517c673c6494dd16de9473ad87816f895ad4661ab203ee41 -SIZE (ghc-6.10.4-amd64-freebsd9-boot.tar.bz2) = 39414446 +SHA256 (ghc-7.4.1-src.tar.bz2) = 721c09a49e519b7459b67b451b5103252ba3833906a7a24c3a3679ff94669a79 +SIZE (ghc-7.4.1-src.tar.bz2) = 25272609 +SHA256 (hscolour-1.19.tar.gz) = 7f9d2cfafbd300793686fd4e9f4ddb3f6463f300a22129db898db47956689f9f +SIZE (hscolour-1.19.tar.gz) = 25466 +SHA256 (ghc-7.4.1-i386-freebsd7-boot.tar.bz2) = e5cfc6c098179f8657d5cbf1a0fe70e8e9bfdde5a280c095e1dfc51d6e43731f +SIZE (ghc-7.4.1-i386-freebsd7-boot.tar.bz2) = 45438870 +SHA256 (ghc-7.4.1-amd64-freebsd7-boot.tar.bz2) = 836e48e2a250a43b1230eac7f04821de86d915a51d0a36d6040b48cdd25ecedb +SIZE (ghc-7.4.1-amd64-freebsd7-boot.tar.bz2) = 45310351 +SHA256 (ghc-7.4.1-i386-freebsd8-boot.tar.bz2) = b58f5b346c2b261f6357f5f72a0bf2c3c766e914cffbe6f2aefb1abf67b9a797 +SIZE (ghc-7.4.1-i386-freebsd8-boot.tar.bz2) = 45447162 +SHA256 (ghc-7.4.1-amd64-freebsd8-boot.tar.bz2) = 536da87dc9e32e98f9258e29b3a44846db6ac786f26b426da4808c33fcc92914 +SIZE (ghc-7.4.1-amd64-freebsd8-boot.tar.bz2) = 45322403 +SHA256 (ghc-7.4.1-i386-freebsd9-boot.tar.bz2) = 2af7912a14e6e31c81d2ef4505c0354ea28c3e263761f1f0282a836fe58bc8e7 +SIZE (ghc-7.4.1-i386-freebsd9-boot.tar.bz2) = 46254818 +SHA256 (ghc-7.4.1-amd64-freebsd9-boot.tar.bz2) = 8dc43c1ed2f026837947d938736ee6084f151fa5617998fca55420418f4ea28f +SIZE (ghc-7.4.1-amd64-freebsd9-boot.tar.bz2) = 46427727 diff --git a/lang/ghc/files/patch-.._ghc-6.10.4-boot_configure b/lang/ghc/files/patch-.._ghc-6.10.4-boot_configure deleted file mode 100644 index 2d0ea9a6ad36..000000000000 --- a/lang/ghc/files/patch-.._ghc-6.10.4-boot_configure +++ /dev/null @@ -1,23 +0,0 @@ - -$FreeBSD$ - ---- ../ghc-6.10.4-boot/configure.orig -+++ ../ghc-6.10.4-boot/configure -@@ -1942,7 +1942,7 @@ - TargetPlatform=i386-unknown-linux;; - i[3456]86-*-freebsd2*) - TargetPlatform=i386-unknown-freebsd2;; --i[3456]86-*-freebsd[3-9]*) -+i[3456]86-*-freebsd*) - TargetPlatform=i386-unknown-freebsd;; - i[3456]86-*-netbsd*) - TargetPlatform=i386-unknown-netbsd;; -@@ -1989,6 +1989,8 @@ - TargetPlatform=x86_64-unknown-linux;; - x86_64-*-freebsd*) - TargetPlatform=x86_64-unknown-freebsd;; -+amd64-*-freebsd*) -+ TargetPlatform=x86_64-unknown-freebsd;; - x86_64-*-openbsd*) - TargetPlatform=x86_64-unknown-openbsd;; - x86_64-*-netbsd*) diff --git a/lang/ghc/files/patch-.._ghc-6.10.4-boot_rts_package.conf.in b/lang/ghc/files/patch-.._ghc-7.4.1-boot_rts_package.conf.in index 428014e57ff5..7976302419f1 100644 --- a/lang/ghc/files/patch-.._ghc-6.10.4-boot_rts_package.conf.in +++ b/lang/ghc/files/patch-.._ghc-7.4.1-boot_rts_package.conf.in @@ -1,5 +1,5 @@ ---- ../ghc-6.10.4-boot/rts/package.conf.in.orig 2009-07-14 19:10:52.000000000 +0200 -+++ ../ghc-6.10.4-boot/rts/package.conf.in 2009-08-13 22:09:35.000000000 +0200 +--- ../ghc-7.4.1-boot/rts/package.conf.in.orig 2009-07-14 19:10:52.000000000 +0200 ++++ ../ghc-7.4.1-boot/rts/package.conf.in 2009-08-13 22:09:35.000000000 +0200 @@ -156,6 +156,8 @@ , "-u", "base_GHCziConc_ensureIOManagerIsRunning_closure" #endif diff --git a/lang/ghc/files/patch-compiler_ghc.mk b/lang/ghc/files/patch-compiler_ghc.mk new file mode 100644 index 000000000000..ebd1dda64453 --- /dev/null +++ b/lang/ghc/files/patch-compiler_ghc.mk @@ -0,0 +1,13 @@ +--- ./compiler/ghc.mk.orig 2012-02-01 19:10:32.000000000 +0100 ++++ ./compiler/ghc.mk 2012-05-17 11:32:41.868463028 +0200 +@@ -107,6 +107,10 @@ + @echo 'cRAWCPP_FLAGS = "$(RAWCPP_FLAGS)"' >> $@ + @echo 'cLdHasNoCompactUnwind :: String' >> $@ + @echo 'cLdHasNoCompactUnwind = "$(LdHasNoCompactUnwind)"' >> $@ ++ @echo 'cLdHashSize31 :: String' >> $@ ++ @echo 'cLdHashSize31 = "$(LdHashSize31)"' >> $@ ++ @echo 'cLdReduceMemoryOverheads :: String' >> $@ ++ @echo 'cLdReduceMemoryOverheads = "$(LdReduceMemoryOverheads)"' >> $@ + @echo 'cLdIsGNULd :: String' >> $@ + @echo 'cLdIsGNULd = "$(LdIsGNULd)"' >> $@ + @echo 'cLdHasBuildId :: String' >> $@ diff --git a/lang/ghc/files/patch-compiler_main_DriverPipeline.hs b/lang/ghc/files/patch-compiler_main_DriverPipeline.hs new file mode 100644 index 000000000000..e6740df077ae --- /dev/null +++ b/lang/ghc/files/patch-compiler_main_DriverPipeline.hs @@ -0,0 +1,17 @@ +--- ./compiler/main/DriverPipeline.hs.orig 2012-05-17 11:27:22.763461303 +0200 ++++ ./compiler/main/DriverPipeline.hs 2012-05-17 11:27:00.427463463 +0200 +@@ -1753,6 +1753,14 @@ + then ["-Wl,-no_compact_unwind"] + else []) + ++ ++ (if cLdHashSize31 == "YES" ++ then ["-Wl,--hash-size=31"] ++ else []) ++ ++ ++ (if cLdReduceMemoryOverheads == "YES" ++ then ["-Wl,--reduce-memory-overheads"] ++ else []) ++ + -- '-Wl,-read_only_relocs,suppress' + -- ld gives loads of warnings like: + -- ld: warning: text reloc in _base_GHCziArr_unsafeArray_info to _base_GHCziArr_unsafeArray_closure diff --git a/lang/ghc/files/patch-configure b/lang/ghc/files/patch-configure index 18cd7e9742bc..038cefa7a9c9 100644 --- a/lang/ghc/files/patch-configure +++ b/lang/ghc/files/patch-configure @@ -1,65 +1,200 @@ - -$FreeBSD$ - ---- configure.orig -+++ configure -@@ -3312,6 +3312,9 @@ +--- ./configure.orig 2012-02-01 19:11:45.000000000 +0100 ++++ ./configure 2012-05-18 12:40:29.000000000 +0200 +@@ -608,6 +608,8 @@ + HavePapiLib + GTK_CONFIG + LdHasNoCompactUnwind ++LdHashSize31 ++LdReduceMemoryOverheads + LdHasBuildId + LdIsGNULd + LdXFlag +@@ -3372,8 +3374,8 @@ vax) BuildArch="vax" ;; -+ amd64) -+ BuildArch="x86_64" -+ ;; - x86_64) - BuildArch="x86_64" +- x86_64) +- BuildArch="x86_64" ++ x86_64|amd64) ++ BuildArch="amd64" ;; -@@ -3330,7 +3333,7 @@ - BuildOS="linux" - ;; - # As far as I'm aware, none of these have relevant variants -- freebsd|netbsd|openbsd|dragonfly|osf1|osf3|hpux|linuxaout|kfreebsdgnu|freebsd2|solaris2|cygwin32|mingw32|darwin|gnu|nextstep2|nextstep3|sunos4|ultrix|irix|aix|haiku) -+ freebsd*|netbsd|openbsd|dragonfly|osf1|osf3|hpux|linuxaout|kfreebsdgnu|freebsd2|solaris2|cygwin32|mingw32|darwin|gnu|nextstep2|nextstep3|sunos4|ultrix|irix|aix|haiku) + *) + echo "Unknown CPU $build_cpu" +@@ -3404,7 +3406,7 @@ + freebsd|netbsd|openbsd|dragonfly|osf1|osf3|hpux|linuxaout|kfreebsdgnu|freebsd2|solaris2|cygwin32|mingw32|darwin|gnu|nextstep2|nextstep3|sunos4|ultrix|irix|aix|haiku) BuildOS="$build_os" ;; +- freebsd8) # like i686-gentoo-freebsd8 ++ freebsd*) # like i686-gentoo-freebsd8 + BuildOS="freebsd" + ;; *) -@@ -3560,7 +3563,7 @@ - - checkArch() { - case $1 in -- alpha|arm|hppa|hppa1_1|i386|ia64|m68k|mips|mipseb|mipsel|powerpc|powerpc64|rs6000|s390|sparc|sparc64|vax|x86_64) -+ alpha|arm|hppa|hppa1_1|i386|ia64|m68k|mips|mipseb|mipsel|powerpc|powerpc64|rs6000|s390|sparc|sparc64|vax|x86_64|amd64) - ;; - *) - echo "Unknown arch $1" -@@ -3571,7 +3574,7 @@ +@@ -3486,8 +3488,8 @@ + vax) + HostArch="vax" + ;; +- x86_64) +- HostArch="x86_64" ++ x86_64|amd64) ++ HostArch="amd64" + ;; + *) + echo "Unknown CPU $host_cpu" +@@ -3600,8 +3602,8 @@ + vax) + TargetArch="vax" + ;; +- x86_64) +- TargetArch="x86_64" ++ x86_64|amd64) ++ TargetArch="amd64" + ;; + *) + echo "Unknown CPU $target_cpu" +@@ -3712,6 +3714,9 @@ - checkVendor() { - case $1 in -- dec|unknown|hp|apple|next|sun|sgi|ibm) -+ dec|unknown|hp|apple|next|sun|sgi|ibm|portbld) - ;; - *) - echo "Unknown vendor $1" -@@ -3582,7 +3585,7 @@ - checkOS() { - case $1 in -- linux|freebsd|netbsd|openbsd|dragonfly|osf1|osf3|hpux|linuxaout|kfreebsdgnu|freebsd2|solaris2|cygwin32|mingw32|darwin|gnu|nextstep2|nextstep3|sunos4|ultrix|irix|aix|haiku) -+ linux|freebsd*|netbsd|openbsd|dragonfly|osf1|osf3|hpux|linuxaout|kfreebsdgnu|freebsd2|solaris2|cygwin32|mingw32|darwin|gnu|nextstep2|nextstep3|sunos4|ultrix|irix|aix|haiku) - ;; - *) - echo "Unknown OS '$1'" -@@ -3621,6 +3624,9 @@ - checkVendor "$TargetVendor" - checkOS "$TargetOS" +bootstrap_target=`echo "$bootstrap_target" |sed -e 's/-unknown-/-portbld-/g' -e 's/x86_64/amd64/g'` +build=`echo "$build" |sed -e 's/\(freebsd\)[[:digit:].]*$/\1/g'` + # Verify that the installed (bootstrap) GHC is capable of generating # code for the requested build platform. - if test "$build" != "$bootstrap_target" -@@ -9533,7 +9539,7 @@ + if test "$BootingFromHc" = "NO" +@@ -5313,9 +5318,9 @@ + echo 'foo() {}' > conftest.c + ${CC-cc} -c conftest.c + if ${LdCmd} -r --hash-size=31 -o conftest2.o conftest.o > /dev/null 2>&1; then +- fp_cv_LdHashSize31=--hash-size=31 ++ fp_cv_LdHashSize31=YES + else +- fp_cv_LdHashSize31= ++ fp_cv_LdHashSize31=NO + fi + rm -rf conftest* + fi +@@ -5334,9 +5339,9 @@ + echo 'foo() {}' > conftest.c + ${CC-cc} -c conftest.c + if ${LdCmd} -r --reduce-memory-overheads -o conftest2.o conftest.o > /dev/null 2>&1; then +- fp_cv_LdReduceMemoryOverheads=--reduce-memory-overheads ++ fp_cv_LdReduceMemoryOverheads=YES + else +- fp_cv_LdReduceMemoryOverheads= ++ fp_cv_LdReduceMemoryOverheads=NO + fi + rm -rf conftest* + fi +@@ -5387,18 +5392,6 @@ + CFLAGS="$CFLAGS -fno-stack-protector" + fi + +- # Reduce memory usage when linking. See trac #5240. +- if test -n "$LdHashSize31" +- then +- LDFLAGS="$LDFLAGS -Wl,$LdHashSize31" +- IGNORE_LINKER_LD_FLAGS="$IGNORE_LINKER_LD_FLAGS $LdHashSize31" +- fi +- if test -n "$LdReduceMemoryOverheads" +- then +- LDFLAGS="$LDFLAGS -Wl,$LdReduceMemoryOverheads" +- IGNORE_LINKER_LD_FLAGS="$IGNORE_LINKER_LD_FLAGS $LdReduceMemoryOverheads" +- fi +- + rm -f conftest.c conftest.o + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 + $as_echo "done" >&6; } +@@ -5445,15 +5438,15 @@ + fi + + # Reduce memory usage when linking. See trac #5240. +- if test -n "$LdHashSize31" ++ if [ "$LdHashSize31" = "YES" ] + then +- CONF_GCC_LINKER_OPTS_STAGE0="$CONF_GCC_LINKER_OPTS_STAGE0 -Wl,$LdHashSize31" +- CONF_LD_LINKER_OPTS_STAGE0="$CONF_LD_LINKER_OPTS_STAGE0 $LdHashSize31" ++ CONF_GCC_LINKER_OPTS_STAGE0="$CONF_GCC_LINKER_OPTS_STAGE0 -Wl,--hash-size=31" ++ CONF_LD_LINKER_OPTS_STAGE0="$CONF_LD_LINKER_OPTS_STAGE0 --hash-size=31" + fi +- if test -n "$LdReduceMemoryOverheads" ++ if [ "$LdReduceMemoryOverheads" = "YES" ] + then +- CONF_GCC_LINKER_OPTS_STAGE0="$CONF_GCC_LINKER_OPTS_STAGE0 -Wl,$LdReduceMemoryOverheads" +- CONF_LD_LINKER_OPTS_STAGE0="$CONF_LD_LINKER_OPTS_STAGE0 $LdReduceMemoryOverheads" ++ CONF_GCC_LINKER_OPTS_STAGE0="$CONF_GCC_LINKER_OPTS_STAGE0 -Wl,--reduce-memory-overheads" ++ CONF_LD_LINKER_OPTS_STAGE0="$CONF_LD_LINKER_OPTS_STAGE0 --reduce-memory-overheads" + fi + + rm -f conftest.c conftest.o +@@ -5502,15 +5495,15 @@ + fi + + # Reduce memory usage when linking. See trac #5240. +- if test -n "$LdHashSize31" ++ if [ "$LdHashSize31" = "YES" ] + then +- CONF_GCC_LINKER_OPTS_STAGE1="$CONF_GCC_LINKER_OPTS_STAGE1 -Wl,$LdHashSize31" +- CONF_LD_LINKER_OPTS_STAGE1="$CONF_LD_LINKER_OPTS_STAGE1 $LdHashSize31" ++ CONF_GCC_LINKER_OPTS_STAGE1="$CONF_GCC_LINKER_OPTS_STAGE1 -Wl,--hash-size=31" ++ CONF_LD_LINKER_OPTS_STAGE1="$CONF_LD_LINKER_OPTS_STAGE1 --hash-size=31" + fi +- if test -n "$LdReduceMemoryOverheads" ++ if [ "$LdReduceMemoryOverheads" = "YES" ] + then +- CONF_GCC_LINKER_OPTS_STAGE1="$CONF_GCC_LINKER_OPTS_STAGE1 -Wl,$LdReduceMemoryOverheads" +- CONF_LD_LINKER_OPTS_STAGE1="$CONF_LD_LINKER_OPTS_STAGE1 $LdReduceMemoryOverheads" ++ CONF_GCC_LINKER_OPTS_STAGE1="$CONF_GCC_LINKER_OPTS_STAGE1 -Wl,--reduce-memory-overheads" ++ CONF_LD_LINKER_OPTS_STAGE1="$CONF_LD_LINKER_OPTS_STAGE1 --reduce-memory-overheads" + fi + + rm -f conftest.c conftest.o +@@ -5559,18 +5552,6 @@ + CONF_CC_OPTS_STAGE2="$CONF_CC_OPTS_STAGE2 -fno-stack-protector" + fi + +- # Reduce memory usage when linking. See trac #5240. +- if test -n "$LdHashSize31" +- then +- CONF_GCC_LINKER_OPTS_STAGE2="$CONF_GCC_LINKER_OPTS_STAGE2 -Wl,$LdHashSize31" +- CONF_LD_LINKER_OPTS_STAGE2="$CONF_LD_LINKER_OPTS_STAGE2 $LdHashSize31" +- fi +- if test -n "$LdReduceMemoryOverheads" +- then +- CONF_GCC_LINKER_OPTS_STAGE2="$CONF_GCC_LINKER_OPTS_STAGE2 -Wl,$LdReduceMemoryOverheads" +- CONF_LD_LINKER_OPTS_STAGE2="$CONF_LD_LINKER_OPTS_STAGE2 $LdReduceMemoryOverheads" +- fi +- + rm -f conftest.c conftest.o + { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 + $as_echo "done" >&6; } +@@ -5772,7 +5753,7 @@ + i386) + test -z "$2" || eval "$2=ArchX86" + ;; +- x86_64) ++ x86_64|amd64) + + cat confdefs.h - <<_ACEOF >conftest.$ac_ext + /* end confdefs.h. */ +@@ -5953,7 +5934,7 @@ + + checkVendor() { + case $1 in +- dec|unknown|hp|apple|next|sun|sgi|ibm) ++ dec|unknown|hp|apple|next|sun|sgi|ibm|portbld) + ;; + *) + echo "Unknown vendor $1" +@@ -5976,7 +5957,7 @@ + mingw32) + test -z "$2" || eval "$2=OSMinGW32" + ;; +- freebsd) ++ freebsd*) + test -z "$2" || eval "$2=OSFreeBSD" + ;; + kfreebsdgnu) +@@ -9987,7 +9968,7 @@ $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -68,7 +203,7 @@ $FreeBSD$ cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -@@ -9564,11 +9570,7 @@ +@@ -10018,11 +9999,7 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_clock_gettime" >&5 $as_echo "$ac_cv_lib_rt_clock_gettime" >&6; } if test "x$ac_cv_lib_rt_clock_gettime" = x""yes; then : diff --git a/lang/ghc/files/patch-libraries-gen_contents_index b/lang/ghc/files/patch-libraries-gen_contents_index new file mode 100644 index 000000000000..a2785da02ed9 --- /dev/null +++ b/lang/ghc/files/patch-libraries-gen_contents_index @@ -0,0 +1,10 @@ +--- ./libraries/gen_contents_index.orig 2012-02-01 19:10:32.000000000 +0100 ++++ ./libraries/gen_contents_index 2012-05-17 02:20:09.000000000 +0200 +@@ -47,7 +47,6 @@ + esac + + # Now create the combined contents and index pages +-echo $HADDOCK_ARGS + $HADDOCK --gen-index --gen-contents -o . \ + -t "Haskell Hierarchical Libraries" \ + -p "prologue.txt" \ diff --git a/lang/ghc/files/patch-libraries_Cabal_Distribution_Simple_Haddock.hs b/lang/ghc/files/patch-libraries_Cabal_Distribution_Simple_Haddock.hs deleted file mode 100644 index c8a4d6a29e90..000000000000 --- a/lang/ghc/files/patch-libraries_Cabal_Distribution_Simple_Haddock.hs +++ /dev/null @@ -1,14 +0,0 @@ ---- ./libraries/Cabal/Distribution/Simple/Haddock.hs.orig 2011-06-13 19:10:10.000000000 +0200 -+++ ./libraries/Cabal/Distribution/Simple/Haddock.hs 2012-01-25 07:33:27.000000000 +0100 -@@ -440,8 +440,9 @@ - let allPkgs = installedPkgs lbi - directDeps = map fst (externalPackageDeps lbi) - transitiveDeps <- case dependencyClosure allPkgs directDeps of -- Left x -> return x -- Right _ -> die "Can't find transitive deps for haddock" -+ Left x -> return x -+ Right inf -> die $ "internal error when calculating transative " -+ ++ "package dependencies.\nDebug info: " ++ show inf - interfaces <- sequence - [ case interfaceAndHtmlPath ipkg of - Nothing -> return (Left (packageId ipkg)) diff --git a/lang/ghc/files/patch-libraries_Cabal_Distribution_Simple_LocalBuildInfo.hs b/lang/ghc/files/patch-libraries_Cabal_Distribution_Simple_LocalBuildInfo.hs deleted file mode 100644 index f656c59d64cd..000000000000 --- a/lang/ghc/files/patch-libraries_Cabal_Distribution_Simple_LocalBuildInfo.hs +++ /dev/null @@ -1,25 +0,0 @@ ---- ./libraries/Cabal/Distribution/Simple/LocalBuildInfo.hs.orig 2011-06-13 19:10:10.000000000 +0200 -+++ ./libraries/Cabal/Distribution/Simple/LocalBuildInfo.hs 2012-01-25 07:33:27.000000000 +0100 -@@ -136,13 +136,17 @@ - } - deriving (Read, Show) - ---- | External package dependencies for the package as a whole, the union of the ---- individual 'targetPackageDeps'. -+-- | External package dependencies for the package as a whole. This is the -+-- union of the individual 'componentPackageDeps', less any internal deps. - externalPackageDeps :: LocalBuildInfo -> [(InstalledPackageId, PackageId)] --externalPackageDeps lbi = nub $ -+externalPackageDeps lbi = filter (not . internal . snd) $ nub $ - -- TODO: what about non-buildable components? -- maybe [] componentPackageDeps (libraryConfig lbi) -- ++ concatMap (componentPackageDeps . snd) (executableConfigs lbi) -+ maybe [] componentPackageDeps (libraryConfig lbi) -+ ++ concatMap (componentPackageDeps . snd) (executableConfigs lbi) -+ where -+ -- True if this dependency is an internal one (depends on the library -+ -- defined in the same package). -+ internal pkgid = pkgid == packageId (localPkgDescr lbi) - - -- | The installed package Id we use for local packages registered in the local - -- package db. This is what is used for intra-package deps between components. diff --git a/lang/ghc/files/patch-mk_config.mk.in b/lang/ghc/files/patch-mk_config.mk.in new file mode 100644 index 000000000000..091c2aadddb3 --- /dev/null +++ b/lang/ghc/files/patch-mk_config.mk.in @@ -0,0 +1,12 @@ +--- ./mk/config.mk.in.orig 2012-02-01 19:10:32.000000000 +0100 ++++ ./mk/config.mk.in 2012-05-17 11:30:15.271461640 +0200 +@@ -699,6 +699,9 @@ + # and compiler/main/DriverPipeline.hs. + LdHasNoCompactUnwind = @LdHasNoCompactUnwind@ + ++LdHashSize31 = @LdHashSize31@ ++LdReduceMemoryOverheads = @LdReduceMemoryOverheads@ ++ + # On MSYS, building with SplitObjs=YES fails with + # ar: Bad file number + # see #3201. We need to specify a smaller max command-line size diff --git a/lang/ghc/files/patch-rts_package.conf.in b/lang/ghc/files/patch-rts_package.conf.in index 4732ffc6ebe9..e3f4f73239ea 100644 --- a/lang/ghc/files/patch-rts_package.conf.in +++ b/lang/ghc/files/patch-rts_package.conf.in @@ -17,7 +17,7 @@ $FreeBSD$ , "-u", "base_GHCziConc_runSparks_closure" , "-u", "base_GHCziConc_runHandlers_closure" #endif -+ , "-L/usr/local/lib" ++ , "-L%%LOCALBASE%%/lib" /* Pick up static libraries in preference over dynamic if in earlier search * path. This is important to use the static gmp in preference on Mac OS. diff --git a/lang/ghc/pkg-descr b/lang/ghc/pkg-descr index d2357b56433e..28181522ac05 100644 --- a/lang/ghc/pkg-descr +++ b/lang/ghc/pkg-descr @@ -2,23 +2,15 @@ Haskell is the standard lazy purely functional programming language. The current language version is Haskell 98, agreed in December 1998, with a revised version published in January 2003. -A wide variety of Haskell related resources (tutorials, libraries, -specifications, documentation, compilers, interpreters, references, -contact information, links to research groups) are available from -the Haskell home page at http://haskell.org/. - The Glasgow Haskell Compiler is a robust, fully-featured, optimising compiler for the functional programming language Haskell 98 generating -good code for a variety of platforms. GHC is a state-of-the-art -programming suite for Haskell and compiles Haskell to either native -code or C. It implements numerous experimental language extensions to +good code for a variety of platforms. GHC is a state-of-the-art +programming suite for Haskell and compiles Haskell to either native code +or C. It implements numerous experimental language extensions to Haskell, including concurrency, a foreign language interface, several -type-system extensions, exceptions, and so on. GHC comes with a +type-system extensions, exceptions, and so on. GHC comes with a generational garbage collector, a space and time profiler, comprehensive set of libraries and an interactive system for convenient, quick development. -The profiling libraries for Glorious Glasgow Haskell Compilation System -should be installed when GHC's profiling subsystem is needed. - -WWW: http://www.haskell.org/ghc/ +WWW: http://www.haskell.org/ghc/ diff --git a/lang/hs-brainfuck/Makefile b/lang/hs-brainfuck/Makefile index 2e379e9dae01..895bb169de37 100644 --- a/lang/hs-brainfuck/Makefile +++ b/lang/hs-brainfuck/Makefile @@ -7,7 +7,7 @@ PORTNAME= brainfuck PORTVERSION= 0.1 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= lang haskell MAINTAINER= haskell@FreeBSD.org diff --git a/lang/hs-unlambda/Makefile b/lang/hs-unlambda/Makefile index 1875ed6f816b..6c545eb49ca6 100644 --- a/lang/hs-unlambda/Makefile +++ b/lang/hs-unlambda/Makefile @@ -7,7 +7,7 @@ PORTNAME= unlambda PORTVERSION= 0.1 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= lang haskell MAINTAINER= haskell@FreeBSD.org diff --git a/lang/whitespace/Makefile b/lang/whitespace/Makefile index 1fe6554636cb..8462ed529027 100644 --- a/lang/whitespace/Makefile +++ b/lang/whitespace/Makefile @@ -7,7 +7,7 @@ PORTNAME= whitespace PORTVERSION= 0.3 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= lang MASTER_SITES= http://compsoc.dur.ac.uk/whitespace/downloads/ DISTNAME= wspace-${PORTVERSION} diff --git a/lang/whitespace/files/patch-VM.hs b/lang/whitespace/files/patch-VM.hs new file mode 100644 index 000000000000..3ce69251f568 --- /dev/null +++ b/lang/whitespace/files/patch-VM.hs @@ -0,0 +1,10 @@ +--- ./VM.hs.orig 2004-05-04 19:10:41.000000000 +0200 ++++ ./VM.hs 2012-05-12 21:52:19.000000000 +0200 +@@ -1,6 +1,6 @@ + module VM where + +-import IO ++import System.IO + + {- Stack machine for running whitespace programs -} + diff --git a/lang/whitespace/files/patch-main.hs b/lang/whitespace/files/patch-main.hs new file mode 100644 index 000000000000..bf7711f9d1d3 --- /dev/null +++ b/lang/whitespace/files/patch-main.hs @@ -0,0 +1,11 @@ +--- ./main.hs.orig 2003-03-31 17:33:44.000000000 +0200 ++++ ./main.hs 2012-05-12 21:52:07.000000000 +0200 +@@ -26,7 +26,7 @@ + import VM + import Tokens + +-import System(getArgs) ++import System.Environment (getArgs) + + main :: IO () + main = do |