Changeset View
Changeset View
Standalone View
Standalone View
head/lang/ghc/Makefile
# Created by: Simon Marlow <simonmar@microsoft.com> | # Created by: Simon Marlow <simonmar@microsoft.com> | ||||
# $FreeBSD$ | # $FreeBSD$ | ||||
PORTNAME= ghc | PORTNAME= ghc | ||||
PORTVERSION= ${GHC_VERSION} | PORTVERSION= ${GHC_VERSION} | ||||
PORTREVISION= 1 | |||||
CATEGORIES= lang haskell | CATEGORIES= lang haskell | ||||
MASTER_SITES= https://www.haskell.org/ghc/dist/${PORTVERSION}/:source \ | MASTER_SITES= https://www.haskell.org/ghc/dist/${PORTVERSION}/:source \ | ||||
LOCAL/arrowd/:boot \ | LOCAL/arrowd/:boot \ | ||||
https://hackage.haskell.org/package/hscolour-${HSCOLOUR_VERSION}/:docs | https://hackage.haskell.org/package/hscolour-${HSCOLOUR_VERSION}/:docs | ||||
DISTFILES= ghc-${PORTVERSION}-src${EXTRACT_SUFX}:source \ | DISTFILES= ghc-${PORTVERSION}-src${EXTRACT_SUFX}:source \ | ||||
hscolour-${HSCOLOUR_VERSION}.tar.gz:docs | hscolour-${HSCOLOUR_VERSION}.tar.gz:docs | ||||
EXTRACT_ONLY= ${_DISTFILES:C/hscolour.*$//g} | EXTRACT_ONLY= ${_DISTFILES:C/hscolour.*$//g} | ||||
▲ Show 20 Lines • Show All 127 Lines • ▼ Show 20 Lines | |||||
DISTFILES+= ghc-${BOOT_GHC_VERSION}-boot-${ARCH}-freebsd${EXTRACT_SUFX}:boot | DISTFILES+= ghc-${BOOT_GHC_VERSION}-boot-${ARCH}-freebsd${EXTRACT_SUFX}:boot | ||||
.endif # MBOOT | .endif # MBOOT | ||||
.if ${ARCH} == aarch64 || ${ARCH} == armv6 || ${ARCH} == armv7 | .if ${ARCH} == aarch64 || ${ARCH} == armv6 || ${ARCH} == armv7 | ||||
# CONFIGURE_TARGET must to be the same as the llvm triple | # CONFIGURE_TARGET must to be the same as the llvm triple | ||||
CONFIGURE_TARGET= ${ARCH}-unknown-freebsd${"${ARCH:Maarch64}" != "":?:-gnueabihf} | CONFIGURE_TARGET= ${ARCH}-unknown-freebsd${"${ARCH:Maarch64}" != "":?:-gnueabihf} | ||||
EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-aclocal.m4 | EXTRA_PATCHES+= ${PATCHDIR}/extra-patch-aclocal.m4 | ||||
BUILD_DEPENDS+= ld.gold:devel/binutils \ | BUILD_DEPENDS+= llc${LLVM_VERSION}:devel/llvm${LLVM_VERSION} | ||||
llc${LLVM_VERSION}:devel/llvm${LLVM_VERSION} | RUN_DEPENDS+= llc${LLVM_VERSION}:devel/llvm${LLVM_VERSION} | ||||
RUN_DEPENDS+= ld.gold:devel/binutils \ | |||||
llc${LLVM_VERSION}:devel/llvm${LLVM_VERSION} | |||||
USE_GCC= yes | |||||
# When GHC being compiled and GHC used for bootstrapping support different | # When GHC being compiled and GHC used for bootstrapping support different | ||||
# LLVM versions, we have to pull in both. Luckily, this is relatively rare. | # LLVM versions, we have to pull in both. Luckily, this is relatively rare. | ||||
. if ${BOOT_LLVM_VERSION} != ${LLVM_VERSION} | . if ${BOOT_LLVM_VERSION} != ${LLVM_VERSION} | ||||
BUILD_DEPENDS+= llc${BOOT_LLVM_VERSION}:devel/llvm${BOOT_LLVM_VERSION} | BUILD_DEPENDS+= llc${BOOT_LLVM_VERSION}:devel/llvm${BOOT_LLVM_VERSION} | ||||
RUN_DEPENDS+= llc${BOOT_LLVM_VERSION}:devel/llvm${BOOT_LLVM_VERSION} | RUN_DEPENDS+= llc${BOOT_LLVM_VERSION}:devel/llvm${BOOT_LLVM_VERSION} | ||||
. endif | . endif | ||||
. if ${OSVERSION} < 1200064 | |||||
IGNORE= lang/ghc on ARM requires at least __FreeBSD_version 1200064 | |||||
. endif | .endif | ||||
. ifdef QEMU_EMULATING | .if ${ARCH} == aarch64 || ${ARCH} == armv6 || ${ARCH} == armv7 || ${ARCH} == powerpc64 | ||||
IGNORE= qemu-user-static isn't able to build lang/ghc, but it builds fine on a real hardware | |||||
. endif | |||||
.endif | |||||
.if ${ARCH} == powerpc64 | |||||
USE_GCC= yes | USE_GCC= yes | ||||
. if ${OSVERSION} < 1200086 | . if ${OSVERSION} < 1200086 | ||||
IGNORE= lang/ghc on powerpc64 requires at least __FreeBSD_version 1200086 | IGNORE= lang/ghc requires at least FreeBSD 12.0-RELEASE | ||||
. endif | |||||
. ifdef QEMU_EMULATING | |||||
IGNORE= qemu-user-static isn't able to build lang/ghc, but it builds fine on a real hardware | |||||
. endif | . endif | ||||
.endif | .endif | ||||
# Use binutils strip if we are using gcc, as it is faster that base one. See PR 234949 | # Use binutils strip if we are using gcc, as it is faster that base one. See PR 234949 | ||||
.if defined(USE_GCC) | .if defined(USE_GCC) | ||||
CONFIGURE_ENV+= STRIP=${LOCALBASE}/bin/strip | CONFIGURE_ENV+= STRIP=${LOCALBASE}/bin/strip | ||||
.endif | .endif | ||||
▲ Show 20 Lines • Show All 149 Lines • Show Last 20 Lines |