[120764] trunk/dports/science/root6/Portfile
mojca at macports.org
mojca at macports.org
Fri Jun 6 07:30:14 PDT 2014
Revision: 120764
https://trac.macports.org/changeset/120764
Author: mojca at macports.org
Date: 2014-06-06 07:30:14 -0700 (Fri, 06 Jun 2014)
Log Message:
-----------
root6: fix configure.cxx_stdlib and compiler blacklist (#43917)
Modified Paths:
--------------
trunk/dports/science/root6/Portfile
Modified: trunk/dports/science/root6/Portfile
===================================================================
--- trunk/dports/science/root6/Portfile 2014-06-06 13:26:55 UTC (rev 120763)
+++ trunk/dports/science/root6/Portfile 2014-06-06 14:30:14 UTC (rev 120764)
@@ -9,8 +9,6 @@
PortGroup github 1.0
PortGroup select 1.0
-# TODO: try to figure out if one could also build root6 on < 10.9
-
# Essentially 6.00.00, but with some bug fixes to the build system
github.setup root-mirror root aaf9b65
#github.setup root-mirror root 6-00-00 v
@@ -37,27 +35,6 @@
configure.dir ${workpath}/build
build.dir ${configure.dir}
-# (copied from llvm-3.5)
-# TODO: Check ${configure.cxx_stdlib} directly once MacPorts 2.3 is released
-platform darwin {
- # Note that we are forcing this choice. This means that anything linking
- # against llvm-3.5 needs to also be using libc++. This is possibly
- # problematic, but luckily there is just a limited set of such dependents.
-
- if {[info exists configure.cxx_stdlib]} {
- configure.cxx_stdlib libc++
- }
-
- depends_lib-append port:libcxx
-}
-pre-fetch {
- if {(${os.major} < 13 && ! [info exists configure.cxx_stdlib]) ||
- (! [file exists /usr/lib/libc++.dylib])} {
- ui_error "$name requires a C++11 runtime, which your configuration does not allow"
- error "unsupported configuration"
- }
-}
-
post-extract {
file mkdir ${configure.dir}
}
@@ -80,10 +57,10 @@
select.group root
select.file ${filespath}/${name}
-# TODO: exact compiler fallback/black list
# Force a compatible compiler
-compiler.blacklist-append {clang < 425} macports-clang-2.9
-compiler.fallback-append macports-clang-3.5 macports-clang-3.4 macports-clang-3.3
+# (macports-clang-3.3 works; it's blacklisted only to give the preference to 3.4)
+compiler.blacklist-append *gcc* {clang < 500} macports-clang-2.9 macports-clang-3.0 macports-clang-3.1 macports-clang-3.2 macports-clang-3.3
+compiler.fallback-append macports-clang-3.4 macports-clang-3.5
# port specific location
set install_prefix ${prefix}/libexec/root${version_major}
@@ -125,15 +102,14 @@
-Dbonjour=OFF \
-Dgviz=OFF \
-Dsoversion=OFF \
- -Dc++11=OFF \
- -Dlibcxx=OFF \
+ -Dc++11=ON \
+ -Dlibcxx=ON \
-Dxrootd=OFF \
-Dbuiltin_ftgl=ON \
-Dmathmore=ON \
-Dgenvector=ON \
-Dmemstat=ON \
-Dunuran=ON \
- -Dreflex=ON \
-Dtable=ON \
-Dgdml=ON \
-DPNG_LIBRARY=${prefix}/lib/libpng.dylib \
@@ -145,23 +121,16 @@
configure.args-append -DCMAKE_INCLUDE_PATH=${prefix}/include
configure.cppflags-delete -I${prefix}/include
-# TODO: Check ${configure.cxx_stdlib} directly once MacPorts 2.3 is released
platform darwin {
- set cxxstdlib {}
-
- if {[info exists configure.cxx_stdlib] &&
- ${configure.cxx_stdlib} ne {} &&
- [string match *clang* ${configure.cxx}]} {
- set cxxstdlib ${configure.cxx_stdlib}
- } elseif {[string match *clang* ${configure.cxx}] && ${os.major} >= 13} {
- set cxxstdlib libc++
- } else {
- set cxxstdlib libstdc++
+ # Note that we are forcing this choice. This means that anything linking
+ # against root6 needs to also be using libc++. This is possibly
+ # problematic, but luckily there is just a limited set of such dependents.
+ # Another problem is that all dependencies might need to be built-in
+ # to make sure that they all use libc++.
+ if { ${configure.cxx_stdlib} ne "libc++" } {
+ configure.cxx_stdlib libc++
+ depends_lib-append port:libcxx
}
-
- if {${cxxstdlib} eq "libc++"} {
- configure.args-replace -Dc++11=OFF -Dc++11=ON
- }
}
post-destroot {
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20140606/35052ec4/attachment.html>
More information about the macports-changes
mailing list