Ignore:
Timestamp:
Nov 2, 2013, 5:22:32 PM (6 years ago)
Author:
jeremyhu@…
Message:

cmake: Honor configure.cxx_stdlib

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dports/_resources/port1.0/group/cmake-1.0.tcl

    r112838 r112840  
    8484    configure.args-append -DCMAKE_C_FLAGS_RELEASE="${configure.cflags}"
    8585}
    86 if {${configure.cxxflags} != ""} {
     86set cxx_stdlibflags {}
     87if {[info exists configure.cxx_stdlib] &&
     88    ${configure.cxx_stdlib} ne {} &&
     89    [string match *clang* ${configure.cxx}]} {
     90    set cxx_stdlibflags -stdlib=${configure.cxx_stdlib}
     91}
     92if {${configure.cxxflags} != "" || ${cxx_stdlibflags} != ""} {
    8793    # The configure.cxxflags contain configure.optflags by default. Therefore,
    8894    # we set the Release flags, which would otherwise overrule the optimization
     
    9096    # to add "-NDEBUG" to the configure.cflags if you want to turn off
    9197    # assertions in release builds!
    92     configure.args-append -DCMAKE_CXX_FLAGS_RELEASE="${configure.cxxflags}"
     98    configure.args-append -DCMAKE_CXX_FLAGS_RELEASE="${configure.cxxflags} ${cxx_stdlibflags}"
    9399}
    94100if {${configure.ldflags} != ""} {
Note: See TracChangeset for help on using the changeset viewer.