diff options
author | Keri Harris <keri@gentoo.org> | 2017-10-01 18:26:16 +0200 |
---|---|---|
committer | Keri Harris <keri@gentoo.org> | 2017-10-01 18:26:34 +0200 |
commit | eeeab1a8ebfb0d3ac9c34bdf0eb272d68ef6e672 (patch) | |
tree | 8981d7ba6e5b4855372299a1d9c6b2712968b1f8 /dev-lang/mercury/mercury-14.01.1.ebuild | |
parent | dev-util/icemon: 3.1.0 Qt5-based version bump, bug #629038 (diff) | |
download | gentoo-eeeab1a8ebfb0d3ac9c34bdf0eb272d68ef6e672.tar.gz gentoo-eeeab1a8ebfb0d3ac9c34bdf0eb272d68ef6e672.tar.bz2 gentoo-eeeab1a8ebfb0d3ac9c34bdf0eb272d68ef6e672.zip |
dev-lang/mercury: use Mmake.params to specify CFLAGS/LDFLAGS
Package-Manager: Portage-2.3.8, Repoman-2.3.1
Diffstat (limited to 'dev-lang/mercury/mercury-14.01.1.ebuild')
-rw-r--r-- | dev-lang/mercury/mercury-14.01.1.ebuild | 32 |
1 files changed, 15 insertions, 17 deletions
diff --git a/dev-lang/mercury/mercury-14.01.1.ebuild b/dev-lang/mercury/mercury-14.01.1.ebuild index d500a59e1798..8bc496d6371a 100644 --- a/dev-lang/mercury/mercury-14.01.1.ebuild +++ b/dev-lang/mercury/mercury-14.01.1.ebuild @@ -5,7 +5,7 @@ EAPI=5 inherit autotools elisp-common eutils flag-o-matic java-pkg-opt-2 multilib xdg-utils -PATCHSET_VER="0" +PATCHSET_VER="1" MY_P=${PN}-srcdist-${PV} DESCRIPTION="Mercury is a modern general-purpose logic/functional programming language" @@ -69,12 +69,14 @@ src_configure() { } src_compile() { + # Prepare mmake flags + echo "EXTRA_CFLAGS = ${CFLAGS}" >> Mmake.params + echo "EXTRA_LDFLAGS = ${LDFLAGS}" >> Mmake.params + echo "EXTRA_MLFLAGS = --no-strip" >> Mmake.params + # Build Mercury using bootstrap grade emake \ PARALLEL="${MAKEOPTS}" \ - EXTRA_CFLAGS="${CFLAGS}" \ - EXTRA_LDFLAGS="${LDFLAGS}" \ - EXTRA_MLFLAGS="--no-strip" \ || die "emake failed" # We can now patch .m Mercury compiler files since we @@ -93,9 +95,6 @@ src_compile() { # Rebuild Mercury compiler using the just built mercury_compiler emake \ PARALLEL="${MAKEOPTS}" \ - EXTRA_CFLAGS="${CFLAGS}" \ - EXTRA_LDFLAGS="${LDFLAGS}" \ - EXTRA_MLFLAGS="--no-strip" \ MERCURY_COMPILER="${S}"/compiler/mercury_compile \ compiler || die "emake compiler failed" @@ -104,9 +103,6 @@ src_compile() { # the default grade now emake \ PARALLEL="${MAKEOPTS}" \ - EXTRA_CFLAGS="${CFLAGS}" \ - EXTRA_LDFLAGS="${LDFLAGS}" \ - EXTRA_MLFLAGS="--no-strip" \ MERCURY_COMPILER="${S}"/compiler/mercury_compile \ default_grade || die "emake default_grade failed" } @@ -123,8 +119,16 @@ src_test() { fi cd "${S}"/tests || die - sed -e "s:@WORKSPACE@:${TWS}:" < WS_FLAGS.ws > WS_FLAGS \ + sed -e "s:@WORKSPACE@:${TWS}:" \ + < WS_FLAGS.ws \ + > WS_FLAGS \ + || die "sed WORKSPACE failed" + sed -e "s:@WORKSPACE@:${TWS}:" \ + < .mgnuc_copts.ws \ + > .mgnuc_copts \ || die "sed WORKSPACE failed" + find . -mindepth 1 -type d -exec cp .mgnuc_opts {} \; + find . -mindepth 1 -type d -exec cp .mgnuc_copts {} \; # Mercury tests must be run in C locale since Mercury output is # compared to hard-coded warnings/errors @@ -137,18 +141,12 @@ src_test() { MMAKE_DIR="${TWS}"/scripts \ MERCURY_SUPPRESS_STACK_TRACE=yes \ GRADE=${TEST_GRADE} \ - MERCURY_ALL_LOCAL_C_INCL_DIRS=" -I${TWS}/boehm_gc/include \ - -I${TWS}/runtime \ - -I${TWS}/library" \ mmake || die "mmake test failed" } src_install() { emake \ PARALLEL="${MAKEOPTS}" \ - EXTRA_CFLAGS="${CFLAGS}" \ - EXTRA_LDFLAGS="${LDFLAGS}" \ - EXTRA_MLFLAGS="--no-strip" \ MERCURY_COMPILER="${S}"/compiler/mercury_compile \ DESTDIR="${D}" \ INSTALL_PREFIX="${D}"/usr \ |