[92241] trunk/dports/devel/cctools/Portfile
jeremyhu at macports.org
jeremyhu at macports.org
Sun Apr 22 03:27:32 PDT 2012
Revision: 92241
https://trac.macports.org/changeset/92241
Author: jeremyhu at macports.org
Date: 2012-04-22 03:27:31 -0700 (Sun, 22 Apr 2012)
Log Message:
-----------
cctools: Make non-llvm build succeed
Modified Paths:
--------------
trunk/dports/devel/cctools/Portfile
Modified: trunk/dports/devel/cctools/Portfile
===================================================================
--- trunk/dports/devel/cctools/Portfile 2012-04-22 10:20:58 UTC (rev 92240)
+++ trunk/dports/devel/cctools/Portfile 2012-04-22 10:27:31 UTC (rev 92241)
@@ -82,8 +82,10 @@
reinplace "/^COMMON_SUBDIRS/s/ ld / /" ${worksrcpath}/Makefile
# Use our chosen version of llvm
- reinplace "s:\"llvm-mc\":\"llvm-mc-mp-${llvm_version}\":" ${worksrcpath}/as/driver.c
- reinplace "s:@@LLVM_LIBDIR@@:${prefix}/libexec/llvm-${llvm_version}/lib:" ${worksrcpath}/libstuff/lto.c
+ if {[variant_isset llvm29] || [variant_isset llvm30] || [variant_isset llvm31]} {
+ reinplace "s:\"llvm-mc\":\"llvm-mc-mp-${llvm_version}\":" ${worksrcpath}/as/driver.c
+ reinplace "s:@@LLVM_LIBDIR@@:${prefix}/libexec/llvm-${llvm_version}/lib:" ${worksrcpath}/libstuff/lto.c
+ }
foreach file [glob ${worksrcpath}/{*/,}Makefile] {
reinplace "s:/usr/local:${prefix}:g" ${file}
@@ -108,14 +110,22 @@
RC_ProjectSourceVersion=${version} \
USE_DEPENDENCY_FILE=NO \
BUILD_DYLIBS=NO \
- LTO=-DLTO_SUPPORT \
CC="${configure.cc}" \
CXX="${configure.cxx}" \
- RC_CFLAGS="[get_canonical_archflags] `llvm-config-mp-${llvm_version} --cflags`" \
RC_ARCHS="[get_canonical_archs]" \
- LLVM_MC="llvm-mc-mp-${llvm_version}" \
SDK="-I${prefix}/include"
+ if {[variant_isset llvm29] || [variant_isset llvm30] || [variant_isset llvm31]} {
+ build.args-append \
+ LTO=-DLTO_SUPPORT \
+ RC_CFLAGS="[get_canonical_archflags] `llvm-config-mp-${llvm_version} --cflags`" \
+ LLVM_MC="llvm-mc-mp-${llvm_version}"
+ } else {
+ build.args-append \
+ LTO= \
+ RC_CFLAGS="[get_canonical_archflags]"
+ }
+
if {[file exists ${prefix}/lib/libprunetrie.a]} {
build.args-append \
TRIE=-DTRIE_SUPPORT
@@ -130,14 +140,22 @@
RC_ProjectSourceVersion=${version} \
USE_DEPENDENCY_FILE=NO \
BUILD_DYLIBS=NO \
- LTO=-DLTO_SUPPORT \
CC="${configure.cc}" \
CXX="${configure.cxx}" \
- RC_CFLAGS="[get_canonical_archflags] `llvm-config-mp-${llvm_version} --cflags`" \
RC_ARCHS="[get_canonical_archs]" \
- LLVM_MC="llvm-mc-mp-${llvm_version}" \
SDK="-I${prefix}/include"
+ if {[variant_isset llvm29] || [variant_isset llvm30] || [variant_isset llvm31]} {
+ destroot.args-append \
+ LTO=-DLTO_SUPPORT \
+ RC_CFLAGS="[get_canonical_archflags] `llvm-config-mp-${llvm_version} --cflags`" \
+ LLVM_MC="llvm-mc-mp-${llvm_version}"
+ } else {
+ destroot.args-append \
+ LTO= \
+ RC_CFLAGS="[get_canonical_archflags]"
+ }
+
if {[file exists ${prefix}/lib/libprunetrie.a]} {
destroot.args-append \
TRIE=-DTRIE_SUPPORT
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20120422/35a40223/attachment.html>
More information about the macports-changes
mailing list