Mac: Disallow c++11 if dependencies are linked against libstdc++
This commit is contained in:
parent
a0875c845c
commit
b394da33c7
1 changed files with 9 additions and 2 deletions
11
openscad.pro
11
openscad.pro
|
|
@ -92,12 +92,19 @@ macx {
|
|||
dirs = $${BOOSTDIR} $${QMAKE_LIBDIR}
|
||||
for(dir, dirs) {
|
||||
system(grep -q __112basic_string $${dir}/libboost_thread* >& /dev/null) {
|
||||
message("Detected libc++-linked boost in $${dir}")
|
||||
message("Using libc++11")
|
||||
CONFIG += libc++
|
||||
}
|
||||
else {
|
||||
message("Using libstdc++")
|
||||
CONFIG += libstdc++
|
||||
}
|
||||
}
|
||||
|
||||
c++11: CONFIG += libc++
|
||||
c++11 {
|
||||
libstdc++: error("libc++ vs. libstdc++ conflict: Dependencies must be linked with libc++")
|
||||
else: CONFIG += libc++
|
||||
}
|
||||
|
||||
libc++ {
|
||||
QMAKE_CXXFLAGS += -stdlib=libc++
|
||||
|
|
|
|||
Loading…
Reference in a new issue