Skip to content

Commit

Permalink
qt5*: always respect configure.sdk_version value
Browse files Browse the repository at this point in the history
  • Loading branch information
MarcusCalhoun-Lopez committed Feb 17, 2017
1 parent c7a7730 commit 72f9ad9
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 10 deletions.
16 changes: 11 additions & 5 deletions aqua/qt5/Portfile
Expand Up @@ -135,7 +135,7 @@ array set modules {
{"Qt Gui" "Qt Widgets" "Qt Print Support" "Qt OpenGL" "Qt Core" "Qt XML" "Qt SQL" "Qt Network" "Qt Test" "Qt D-Bus" "Qt Concurrent" "Qt Platform Headers"}
""
"variant overrides: ~docs"
"revision 1"
"revision 2"
"License: "
}
qtcanvas3d {
Expand Down Expand Up @@ -720,6 +720,14 @@ foreach {module module_info} [array get modules] {
}
}

# respect configure.sdk_version value
patchfiles-append patch-macx.conf.diff
post-patch {
reinplace \
"s|__MACPORTS_MAC_SDK__|macosx${configure.sdk_version}|g" \
${worksrcpath}/mkspecs/common/macx.conf
}

# return modified spec files to the default values
post-build {
if { [variant_exists universal] && [variant_isset universal] } {
Expand Down Expand Up @@ -859,10 +867,8 @@ foreach {module module_info} [array get modules] {
-framework \
-securetransport

if {${configure.sdkroot} ne ""} {
configure.args-append \
-sdk [string tolower [join [lrange [split [lindex [split ${configure.sdkroot} "/"] end] "."] 0 end-1] "."]]
}
configure.args-append \
-sdk macosx${configure.sdk_version}

# configure options that don't show up in configure --help
configure.args-append \
Expand Down
16 changes: 11 additions & 5 deletions aqua/qt55/Portfile
Expand Up @@ -134,7 +134,7 @@ array set modules {
{"Qt Gui" "Qt Widgets" "Qt Print Support" "Qt OpenGL" "Qt Core" "Qt XML" "Qt SQL" "Qt Network" "Qt Test" "Qt D-Bus" "Qt Concurrent" "Qt Platform Headers"}
""
"variant overrides: ~docs"
"revision 1"
"revision 2"
"License: "
}
qtcanvas3d {
Expand Down Expand Up @@ -709,6 +709,14 @@ foreach {module module_info} [array get modules] {
}
}

# respect configure.sdk_version value
patchfiles-append patch-macx.conf.diff
post-patch {
reinplace \
"s|__MACPORTS_MAC_SDK__|macosx${configure.sdk_version}|g" \
${worksrcpath}/mkspecs/common/macx.conf
}

# return modified spec files to the default values
post-build {
if { [variant_exists universal] && [variant_isset universal] } {
Expand Down Expand Up @@ -845,10 +853,8 @@ foreach {module module_info} [array get modules] {
-framework \
-securetransport

if {${configure.sdkroot} ne ""} {
configure.args-append \
-sdk [string tolower [join [lrange [split [lindex [split ${configure.sdkroot} "/"] end] "."] 0 end-1] "."]]
}
configure.args-append \
-sdk macosx${configure.sdk_version}

# configure options that don't show up in configure --help
configure.args-append \
Expand Down

0 comments on commit 72f9ad9

Please sign in to comment.