pkgsrc/lang/ghc/Makefile

55 lines
1.9 KiB
Makefile

# $NetBSD: Makefile,v 1.15 2004/01/24 13:51:14 grant Exp $
DISTNAME= ghc-5.04.3
CATEGORIES= lang
MASTER_SITES= http://www.haskell.org/ghc/dist/5.04.3/
DISTFILES= ghc-5.04.3-src.tar.bz2 ghc-5.04.3-i386-unknown-netbsd-hc.tar.bz2
MAINTAINER= kristerw@NetBSD.org
HOMEPAGE= http://www.haskell.org/ghc/
COMMENT= Compiler for the functional language Haskell
GNU_CONFIGURE= # defined
USE_X11= # defined
CONFIGURE_SCRIPT= ./distrib/hc-build
CONFIGURE_ENV+= LIBS="-L${PREFIX}/lib"
AUTOCONF_REQD=2.13
USE_BUILDLINK2= #defined
USE_GNU_READLINE=yes
USE_PERL5= yes
USE_GNU_TOOLS+= make
# Note: this package contains a Haskell compiler that is itself
# written in Haskell. There are basically two ways we can solve the
# bootstrap problem:
# 1. bootstrap from pre-generated C files.
# 2. first download a binary pre-built compiler and use it to compile.
# We currently use way 1.
# The problem with 2. is that it may make the package more sensitive
# to the exact NetBSD versions involved (the version of the build
# system compared to the version used to build the pre-built binary).
# On the other hand, bootstrapping GHC from C is very fragile and it
# may be harder to update the package with method 1.
# For comparison, FreeBSD currently uses method 2.
# Note: a number of non-i386 platforms, including solaris/sparc,
# osf/alpha etc are supported natively by ghc. pkg support for those
# platforms and their NetBSD varients is left as a mid-level exercise
# for the reader
ONLY_FOR_PLATFORM= NetBSD-1.5*-i386 NetBSD-1.6*-i386
pre-configure:
cd ${WRKSRC}; file=configure.in; \
${SED} -e "s|@PREFIX@|${PREFIX}|g" $${file} > $${file}.fixed; \
${MV} -f $${file}.fixed $${file}; \
${AUTOCONF}
do-build:
.include "../../devel/readline/buildlink2.mk"
.include "../../devel/gmp/buildlink2.mk"
.include "../../x11/gtk/buildlink2.mk"
.include "../../mk/autoconf.mk"
.include "../../mk/bsd.pkg.mk"