7d5781e5ab
port revision where appropriate - Add devel/hs-ghc-paths - Add devel/hs-QuickCheck - Add devel/hs-readline - Add devel/hs-haskeline - Add devel/hs-mmap - Remove lang/ghc-doc - Mark devel/lhs2TeX broken as it does not compile with GHC 6.10.4 - Set NHC98 as default compiler for devel/hs-hat as it does not compile with GHC 6.10.4 PR: ports/137055, ports/137058, ports/137059, ports/137060, ports/137061, ports/137062, ports/137063, ports/137063, ports/137064, ports/137065, ports/137066, ports/137067, ports/137068, ports/137069, ports/137070, ports/137071, ports/137072, ports/137074, ports/137075, ports/137076, ports/137077, ports/137078, ports/137079, ports/137080, ports/137081, ports/137082, ports/137083, ports/137084, ports/137085, ports/137086, ports/137087, ports/137088, ports/137090, ports/137091, ports/137092, ports/137093, ports/137094, ports/137095, ports/137096, ports/137097, ports/137098, ports/137099, ports/137102, ports/137103, ports/137104, ports/137107, ports/137108, ports/137109, ports/137110, ports/137111 Submitted by: Jacula Modyun (jacula (at) gmail (dot) com), Ashish Shukla (wahjava (at) gmail (dot) com) (amd64 support) Supported by: wxs (review, amd64 testing), tabthorpe (8.x testing) Approved by: tabthorpe (mentor), respective maintainers
135 lines
3.1 KiB
Makefile
135 lines
3.1 KiB
Makefile
# New ports collection makefile for: hs-hat
|
|
# Date created: February 4, 2009
|
|
# Whom: Gabor Pali <pgj@FreeBSD.org>
|
|
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
PORTNAME= hat
|
|
PORTVERSION= 2.06
|
|
PORTREVISION= 1
|
|
CATEGORIES= devel haskell
|
|
MASTER_SITES= ftp://ftp.cs.york.ac.uk/pub/haskell/${PORTNAME}/
|
|
PKGNAMEPREFIX= hs-
|
|
|
|
MAINTAINER= haskell@FreeBSD.org
|
|
COMMENT= A source-level tracer for Haskell 98
|
|
|
|
USE_GMAKE= yes
|
|
HAS_CONFIGURE= yes
|
|
USE_GNOME= glib12
|
|
|
|
OPTIONS= GHC "Build with GHC" off \
|
|
NHC98 "Build with NHC98" on
|
|
|
|
.include <bsd.port.pre.mk>
|
|
|
|
.if !defined(WITH_GHC) && !defined(WITH_NHC98)
|
|
IGNORE= cannot be compiled without a compiler. Please (re)run 'make config' and choose either GHC or NHC98
|
|
.endif
|
|
|
|
.if defined(WITH_GHC) && defined(WITH_NHC98)
|
|
IGNORE= can be compiled only with one of the compilers. Please (re)run 'make config' and choose either GHC or NHC98
|
|
.endif
|
|
|
|
.if defined(WITH_NHC98) && ${ARCH} == "amd64"
|
|
IGNORE= is not supported on AMD64 by NHC98.
|
|
.endif
|
|
|
|
.if defined(WITH_GHC)
|
|
IGNORE= is only supported by NHC98. Please (re)run 'make config' and choose NHC98
|
|
.endif
|
|
|
|
.if ${ARCH} == "i386"
|
|
ARCHITECTURE=ix86
|
|
.elif ${ARCH} == "amd64"
|
|
ARCHITECTURE=amd64
|
|
.else
|
|
IGNORE= is not supported on your architecture as there is no compiler for it
|
|
.endif
|
|
|
|
PLIST_SUB+= ARCH=${ARCHITECTURE}
|
|
|
|
.if defined(WITH_NHC98)
|
|
BUILD_DEPENDS+= nhc98:${PORTSDIR}/lang/nhc98
|
|
RUN_DEPENDS= nhc98:${PORTSDIR}/lang/nhc98
|
|
PKGNAMESUFFIX= -nhc98
|
|
.endif
|
|
|
|
.if defined(WITH_GHC)
|
|
BUILD_DEPENDS+= hs-hmake>=3.0:${PORTSDIR}/devel/hs-hmake \
|
|
ghc:${PORTSDIR}/lang/ghc
|
|
RUN_DEPENDS+= ghc:${PORTSDIR}/lang/ghc
|
|
PKGNAMESUFFIX= -ghc
|
|
.endif
|
|
|
|
.if defined(WITH_NHC98)
|
|
ALL_TARGET= hat-nhc
|
|
ALL_TARGET+= hat-lib-nhc
|
|
.endif
|
|
|
|
.if defined(WITH_GHC)
|
|
ALL_TARGET= hat-ghc
|
|
ALL_TARGET+= hat-lib-ghc
|
|
.endif
|
|
|
|
PLIST_SUB+= PORTVERSION=${PORTVERSION}
|
|
|
|
.if defined(WITH_NHC98)
|
|
PLIST_SUB+= NHC98=""
|
|
PLIST_SUB+= GHC="@comment "
|
|
.endif
|
|
|
|
.if defined(WITH_GHC)
|
|
GHC_VERSION= 6.10.4
|
|
PLIST_SUB+= NHC98="@comment "
|
|
PLIST_SUB+= GHC=""
|
|
PLIST_SUB+= GHC_VER="608"
|
|
PLIST_SUB+= GHC_VERSION=${GHC_VERSION}
|
|
.endif
|
|
|
|
CONFIGURE_ARGS= --prefix=${PREFIX} --libdir=${PREFIX}/lib
|
|
|
|
.if defined(WITH_NHC98)
|
|
CONFIGURE_ARGS+= --buildwith=nhc98
|
|
.endif
|
|
|
|
.if defined(WITH_GHC)
|
|
CONFIGURE_ARGS+= --buildwith=ghc
|
|
.endif
|
|
|
|
.if !defined(NOPORTDOCS)
|
|
CONFIGURE_ARGS+= --docdir=${DOCSDIR} +docs
|
|
PORTDOCS= *
|
|
.endif
|
|
|
|
MAN1= black-hat.1 hat-anim.1 hat-cover.1 hat-delta.1 hat-detect.1 hat-nonterm.1 hat-observe.1 \
|
|
hat-stack.1 hat-trail.1 hat-trans.1 pretty-hat.1
|
|
|
|
pre-everything::
|
|
@${ECHO_CMD} ""
|
|
.if defined(WITH_GHC)
|
|
@${ECHO_CMD} " HAT will be built and installed with ghc."
|
|
@${ECHO_CMD} " Define WITH_NHC98 to install with nhc98."
|
|
.endif
|
|
|
|
.if defined(WITH_NHC98)
|
|
@${ECHO_CMD} " HAT will be built and installed with nhc98."
|
|
@${ECHO_CMD} " Define WITH_GHC to install with ghc."
|
|
.endif
|
|
@${ECHO_CMD} ""
|
|
|
|
post-patch:
|
|
.if defined(WITH_NHC98)
|
|
@${REINPLACE_CMD} -e "s/-package containers//" ${WRKSRC}/src/tools/Makefile
|
|
.endif
|
|
|
|
post-install:
|
|
.if defined(WITH_GHC)
|
|
@${RM} -f ${PREFIX}/lib/ghc-${GHC_VERSION}/package.conf.old
|
|
.endif
|
|
@${INSTALL_DATA} ${WRKSRC}/src/lib/hat.cabal \
|
|
${PREFIX}/lib/${ARCHITECTURE}-FreeBSD
|
|
@${RM} -rf ${PREFIX}/share/doc/hat/private
|
|
|
|
.include <bsd.port.post.mk>
|