# New ports collection makefile for: sbcl # Date created: 2002-11-26 # Whom: des # # $FreeBSD$ # PORTNAME= sbcl PORTVERSION= 1.0 CATEGORIES= lang lisp MASTER_SITES= ${MASTER_SITE_SOURCEFORGE} MASTER_SITE_SUBDIR= sbcl DISTFILES= ${DISTNAME}-source${EXTRACT_SUFX} .if !defined(NOPORTDOCS) DISTFILES+= ${DISTNAME}-documentation-html${EXTRACT_SUFX} .endif MAINTAINER= sa2c@sa2c.net COMMENT= A Common Lisp development system derived from the CMU CL system USE_BZIP2= yes USE_GMAKE= yes EXTRACT_AFTER_ARGS= | ${TAR} -xf - --exclude */CVS/* # Can currently only bootstrap using cmucl, which is i386-only ONLY_FOR_ARCHS= i386 amd64 MAN1= sbcl.1 INFO= asdf sbcl INFODIR= ${PREFIX}/${INFO_PATH} .include # If you have a previous version of SBCL installed, you can use it # instead of the binary distribution. .if defined(WITH_SBCL) LISP_CMD= "" .else BOOT_VERSION= 0.9.16 BOOT_ARCH= x86 BOOT_OS= ${OPSYS:L} BOOT_DISTNAME= ${PORTNAME}-${BOOT_VERSION}-${BOOT_ARCH}-${BOOT_OS} DISTFILES+= ${BOOT_DISTNAME}-binary${EXTRACT_SUFX} LISP_CMD= "${WRKDIR}/${BOOT_DISTNAME}/src/runtime/sbcl --core ${WRKDIR}/${BOOT_DISTNAME}/output/sbcl.core --disable-debugger --userinit /dev/null --sysinit /dev/null" .if ${OSVERSION} >= 500000 .if ${ARCH} == i386 BUILD_DEPENDS+= ${LOCALBASE}/lib/compat/libc.so.4:${PORTSDIR}/misc/compat4x .elif ${ARCH} == amd64 BUILD_DEPENDS+= ${LOCALBASE}/lib32/compat/libc.so.4:${PORTSDIR}/misc/compat4x .endif .endif .endif .if defined(WITH_THREADS) && ${OSVERSION} < 500000 BROKEN= Does not compile on 4.x with threading .endif .if defined(WITH_THREADS) && ${ARCH} == amd64 BROKEN= Does not compile on AMD64 with threading .endif .if ${ARCH} == i386 PLIST_SUB+= I386_ONLY="" .else PLIST_SUB+= I386_ONLY="@comment " .endif post-patch: @${REINPLACE_CMD} -E -e \ 's|CFLAGS = .*|CFLAGS = ${CFLAGS} -g -DSBCL_HOME=\\"${PREFIX}/lib/sbcl/\\"|' \ ${WRKSRC}/src/runtime/GNUmakefile @${FIND} ${WRKSRC} -name '*.orig' -o -name '*.bak' | ${XARGS} ${RM} .if defined(WITH_THREADS) @${CP} ${FILESDIR}/customize-target-features.lisp ${WRKSRC} .endif do-build: @(cd ${WRKSRC} && ${SETENV} INSTALL_ROOT=${PREFIX} \ ${SH} make.sh ${LISP_CMD}) @(cd ${WRKSRC}/doc/manual && \ ${GMAKE} MAKEINFO='makeinfo --no-split' info) do-install: (cd ${WRKSRC} && ${SETENV} INSTALL_ROOT=${PREFIX} \ MAN_DIR=${PREFIX}/man DOC_DIR=${DOCSDIR} \ INFO_DIR=${INFODIR} ${SH} install.sh) .if defined(NOPORTDOCS) @${RMDIR} ${DOCSDIR}/html .endif test: build (cd ${WRKSRC}/tests && ${SH} run-tests.sh) pre-everything:: .if ${ARCH} == amd64 @${ECHO_MSG} "====>" @${ECHO_MSG} "====> WARNING: AMD64 support is experimental." @${ECHO_MSG} "====>" .else .if !defined(WITH_THREADS) && ${OSVERSION} >= 600000 @${ECHO_MSG} "====>" @${ECHO_MSG} "====> To enable experimental threading support, define WITH_THREADS." @${ECHO_MSG} "====>" .elif defined(WITH_THREADS) && ${OSVERSION} < 600000 @${ECHO_MSG} "====>" @${ECHO_MSG} "====> WARNING: Current threading support is very unstable on FreeBSD 5.x." @${ECHO_MSG} "====>" .endif .endif .include