[macports-ports] branch master updated: cmake: update to 3.17.1
Frank Schima
mf2k at macports.org
Tue Apr 14 15:09:31 UTC 2020
Hi Michael,
> On Apr 14, 2020, at 8:37 AM, Michael Dickens <michaelld at macports.org> wrote:
>
> Michael Dickens (michaelld) pushed a commit to branch master
> in repository macports-ports.
>
> https://github.com/macports/macports-ports/commit/a2b35ff01110fe89e56a898876b65863f26b0073 <https://github.com/macports/macports-ports/commit/a2b35ff01110fe89e56a898876b65863f26b0073>
> The following commit(s) were added to refs/heads/master by this push:
> new a2b35ff cmake: update to 3.17.1
> a2b35ff is described below
>
> commit a2b35ff01110fe89e56a898876b65863f26b0073
> Author: Michael Dickens <michaelld at macports.org>
> AuthorDate: Tue Apr 14 10:37:01 2020 -0400
>
> cmake: update to 3.17.1
>
> Deprecate cmake-devel: cmake is updated regularly enough to not warrant needing this port.
> ---
> devel/cmake/Portfile | 505 ++++++++++-----------
> .../patch-CMakeFindFrameworks.cmake.devel.diff | 11 -
> .../files/patch-Modules-noArchCheck.devel.diff | 72 ---
> ...patch-Source_Modules_FindLibUV.cmake.devel.diff | 13 -
> .../files/patch-cmake-leopard-tiger.devel.diff | 119 -----
> .../files/patch-fix-clock_gettime-test.devel.diff | 15 -
> .../files/patch-fix-system-prefix-path.devel.diff | 75 ---
> .../files/patch-fix_cxx14_17_checks.devel.diff | 63 ---
> devel/cmake/files/patch-qt4gui.devel.diff | 172 -------
> devel/cmake/files/patch-qt5gui.devel.diff | 93 ----
> 10 files changed, 243 insertions(+), 895 deletions(-)
>
> diff --git a/devel/cmake/Portfile b/devel/cmake/Portfile
> index 115e89b..50eb99a 100644
> --- a/devel/cmake/Portfile
> +++ b/devel/cmake/Portfile
> @@ -6,7 +6,7 @@ PortGroup xcodeversion 1.0
> PortGroup gitlab 1.0
> PortGroup legacysupport 1.1
>
> -# Cmake is a depedency of clang
> +# CMake is a depedency of clang
“dependency” is still spelled incorrectly here. :)
> PortGroup clang_dependency 1.0
>
> name cmake
> @@ -25,40 +25,40 @@ homepage https://cmake.org
> platforms darwin freebsd
> gitlab.instance https://gitlab.kitware.com
>
> -# require C++11
> -compiler.cxx_standard 2011
> -
> -platform darwin {
> - if {!((${os.major} < 9) || ${build_arch} eq "ppc" || ${build_arch} eq "ppc64")} {
> - depends_lib-append port:libcxx
> - configure.cxx_stdlib libc++
> - }
> +subport cmake-devel {
> + PortGroup obsolete 1.0
> + replaced_by cmake
> + version 20200323-8638c49f
> + revision 2
> + depends_build
> + depends_lib
> }
>
> -dist_subdir cmake
> -
> -# OSX <= 10.11 does not provide "clock_gettime"
> -legacysupport.newest_darwin_requires_legacy 15
> -# see https://trac.macports.org/ticket/59832
> -legacysupport.redirect_bins cmake
> -
> -subport cmake-devel {}
> -
> -set branch 3.17
> -
> if {${subport} eq ${name}} {
>
> - # release
> + gitlab.setup cmake cmake 3.17.1 v
> + gitlab.livecheck.regex {([0-9.]+)}
> +
> + checksums rmd160 9afa348d301a329500a54687c179b4b9496ca01c \
> + sha256 0169920aff738ebfc7b008d2eddb0db5dd9c6ef36cf26283b02cdcacb4188be6 \
> + size 7413964
> + revision 0
>
> - gitlab.setup cmake cmake ${branch}.0 v
> - gitlab.livecheck.regex {([0-9.]+)}
> + # require C++11
> + compiler.cxx_standard 2011
>
> - checksums rmd160 bc8af0a1638c1d21333f162e133c22203e44dd35 \
> - sha256 c8ee2d53f4aad3987d8a3cb138d12c772c1ad6b65b2b69c74421b21ea8d6fb79 \
> - size 7411593
> - revision 1
> + platform darwin {
> + if {!((${os.major} < 9) || ${build_arch} eq "ppc" ||
> + ${build_arch} eq "ppc64")} {
> + depends_lib-append port:libcxx
> + configure.cxx_stdlib libc++
> + }
> + }
>
> - conflicts cmake-devel
> + # OSX <= 10.11 does not provide "clock_gettime"
> + legacysupport.newest_darwin_requires_legacy 15
> + # see https://trac.macports.org/ticket/59832
> + legacysupport.redirect_bins cmake
>
> long_description ${base_long_description} \
> The ${subport} release port is updated roughly every few months.
> @@ -72,282 +72,263 @@ if {${subport} eq ${name}} {
> patch-fix-system-prefix-path.release.diff \
> patch-cmake-leopard-tiger.release.diff \
> patch-fix-clock_gettime-test.release.diff
> -} else {
>
> - # devel
> + depends_lib-append \
> + port:curl \
> + port:expat \
> + port:zlib \
> + port:bzip2 \
> + port:libarchive \
> + port:ncurses
>
> - gitlab.setup cmake cmake 8638c49f
> - version 20200323-${gitlab.version}
> - checksums rmd160 e2b2fb0728376283ef35dd15a6f01de8540272e1 \
> - sha256 849ed895f1a8d2efd2ff5bd66ba414e28ab9aa43942a701e5a95eae7fdc32b23 \
> - size 6692910
> - revision 1
> + # allow use of libuv or libuv-devel;
> + # system libuv is the default as of 20160830 (g320f5)
> + depends_lib-append path:lib/pkgconfig/libuv.pc:libuv
>
> - conflicts cmake
> - long_description ${base_long_description} \
> - The ${subport} port is updated roughly every week.
> -
> - # devel-only patches
> - patchfiles-append \
> - patch-Modules-noArchCheck.devel.diff \
> - patch-CMakeFindFrameworks.cmake.devel.diff \
> - patch-Source_Modules_FindLibUV.cmake.devel.diff \
> - patch-fix_cxx14_17_checks.devel.diff \
> - patch-fix-system-prefix-path.devel.diff \
> - patch-cmake-leopard-tiger.devel.diff \
> - patch-fix-clock_gettime-test.devel.diff
> -}
> + # configure is just a shell script that passes directly to bootstrap
> + configure.cmd ./bootstrap
>
> -depends_lib-append port:curl \
> - port:expat \
> - port:zlib \
> - port:bzip2 \
> - port:libarchive \
> - port:ncurses
> -
> -# allow use of libuv or libuv-devel;
> -# system libuv is the default as of 20160830 (g320f5)
> -depends_lib-append path:lib/pkgconfig/libuv.pc:libuv
> -
> -# configure is just a shell script that passes directly to bootstrap
> -configure.cmd ./bootstrap
> -
> -# bootstrap takes cmake-style args for the build of the cmake to be installed.
> -# the args are passed as usual for cmake, after "--", so we pass them as post_args
> -configure.post_args --
> -
> -configure.env-append \
> - CMAKE_PREFIX_PATH=${prefix} \
> - CMAKE_INCLUDE_PATH=${prefix}/include/ncurses \
> - CMAKE_LIBRARY_PATH=${prefix}/lib
> -
> -# Check if the default compiler has yet to be installed. Used to prevent
> -# circular deps involving variants. Has to be tested here before our
> -# blacklisting and whitelisting is applied.
> -if {${os.platform} eq "darwin" && ${os.major} <= 10 && ${cxx_stdlib} eq "libc++" && ![file exists ${configure.cxx}]} {
> - set cmake_bootstrapping yes
> -}
> -
> -# On Lion, Clang 3.3 produces bad stream reading code when using libc++.
> -# See https://trac.macports.org/ticket/44129
> -# Clang 3.4 works. But Clang 3.7 doesn't work.
> -if {${os.platform} eq "darwin" && ${os.major} == 11 && ${configure.cxx_stdlib} eq "libc++"} {
> - compiler.whitelist macports-clang-3.4
> -}
> + # bootstrap takes cmake-style args for the build of the cmake to
> + # be installed. the args are passed as usual for cmake, after
> + # "--", so we pass them as post_args
> + configure.post_args --
>
> -# clang 3.4 can't build certain parts of the cmake self-testing infrastructure
> -# https://trac.macports.org/ticket/59782
> -if {${configure.compiler} eq "macports-clang-3.4"} {
> - configure.post_args-append -DBUILD_TESTING=OFF
> -}
> -
> -platform darwin {
> configure.env-append \
> - CMAKE_OSX_DEPLOYMENT_TARGET=${macosx_deployment_target}
> + CMAKE_PREFIX_PATH=${prefix} \
> + CMAKE_INCLUDE_PATH=${prefix}/include/ncurses \
> + CMAKE_LIBRARY_PATH=${prefix}/lib
> +
> + # Check if the default compiler has yet to be installed. Used to
> + # prevent circular deps involving variants. Has to be tested here
> + # before our blacklisting and whitelisting is applied.
> + if {${os.platform} eq "darwin" && ${os.major} <= 10 &&
> + ${cxx_stdlib} eq "libc++" && ![file exists ${configure.cxx}]} {
> + set cmake_bootstrapping yes
> + }
>
> - if {${configure.sdkroot} eq ""} {
> - configure.env-append SDKROOT=/
> + # On Lion, Clang 3.3 produces bad stream reading code when using
> + # libc++. See https://trac.macports.org/ticket/44129 . Clang 3.4
> + # works. But Clang 3.7 doesn't work.
> + if {${os.platform} eq "darwin" && ${os.major} == 11 &&
> + ${configure.cxx_stdlib} eq "libc++"} {
> + compiler.whitelist macports-clang-3.4
> }
>
> - if {${os.arch} eq "i386" && ${os.major} <= 9} {
> - # The old system headers do some bit shifting on Intel about which
> - # newer compilers throw errors:
> - # SecKeychain.h:102:46: error: shift expression '(1853123693 << 8)' overflows [-fpermissive]
> - configure.cflags-append -fpermissive
> - configure.cxxflags-append -fpermissive
> + # clang 3.4 can't build certain parts of the
> + # cmake self-testing infrastructure
> + # https://trac.macports.org/ticket/59782
> + if {${configure.compiler} eq "macports-clang-3.4"} {
> + configure.post_args-append -DBUILD_TESTING=OFF
> }
> -}
>
> -# jsoncpp 1.0+ requires CMake for building; circular dependencies are
> -# not possible in MacPorts. In addition, jsoncpp uses C++, so it would
> -# not be possible for CMake, which uses libc++ on 10.6-10.8, to link
> -# with a MacPorts copy of jsoncpp, which would usually use libstdc++
> -# on those systems. Fortunately CMake comes bundled with its own
> -# internal copy of jsoncpp, so we use that.
> + platform darwin {
> + configure.env-append \
> + CMAKE_OSX_DEPLOYMENT_TARGET=${macosx_deployment_target}
> +
> + if {${configure.sdkroot} eq ""} {
> + configure.env-append SDKROOT=/
> + }
>
> -configure.args-append --docdir=share/doc/cmake \
> - --parallel=${build.jobs} \
> - --init=${worksrcpath}/macports.cmake \
> - --system-libs \
> - --no-system-jsoncpp \
> - --no-system-librhash
> + if {${os.arch} eq "i386" && ${os.major} <= 9} {
> + # The old system headers do some bit shifting on Intel about which
> + # newer compilers throw errors:
> + # SecKeychain.h:102:46: error: shift expression '(1853123693 << 8)' overflows [-fpermissive]
> + configure.cflags-append -fpermissive
> + configure.cxxflags-append -fpermissive
> + }
> + }
>
> -configure.universal_args
> + # jsoncpp 1.0+ requires CMake for building; circular dependencies
> + # are not possible in MacPorts. In addition, jsoncpp uses C++, so
> + # it would not be possible for CMake, which uses libc++ on
> + # 10.6-10.8, to link with a MacPorts copy of jsoncpp, which would
> + # usually use libstdc++ on those systems. Fortunately CMake comes
> + # bundled with its own internal copy of jsoncpp, so we use that.
>
> -# CMake's configure script doesn't recognize `--host`.
> -array set merger_host {i386 {} x86_64 {} ppc {} ppc64 {}}
> + configure.args-append \
> + --docdir=share/doc/cmake \
> + --parallel=${build.jobs} \
> + --init=${worksrcpath}/macports.cmake \
> + --system-libs \
> + --no-system-jsoncpp \
> + --no-system-librhash
>
> -platform darwin 8 {
> - configure.ldflags-append -Wl,-framework -Wl,ApplicationServices
> -}
> + configure.universal_args
>
> -# Leopard's Rosetta has some difficulties configuring the ppc slice
> -platform darwin 9 {
> - global universal_archs_supported
> - if {${build_arch} eq "i386" || ${build_arch} eq "x86_64"} {
> - supported_archs i386 x86_64
> - } elseif {${build_arch} eq "ppc" || ${build_arch} eq "ppc64"} {
> - supported_archs ppc ppc64
> - }
> - set universal_archs_supported ${supported_archs}
> -}
> + # CMake's configure script doesn't recognize `--host`.
> + array set merger_host {i386 {} x86_64 {} ppc {} ppc64 {}}
>
> -build.post_args VERBOSE=ON
> + platform darwin 8 {
> + configure.ldflags-append -Wl,-framework -Wl,ApplicationServices
> + }
>
> -post-patch {
> - # copy cmake init file, ready to be patched below
> - copy ${filespath}/macports.cmake ${worksrcpath}
> + # Leopard's Rosetta has some difficulties configuring the ppc slice
> + platform darwin 9 {
> + global universal_archs_supported
> + if {${build_arch} eq "i386" || ${build_arch} eq "x86_64"} {
> + supported_archs i386 x86_64
> + } elseif {${build_arch} eq "ppc" || ${build_arch} eq "ppc64"} {
> + supported_archs ppc ppc64
> + }
> + set universal_archs_supported ${supported_archs}
> + }
>
> - # patch PREFIX
> - reinplace "s|__PREFIX__|${prefix}|g" \
> - ${worksrcpath}/macports.cmake \
> - ${worksrcpath}/Modules/CMakeFindFrameworks.cmake \
> - ${worksrcpath}/Modules/Platform/Darwin.cmake
> -}
> + build.post_args VERBOSE=ON
>
> -post-destroot {
> - xinstall -d -m 0755 ${destroot}${prefix}/share/emacs/site-lisp
> - xinstall -m 0644 ${worksrcpath}/Auxiliary/cmake-mode.el \
> - ${destroot}${prefix}/share/emacs/site-lisp
> - foreach type {syntax indent} {
> - xinstall -d -m 0755 ${destroot}${prefix}/share/vim/vimfiles/${type}
> - xinstall -m 0644 -W ${worksrcpath}/Auxiliary/vim/${type} cmake.vim \
> - ${destroot}${prefix}/share/vim/vimfiles/${type}
> - }
> - if ([variant_isset gui]) {
> - set app CMake
> - xinstall -d ${destroot}${applications_dir}/${app}.app/Contents/MacOS \
> - ${destroot}${applications_dir}/${app}.app/Contents/Resources
> - xinstall -m 644 ${filespath}/Info.plist.in ${destroot}${applications_dir}/${app}.app/Contents/Info.plist
> - reinplace "s|@VERSION@|${version}|g" ${destroot}${applications_dir}/${app}.app/Contents/Info.plist
> - reinplace "s|@PREFIX@|${prefix}|g" ${destroot}${applications_dir}/${app}.app/Contents/Info.plist
> - ln -s ${prefix}/bin/cmake-gui ${destroot}${applications_dir}/${app}.app/Contents/MacOS/cmake-gui
> - xinstall -m 644 ${worksrcpath}/Source/QtDialog/CMakeSetup.icns ${destroot}${applications_dir}/${app}.app/Contents/Resources/CMakeSetup.icns
> + post-patch {
> + # copy cmake init file, ready to be patched below
> + copy ${filespath}/macports.cmake ${worksrcpath}
> +
> + # patch PREFIX
> + reinplace "s|__PREFIX__|${prefix}|g" \
> + ${worksrcpath}/macports.cmake \
> + ${worksrcpath}/Modules/CMakeFindFrameworks.cmake \
> + ${worksrcpath}/Modules/Platform/Darwin.cmake
> }
> -}
>
> -# All the variants create circular dependencies on 10.6 with libc++,
> -# due to the default compiler needing cmake to build.
> -if {[info exists cmake_bootstrapping]} {
> - set some_variant_disabled 0
> - foreach vname {gui qt4 qt5 docs python35 python36 python37 python38} {
> - if {[variant_isset $vname]} {
> - unset ::variations($vname)
> - set some_variant_disabled 1
> + post-destroot {
> + xinstall -d -m 0755 ${destroot}${prefix}/share/emacs/site-lisp
> + xinstall -m 0644 ${worksrcpath}/Auxiliary/cmake-mode.el \
> + ${destroot}${prefix}/share/emacs/site-lisp
> + foreach type {syntax indent} {
> + xinstall -d -m 0755 ${destroot}${prefix}/share/vim/vimfiles/${type}
> + xinstall -m 0644 -W ${worksrcpath}/Auxiliary/vim/${type} cmake.vim \
> + ${destroot}${prefix}/share/vim/vimfiles/${type}
> + }
> + if ([variant_isset gui]) {
> + set app CMake
> + xinstall -d ${destroot}${applications_dir}/${app}.app/Contents/MacOS \
> + ${destroot}${applications_dir}/${app}.app/Contents/Resources
> + xinstall -m 644 ${filespath}/Info.plist.in ${destroot}${applications_dir}/${app}.app/Contents/Info.plist
> + reinplace "s|@VERSION@|${version}|g" ${destroot}${applications_dir}/${app}.app/Contents/Info.plist
> + reinplace "s|@PREFIX@|${prefix}|g" ${destroot}${applications_dir}/${app}.app/Contents/Info.plist
> + ln -s ${prefix}/bin/cmake-gui ${destroot}${applications_dir}/${app}.app/Contents/MacOS/cmake-gui
> + xinstall -m 644 ${worksrcpath}/Source/QtDialog/CMakeSetup.icns ${destroot}${applications_dir}/${app}.app/Contents/Resources/CMakeSetup.icns
> }
> }
> - if {$some_variant_disabled} {
> - notes-append "Installing $name with variants would create\
> - circular dependencies, so all variants have been\
> - deselected. You can install again with your desired\
> - variants after the default compiler has been installed."
> - }
> -}
>
> -variant gui description {Build Qt-based cmake-gui} {
> - configure.args-append --qt-gui
> -}
> -
> -variant qt4 conflicts qt5 requires gui description {Build Qt GUI using Qt4} {
> - PortGroup qt4 1.0
> - if {${subport} eq ${name}} {
> - patchfiles-append patch-qt4gui.release.diff
> - } else {
> - patchfiles-append patch-qt4gui.devel.diff
> + # All the variants create circular dependencies on 10.6 with libc++,
> + # due to the default compiler needing cmake to build.
> + if {[info exists cmake_bootstrapping]} {
> + set some_variant_disabled 0
> + foreach vname {gui qt4 qt5 docs python35 python36 python37 python38} {
> + if {[variant_isset $vname]} {
> + unset ::variations($vname)
> + set some_variant_disabled 1
> + }
> + }
> + if {$some_variant_disabled} {
> + notes-append "Installing $name with variants would create\
> + circular dependencies, so all variants have been\
> + deselected. You can install again with your desired\
> + variants after the default compiler has been installed."
> + }
> }
> - configure.args-append --qt-qmake=${qt_qmake_cmd}
> -}
>
> -variant qt5 conflicts qt4 requires gui description {Build Qt GUI using Qt5} {
> - PortGroup qt5 1.0
> - if {${subport} eq ${name}} {
> - patchfiles-append patch-qt5gui.release.diff
> - } else {
> - patchfiles-append patch-qt5gui.devel.diff
> + variant gui description {Build Qt-based cmake-gui} {
> + configure.args-append --qt-gui
> }
> - configure.args-append --qt-qmake=${qt_qmake_cmd}
> -}
>
> -if {[variant_isset gui]} {
> - if {![variant_isset qt4] && ![variant_isset qt5]} {
> - default_variants +qt4
> + variant qt4 conflicts qt5 requires gui description {Build Qt GUI using Qt4} {
> + PortGroup qt4 1.0
> + if {${subport} eq ${name}} {
> + patchfiles-append patch-qt4gui.release.diff
> + } else {
> + patchfiles-append patch-qt4gui.devel.diff
> + }
> + configure.args-append --qt-qmake=${qt_qmake_cmd}
> }
>
> - if {![variant_isset qt4] && ![variant_isset qt5]} {
> - ui_error "\n\nYou must select either the +qt4 or +qt5 variant when using variant +gui.\n"
> - return -code error "Invalid variant selection"
> + variant qt5 conflicts qt4 requires gui description {Build Qt GUI using Qt5} {
> + PortGroup qt5 1.0
> + if {${subport} eq ${name}} {
> + patchfiles-append patch-qt5gui.release.diff
> + } else {
> + patchfiles-append patch-qt5gui.devel.diff
> + }
> + configure.args-append --qt-qmake=${qt_qmake_cmd}
> }
> -} else {
> - configure.args-append --no-qt-gui
> -}
>
> -variant docs description {Build documentation: HTML and manpages} {
> + if {[variant_isset gui]} {
> + if {![variant_isset qt4] && ![variant_isset qt5]} {
> + default_variants +qt4
> + }
>
> - configure.args-append \
> - --mandir=share/man \
> - --sphinx-man \
> - --sphinx-html \
> - --sphinx-build=${prefix}/bin/sphinx-build-${PYTHON_VERSION_WITH_DOT}
> -
> - depends_build-append \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinx
> -
> - depends_build-append \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-applehelp \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-devhelp \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-htmlhelp \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-jsmath \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-qthelp \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-serializinghtml \
> - port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-websupport
> -}
> + if {![variant_isset qt4] && ![variant_isset qt5]} {
> + ui_error "\n\nYou must select either the +qt4 or +qt5 variant when using variant +gui.\n"
> + return -code error "Invalid variant selection"
> + }
> + } else {
> + configure.args-append --no-qt-gui
> + }
>
> -variant python35 conflicts python36 python37 python38 requires docs \
> - description {Build documentation using Sphinx from Python 3.5} {}
> + variant docs description {Build documentation: HTML and manpages} {
> +
> + configure.args-append \
> + --mandir=share/man \
> + --sphinx-man \
> + --sphinx-html \
> + --sphinx-build=${prefix}/bin/sphinx-build-${PYTHON_VERSION_WITH_DOT}
> +
> + depends_build-append \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinx
> +
> + depends_build-append \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-applehelp \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-devhelp \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-htmlhelp \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-jsmath \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-qthelp \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-serializinghtml \
> + port:py${PYTHON_VERSION_NO_DOT}-sphinxcontrib-websupport
> + }
>
> -variant python36 conflicts python35 python37 python38 requires docs \
> - description {Build documentation using Sphinx from Python 3.6} {}
> + variant python35 conflicts python36 python37 python38 requires docs \
> + description {Build documentation using Sphinx from Python 3.5} {}
>
> -variant python37 conflicts python35 python36 python38 requires docs \
> - description {Build documentation using Sphinx from Python 3.7} {}
> + variant python36 conflicts python35 python37 python38 requires docs \
> + description {Build documentation using Sphinx from Python 3.6} {}
>
> -variant python38 conflicts python35 python36 python37 requires docs \
> - description {Build documentation using Sphinx from Python 3.8} {}
> + variant python37 conflicts python35 python36 python38 requires docs \
> + description {Build documentation using Sphinx from Python 3.7} {}
>
> -if {[variant_isset docs]} {
> + variant python38 conflicts python35 python36 python37 requires docs \
> + description {Build documentation using Sphinx from Python 3.8} {}
>
> - # default Python is 3.6
> - if {![variant_isset python35] &&
> - ![variant_isset python36] &&
> - ![variant_isset python37] &&
> - ![variant_isset python38]} {
> - default_variants +python37
> - }
> + if {[variant_isset docs]} {
>
> - # make sure -python36 is not specified alone
> - if {![variant_isset python35] &&
> - ![variant_isset python36] &&
> - ![variant_isset python37] &&
> - ![variant_isset python38]} {
> - ui_error "\n\nYou must select either the +python35, +python36, +python37, or +python38 variant when using variant +docs.\n"
> - return -code error "Invalid variant selection"
> - }
> + # default Python is 3.6
> + if {![variant_isset python35] &&
> + ![variant_isset python36] &&
> + ![variant_isset python37] &&
> + ![variant_isset python38]} {
> + default_variants +python37
> + }
>
> - # determine Python-related variables
> - if {[variant_isset python35]} {
> - set PYTHON_VERSION_WITH_DOT "3.5"
> - } elseif {[variant_isset python36]} {
> - set PYTHON_VERSION_WITH_DOT "3.6"
> - } elseif {[variant_isset python37]} {
> - set PYTHON_VERSION_WITH_DOT "3.7"
> - } else {
> - set PYTHON_VERSION_WITH_DOT "3.8"
> - }
> - set PYTHON_VERSION_NO_DOT [join [split ${PYTHON_VERSION_WITH_DOT} "."] ""]
> + # make sure -python36 is not specified alone
> + if {![variant_isset python35] &&
> + ![variant_isset python36] &&
> + ![variant_isset python37] &&
> + ![variant_isset python38]} {
> + ui_error "\n\nYou must select either the +python35, +python36, +python37, or +python38 variant when using variant +docs.\n"
> + return -code error "Invalid variant selection"
> + }
>
> - post-patch {
> - # patch Python Version
> - reinplace "s|__PYTHON_VERSION_WITH_DOT__|${PYTHON_VERSION_WITH_DOT}|g" ${worksrcpath}/macports.cmake
> - }
> + # determine Python-related variables
> + if {[variant_isset python35]} {
> + set PYTHON_VERSION_WITH_DOT "3.5"
> + } elseif {[variant_isset python36]} {
> + set PYTHON_VERSION_WITH_DOT "3.6"
> + } elseif {[variant_isset python37]} {
> + set PYTHON_VERSION_WITH_DOT "3.7"
> + } else {
> + set PYTHON_VERSION_WITH_DOT "3.8"
> + }
> + set PYTHON_VERSION_NO_DOT [join [split ${PYTHON_VERSION_WITH_DOT} "."] ""]
>
> + post-patch {
> + # patch Python Version
> + reinplace "s|__PYTHON_VERSION_WITH_DOT__|${PYTHON_VERSION_WITH_DOT}|g" ${worksrcpath}/macports.cmake
> + }
> + }
> }
> diff --git a/devel/cmake/files/patch-CMakeFindFrameworks.cmake.devel.diff b/devel/cmake/files/patch-CMakeFindFrameworks.cmake.devel.diff
> deleted file mode 100644
> index 4d26bd8..0000000
> --- a/devel/cmake/files/patch-CMakeFindFrameworks.cmake.devel.diff
> +++ /dev/null
> @@ -1,11 +0,0 @@
> ---- Modules/CMakeFindFrameworks.cmake.orig
> -+++ Modules/CMakeFindFrameworks.cmake
> -@@ -22,7 +22,7 @@
> - ${CMAKE_FRAMEWORK_PATH}
> - ${_cmff_CMAKE_FRAMEWORK_PATH}
> - ~/Library/Frameworks
> -- /usr/local/Frameworks
> -+ __PREFIX__/Library/Frameworks/${fwk}.framework
> - /Library/Frameworks
> - /System/Library/Frameworks
> - /Network/Library/Frameworks
> diff --git a/devel/cmake/files/patch-Modules-noArchCheck.devel.diff b/devel/cmake/files/patch-Modules-noArchCheck.devel.diff
> deleted file mode 100644
> index 0338cf7..0000000
> --- a/devel/cmake/files/patch-Modules-noArchCheck.devel.diff
> +++ /dev/null
> @@ -1,72 +0,0 @@
> ---- Modules/BasicConfigVersion-AnyNewerVersion.cmake.in.orig
> -+++ Modules/BasicConfigVersion-AnyNewerVersion.cmake.in
> -@@ -23,15 +23,3 @@
> - if("@CVF_ARCH_INDEPENDENT@")
> - return()
> - endif()
> --
> --# if the installed or the using project don't have CMAKE_SIZEOF_VOID_P set, ignore it:
> --if("${CMAKE_SIZEOF_VOID_P}" STREQUAL "" OR "@CMAKE_SIZEOF_VOID_P@" STREQUAL "")
> -- return()
> --endif()
> --
> --# check that the installed version has the same 32/64bit-ness as the one which is currently searching:
> --if(NOT CMAKE_SIZEOF_VOID_P STREQUAL "@CMAKE_SIZEOF_VOID_P@")
> -- math(EXPR installedBits "@CMAKE_SIZEOF_VOID_P@ * 8")
> -- set(PACKAGE_VERSION "${PACKAGE_VERSION} (${installedBits}bit)")
> -- set(PACKAGE_VERSION_UNSUITABLE TRUE)
> --endif()
> ---- Modules/BasicConfigVersion-ExactVersion.cmake.in.orig
> -+++ Modules/BasicConfigVersion-ExactVersion.cmake.in
> -@@ -38,15 +38,3 @@
> - if("@CVF_ARCH_INDEPENDENT@")
> - return()
> - endif()
> --
> --# if the installed or the using project don't have CMAKE_SIZEOF_VOID_P set, ignore it:
> --if("${CMAKE_SIZEOF_VOID_P}" STREQUAL "" OR "@CMAKE_SIZEOF_VOID_P@" STREQUAL "")
> -- return()
> --endif()
> --
> --# check that the installed version has the same 32/64bit-ness as the one which is currently searching:
> --if(NOT CMAKE_SIZEOF_VOID_P STREQUAL "@CMAKE_SIZEOF_VOID_P@")
> -- math(EXPR installedBits "@CMAKE_SIZEOF_VOID_P@ * 8")
> -- set(PACKAGE_VERSION "${PACKAGE_VERSION} (${installedBits}bit)")
> -- set(PACKAGE_VERSION_UNSUITABLE TRUE)
> --endif()
> ---- Modules/BasicConfigVersion-SameMajorVersion.cmake.in.orig
> -+++ Modules/BasicConfigVersion-SameMajorVersion.cmake.in
> -@@ -37,15 +37,3 @@
> - if("@CVF_ARCH_INDEPENDENT@")
> - return()
> - endif()
> --
> --# if the installed or the using project don't have CMAKE_SIZEOF_VOID_P set, ignore it:
> --if("${CMAKE_SIZEOF_VOID_P}" STREQUAL "" OR "@CMAKE_SIZEOF_VOID_P@" STREQUAL "")
> -- return()
> --endif()
> --
> --# check that the installed version has the same 32/64bit-ness as the one which is currently searching:
> --if(NOT CMAKE_SIZEOF_VOID_P STREQUAL "@CMAKE_SIZEOF_VOID_P@")
> -- math(EXPR installedBits "@CMAKE_SIZEOF_VOID_P@ * 8")
> -- set(PACKAGE_VERSION "${PACKAGE_VERSION} (${installedBits}bit)")
> -- set(PACKAGE_VERSION_UNSUITABLE TRUE)
> --endif()
> ---- Modules/BasicConfigVersion-SameMinorVersion.cmake.in.orig
> -+++ Modules/BasicConfigVersion-SameMinorVersion.cmake.in
> -@@ -41,15 +41,3 @@
> - if("@CVF_ARCH_INDEPENDENT@")
> - return()
> - endif()
> --
> --# if the installed or the using project don't have CMAKE_SIZEOF_VOID_P set, ignore it:
> --if("${CMAKE_SIZEOF_VOID_P}" STREQUAL "" OR "@CMAKE_SIZEOF_VOID_P@" STREQUAL "")
> -- return()
> --endif()
> --
> --# check that the installed version has the same 32/64bit-ness as the one which is currently searching:
> --if(NOT CMAKE_SIZEOF_VOID_P STREQUAL "@CMAKE_SIZEOF_VOID_P@")
> -- math(EXPR installedBits "@CMAKE_SIZEOF_VOID_P@ * 8")
> -- set(PACKAGE_VERSION "${PACKAGE_VERSION} (${installedBits}bit)")
> -- set(PACKAGE_VERSION_UNSUITABLE TRUE)
> --endif()
> diff --git a/devel/cmake/files/patch-Source_Modules_FindLibUV.cmake.devel.diff b/devel/cmake/files/patch-Source_Modules_FindLibUV.cmake.devel.diff
> deleted file mode 100644
> index 1b5b3db..0000000
> --- a/devel/cmake/files/patch-Source_Modules_FindLibUV.cmake.devel.diff
> +++ /dev/null
> @@ -1,13 +0,0 @@
> ---- Source/Modules/FindLibUV.cmake.orig
> -+++ Source/Modules/FindLibUV.cmake
> -@@ -61,7 +61,9 @@
> - #-----------------------------------------------------------------------------
> - # Extract version number if possible.
> - set(_LibUV_H_REGEX "#[ \t]*define[ \t]+UV_VERSION_(MAJOR|MINOR|PATCH)[ \t]+[0-9]+")
> --if(LibUV_INCLUDE_DIR AND EXISTS "${LibUV_INCLUDE_DIR}/uv-version.h")
> -+if(LibUV_INCLUDE_DIR AND EXISTS "${LibUV_INCLUDE_DIR}/uv/version.h")
> -+ file(STRINGS "${LibUV_INCLUDE_DIR}/uv/version.h" _LibUV_H REGEX "${_LibUV_H_REGEX}")
> -+elseif(LibUV_INCLUDE_DIR AND EXISTS "${LibUV_INCLUDE_DIR}/uv-version.h")
> - file(STRINGS "${LibUV_INCLUDE_DIR}/uv-version.h" _LibUV_H REGEX "${_LibUV_H_REGEX}")
> - elseif(LibUV_INCLUDE_DIR AND EXISTS "${LibUV_INCLUDE_DIR}/uv/version.h")
> - file(STRINGS "${LibUV_INCLUDE_DIR}/uv/version.h" _LibUV_H REGEX "${_LibUV_H_REGEX}")
> diff --git a/devel/cmake/files/patch-cmake-leopard-tiger.devel.diff b/devel/cmake/files/patch-cmake-leopard-tiger.devel.diff
> deleted file mode 100644
> index ce70486..0000000
> --- a/devel/cmake/files/patch-cmake-leopard-tiger.devel.diff
> +++ /dev/null
> @@ -1,119 +0,0 @@
> -kencu at macports.org
> -The <memory> header seems to be needed if building with gcc/libstdc++ on MacOS
> -adding it does no harm to clang/libc++ builds
> -it must be somehow automatically included with the libc++ headers
> -
> -diff --git Source/cmMachO.h Source/cmMachO.h
> -index 0c44b55..06c39db 100644
> ---- Source/cmMachO.h
> -+++ Source/cmMachO.h
> -@@ -7,6 +7,7 @@
> -
> - #include <iosfwd>
> - #include <string>
> -+#include <memory>
> -
> - #if !defined(CMAKE_USE_MACH_PARSER)
> - # error "This file may be included only if CMAKE_USE_MACH_PARSER is enabled."
> ----
> -
> -kencu at macports.org
> -The patches below match the tiger patches in the libuv port.
> -
> -Although cmake is configured to use the system libuv, it appears that the
> -bootstrap version of cmake uses a more current version, and that is a moving
> -target as libuv advances.
> -
> -At some point we may have to switch to an older bootstrap version of cmake,
> -if libuv becomes too difficult to keep up-to-date.
> -
> -diff --git Utilities/cmlibuv/src/unix/core.c Utilities/cmlibuv/src/unix/core.c
> -index cf7dea0..b48ca73 100644
> ---- Utilities/cmlibuv/src/unix/core.c
> -+++ Utilities/cmlibuv/src/unix/core.c
> -@@ -525,10 +525,24 @@ skip:
> - * will unwind the thread when it's in the cancel state. Work around that
> - * by making the system call directly. Musl libc is unaffected.
> - */
> -+
> -+#if defined(__GNUC__)
> -+#define GCC_VERSION \
> -+ (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__)
> -+#endif
> -+#if defined(__clang__) || (defined(GCC_VERSION) && (GCC_VERSION >= 40500))
> -+/* gcc diagnostic pragmas available */
> -+# define GCC_DIAGNOSTIC_AVAILABLE
> -+#endif
> -+
> - int uv__close_nocancel(int fd) {
> --#if defined(__APPLE__)
> -+#if defined(__APPLE__) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1050
> -+
> -+#if defined(GCC_DIAGNOSTIC_AVAILABLE)
> - #pragma GCC diagnostic push
> - #pragma GCC diagnostic ignored "-Wdollar-in-identifier-extension"
> -+#endif
> -+
> - #if defined(__LP64__)
> - extern int close$NOCANCEL(int);
> - return close$NOCANCEL(fd);
> -@@ -536,7 +550,11 @@ int uv__close_nocancel(int fd) {
> - extern int close$NOCANCEL$UNIX2003(int);
> - return close$NOCANCEL$UNIX2003(fd);
> - #endif
> -+
> -+#if defined(GCC_DIAGNOSTIC_AVAILABLE)
> - #pragma GCC diagnostic pop
> -+#endif
> -+
> - #elif defined(__linux__)
> - return syscall(SYS_close, fd);
> - #else
> -@@ -1306,8 +1324,12 @@ int uv_os_unsetenv(const char* name) {
> - if (name == NULL)
> - return UV_EINVAL;
> -
> -+#if ( defined(__APPLE__) && MAC_OS_X_VERSION_MAX_ALLOWED < 1050)
> -+ unsetenv(name);
> -+#else
> - if (unsetenv(name) != 0)
> - return UV__ERR(errno);
> -+#endif
> -
> - return 0;
> - }
> -diff --git Utilities/cmlibuv/src/unix/fs.c Utilities/cmlibuv/src/unix/fs.c
> -index 5fb34f1..7453980 100644
> ---- Utilities/cmlibuv/src/unix/fs.c
> -+++ Utilities/cmlibuv/src/unix/fs.c
> -@@ -743,7 +743,7 @@ static ssize_t uv__fs_sendfile(uv_fs_t* req) {
> -
> - return -1;
> - }
> --#elif defined(__APPLE__) || \
> -+#elif defined(__APPLE__) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1050 || \
> - defined(__DragonFly__) || \
> - defined(__FreeBSD__) || \
> - defined(__FreeBSD_kernel__)
> -@@ -1055,7 +1055,7 @@ static void uv__to_stat(struct stat* src, uv_stat_t* dst) {
> - dst->st_blksize = src->st_blksize;
> - dst->st_blocks = src->st_blocks;
> -
> --#if defined(__APPLE__)
> -+#if defined(__APPLE__) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1050
> - dst->st_atim.tv_sec = src->st_atimespec.tv_sec;
> - dst->st_atim.tv_nsec = src->st_atimespec.tv_nsec;
> - dst->st_mtim.tv_sec = src->st_mtimespec.tv_sec;
> -diff --git Utilities/cmlibuv/src/unix/tty.c Utilities/cmlibuv/src/unix/tty.c
> -index db479d6..5a7a86b 100644
> ---- Utilities/cmlibuv/src/unix/tty.c
> -+++ Utilities/cmlibuv/src/unix/tty.c
> -@@ -44,7 +44,7 @@ static int uv__tty_is_slave(const int fd) {
> - int dummy;
> -
> - result = ioctl(fd, TIOCGPTN, &dummy) != 0;
> --#elif defined(__APPLE__)
> -+#elif defined(__APPLE__) && MAC_OS_X_VERSION_MAX_ALLOWED >= 1050
> - char dummy[256];
> -
> - result = ioctl(fd, TIOCPTYGNAME, &dummy) != 0;
> diff --git a/devel/cmake/files/patch-fix-clock_gettime-test.devel.diff b/devel/cmake/files/patch-fix-clock_gettime-test.devel.diff
> deleted file mode 100644
> index 2f78ccd..0000000
> --- a/devel/cmake/files/patch-fix-clock_gettime-test.devel.diff
> +++ /dev/null
> @@ -1,15 +0,0 @@
> ---- Source/kwsys/kwsysPlatformTestsC.c.orig 2020-03-04 06:50:44.000000000 -0700
> -+++ Source/kwsys/kwsysPlatformTestsC.c 2020-03-17 03:35:40.000000000 -0700
> -@@ -56,12 +56,6 @@
> - #endif
> -
> - #ifdef TEST_KWSYS_C_HAS_CLOCK_GETTIME_MONOTONIC
> --# if defined(__APPLE__)
> --# include <AvailabilityMacros.h>
> --# if MAC_OS_X_VERSION_MIN_REQUIRED < 101200
> --# error "clock_gettime not available on macOS < 10.12"
> --# endif
> --# endif
> - # include <time.h>
> - int KWSYS_PLATFORM_TEST_C_MAIN()
> - {
> diff --git a/devel/cmake/files/patch-fix-system-prefix-path.devel.diff b/devel/cmake/files/patch-fix-system-prefix-path.devel.diff
> deleted file mode 100644
> index 0b2221e..0000000
> --- a/devel/cmake/files/patch-fix-system-prefix-path.devel.diff
> +++ /dev/null
> @@ -1,75 +0,0 @@
> ---- Modules/Platform/Darwin.cmake.orig
> -+++ Modules/Platform/Darwin.cmake
> -@@ -207,6 +207,12 @@
> - ${_apps_paths})
> - unset(_apps_paths)
> -
> -+# add to CMAKE_SYSTEM_PREFIX_PATH
> -+# might already exist before this if the user has specified it
> -+list(APPEND CMAKE_SYSTEM_PREFIX_PATH
> -+ __PREFIX__ # MacPorts
> -+)
> -+
> - include(Platform/UnixPaths)
> - if(_CMAKE_OSX_SYSROOT_PATH AND EXISTS ${_CMAKE_OSX_SYSROOT_PATH}/usr/include)
> - list(APPEND CMAKE_SYSTEM_PREFIX_PATH ${_CMAKE_OSX_SYSROOT_PATH}/usr)
> -@@ -214,7 +220,3 @@
> - list(APPEND _CMAKE_${lang}_IMPLICIT_INCLUDE_DIRECTORIES_INIT ${_CMAKE_OSX_SYSROOT_PATH}/usr/include)
> - endforeach()
> - endif()
> --list(APPEND CMAKE_SYSTEM_PREFIX_PATH
> -- /sw # Fink
> -- /opt/local # MacPorts
> -- )
> ---- Modules/Platform/UnixPaths.cmake.orig
> -+++ Modules/Platform/UnixPaths.cmake
> -@@ -23,22 +23,39 @@
> - # search types.
> - list(APPEND CMAKE_SYSTEM_PREFIX_PATH
> - # Standard
> -- /usr/local /usr /
> -+ /usr /
> -+)
> -
> -- # CMake install location
> -- "${_CMAKE_INSTALL_DIR}"
> -- )
> --if (NOT CMAKE_FIND_NO_INSTALL_PREFIX)
> -+# CMake install location
> -+# append the _CMAKE_INSTALL_DIR if not already in the list
> -+list(FIND CMAKE_SYSTEM_PREFIX_PATH "${_CMAKE_INSTALL_DIR}" HAS_ENTRY)
> -+if(${HAS_ENTRY} EQUAL -1)
> - list(APPEND CMAKE_SYSTEM_PREFIX_PATH
> -- # Project install destination.
> -- "${CMAKE_INSTALL_PREFIX}"
> -+ "${_CMAKE_INSTALL_DIR}"
> - )
> -- if(CMAKE_STAGING_PREFIX)
> -+endif()
> -+unset(HAS_ENTRY)
> -+
> -+if(NOT CMAKE_FIND_NO_INSTALL_PREFIX)
> -+ # append the CMAKE_INSTALL_PREFIX if not already in the list
> -+ list(FIND CMAKE_SYSTEM_PREFIX_PATH "${CMAKE_INSTALL_PREFIX}" HAS_ENTRY)
> -+ if(${HAS_ENTRY} EQUAL -1)
> - list(APPEND CMAKE_SYSTEM_PREFIX_PATH
> -- # User-supplied staging prefix.
> -- "${CMAKE_STAGING_PREFIX}"
> -+ # Project install destination.
> -+ "${CMAKE_INSTALL_PREFIX}"
> - )
> - endif()
> -+ unset(HAS_ENTRY)
> -+ if(CMAKE_STAGING_PREFIX)
> -+ # append the CMAKE_STAGING_PREFIX if not already in the list
> -+ list(FIND CMAKE_SYSTEM_PREFIX_PATH "${CMAKE_STAGING_PREFIX}" HAS_ENTRY)
> -+ if(${HAS_ENTRY} EQUAL -1)
> -+ list(APPEND CMAKE_SYSTEM_PREFIX_PATH
> -+ # User-supplied staging prefix.
> -+ "${CMAKE_STAGING_PREFIX}"
> -+ )
> -+ endif()
> -+ endif()
> - endif()
> -
> - # Non "standard" but common install prefixes
> diff --git a/devel/cmake/files/patch-fix_cxx14_17_checks.devel.diff b/devel/cmake/files/patch-fix_cxx14_17_checks.devel.diff
> deleted file mode 100644
> index 931fedd..0000000
> --- a/devel/cmake/files/patch-fix_cxx14_17_checks.devel.diff
> +++ /dev/null
> @@ -1,63 +0,0 @@
> ---- Source/Checks/cm_cxx14_check.cpp.orig
> -+++ Source/Checks/cm_cxx14_check.cpp
> -@@ -1,9 +1,18 @@
> -+// actually use c++14 feature to force the compiler to do something,
> -+// since it might otherwise try to optimize all of this out even if it
> -+// doesn't understand it.
> -+#include <iostream>
> -+
> - #include <cstdio>
> - #include <iterator>
> - #include <memory>
> -
> - int main()
> - {
> -+ std::unique_ptr < int > foo = std::make_unique < int > (4);
> -+ std::cout << "std::make_unique < int >(4) is '"
> -+ << *foo << "'" << std::endl;
> -+
> - int a[] = { 0, 1, 2 };
> - auto ai = std::cbegin(a);
> -
> ---- Source/Checks/cm_cxx17_check.cpp.orig
> -+++ Source/Checks/cm_cxx17_check.cpp
> -@@ -1,3 +1,9 @@
> -+// actually use c++17 feature to force the compiler to do something,
> -+// since it might otherwise try to optimize all of this out even if it
> -+// doesn't understand it.
> -+#include <iostream>
> -+#include <string>
> -+
> - #include <cstdio>
> - #include <iterator>
> - #include <memory>
> -@@ -15,6 +21,15 @@
> - return item.get();
> - }
> -
> -+std::optional < std::string >
> -+create
> -+(bool b) {
> -+ if (b) {
> -+ return "foo!";
> -+ }
> -+ return {};
> -+}
> -+
> - int main()
> - {
> - int a[] = { 0, 1, 2 };
> -@@ -38,6 +53,13 @@
> - IDispatchPtr disp(ptr);
> - #endif
> -
> -+ std::cout << "create(false) returned "
> -+ << create(false).value_or("empty")
> -+ << std::endl;
> -+ std::cout << "create(true) returned "
> -+ << create(true).value_or("empty")
> -+ << std::endl;
> -+
> - std::optional<int> oi = 0;
> -
> - return *u + *ai + *(bi - 1) + (3 - static_cast<int>(ci)) + oi.value();
> diff --git a/devel/cmake/files/patch-qt4gui.devel.diff b/devel/cmake/files/patch-qt4gui.devel.diff
> deleted file mode 100644
> index 058a917..0000000
> --- a/devel/cmake/files/patch-qt4gui.devel.diff
> +++ /dev/null
> @@ -1,172 +0,0 @@
> ---- Source/QtDialog/CMakeLists.txt.orig
> -+++ Source/QtDialog/CMakeLists.txt
> -@@ -3,100 +3,6 @@
> -
> - project(QtDialog)
> - CMake_OPTIONAL_COMPONENT(cmake-gui)
> --find_package(Qt5Widgets QUIET)
> --if (Qt5Widgets_FOUND)
> -- include_directories(${Qt5Widgets_INCLUDE_DIRS})
> -- add_definitions(${Qt5Widgets_DEFINITONS})
> -- macro(qt4_wrap_ui)
> -- qt5_wrap_ui(${ARGN})
> -- endmacro()
> -- macro(qt4_wrap_cpp)
> -- qt5_wrap_cpp(${ARGN})
> -- endmacro()
> -- macro(qt4_add_resources)
> -- qt5_add_resources(${ARGN})
> -- endmacro()
> --
> -- set(CMake_QT_LIBRARIES ${Qt5Widgets_LIBRARIES})
> -- set(QT_QTMAIN_LIBRARY ${Qt5Core_QTMAIN_LIBRARIES})
> --
> -- # Try to find the package WinExtras for the task bar progress
> -- if(WIN32)
> -- find_package(Qt5WinExtras QUIET)
> -- if (Qt5WinExtras_FOUND)
> -- include_directories(${Qt5WinExtras_INCLUDE_DIRS})
> -- add_definitions(-DQT_WINEXTRAS)
> -- list(APPEND CMake_QT_LIBRARIES ${Qt5WinExtras_LIBRARIES})
> -- endif()
> -- endif()
> --
> -- # Remove this when the minimum version of Qt is 4.6.
> -- add_definitions(-DQT_DISABLE_DEPRECATED_BEFORE=0)
> --
> -- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${Qt5Widgets_EXECUTABLE_COMPILE_FLAGS}")
> --
> -- if(CMake_QT_STATIC_QXcbIntegrationPlugin_LIBRARIES)
> -- list(APPEND CMake_QT_LIBRARIES ${CMake_QT_STATIC_QXcbIntegrationPlugin_LIBRARIES})
> -- set_property(SOURCE CMakeSetup.cxx
> -- PROPERTY COMPILE_DEFINITIONS USE_QXcbIntegrationPlugin)
> -- endif()
> --
> -- if(CMake_QT_STATIC_QWindowsIntegrationPlugin_LIBRARIES)
> -- list(APPEND CMake_QT_LIBRARIES ${CMake_QT_STATIC_QWindowsIntegrationPlugin_LIBRARIES})
> -- set_property(SOURCE CMakeSetup.cxx
> -- PROPERTY COMPILE_DEFINITIONS USE_QWindowsIntegrationPlugin)
> -- endif()
> --
> -- # We need to install platform plugin and add qt.conf for Qt5 on Mac and Windows.
> -- # FIXME: This should be part of Qt5 CMake scripts, but unfortunately
> -- # Qt5 support is missing there.
> -- if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
> -- macro(install_qt5_plugin _qt_plugin_name _qt_plugins_var)
> -- get_target_property(_qt_plugin_path "${_qt_plugin_name}" LOCATION)
> -- if(EXISTS "${_qt_plugin_path}")
> -- get_filename_component(_qt_plugin_file "${_qt_plugin_path}" NAME)
> -- get_filename_component(_qt_plugin_type "${_qt_plugin_path}" PATH)
> -- get_filename_component(_qt_plugin_type "${_qt_plugin_type}" NAME)
> -- if(APPLE)
> -- set(_qt_plugin_dir "PlugIns")
> -- elseif(WIN32)
> -- set(_qt_plugin_dir "plugins")
> -- endif()
> -- set(_qt_plugin_dest "${_qt_plugin_dir}/${_qt_plugin_type}")
> -- install(FILES "${_qt_plugin_path}"
> -- DESTINATION "${_qt_plugin_dest}"
> -- ${COMPONENT})
> -- set(${_qt_plugins_var}
> -- "${${_qt_plugins_var}};\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${_qt_plugin_dest}/${_qt_plugin_file}")
> -- else()
> -- message(FATAL_ERROR "QT plugin ${_qt_plugin_name} not found")
> -- endif()
> -- endmacro()
> -- if(APPLE)
> -- install_qt5_plugin("Qt5::QCocoaIntegrationPlugin" QT_PLUGINS)
> -- file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/qt.conf"
> -- "[Paths]\nPlugins = ${_qt_plugin_dir}\n")
> -- install(FILES "${CMAKE_CURRENT_BINARY_DIR}/qt.conf"
> -- DESTINATION "${CMAKE_INSTALL_PREFIX}/Resources"
> -- ${COMPONENT})
> -- elseif(WIN32 AND NOT CMake_QT_STATIC_QWindowsIntegrationPlugin_LIBRARIES)
> -- install_qt5_plugin("Qt5::QWindowsIntegrationPlugin" QT_PLUGINS)
> -- file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/qt.conf"
> -- "[Paths]\nPlugins = ../${_qt_plugin_dir}\n")
> -- install(FILES "${CMAKE_CURRENT_BINARY_DIR}/qt.conf"
> -- DESTINATION bin
> -- ${COMPONENT})
> -- endif()
> -- endif()
> --
> -- if(TARGET Qt5::Core)
> -- get_property(_Qt5_Core_LOCATION TARGET Qt5::Core PROPERTY LOCATION)
> -- get_filename_component(Qt_BIN_DIR "${_Qt5_Core_LOCATION}" PATH)
> -- if(APPLE)
> -- get_filename_component(Qt_BIN_DIR "${Qt_BIN_DIR}" PATH)
> -- endif()
> -- endif()
> --else()
> - set(QT_MIN_VERSION "4.4.0")
> - find_package(Qt4 REQUIRED)
> - if(NOT QT4_FOUND)
> -@@ -108,8 +14,6 @@ else()
> -
> - set(CMake_QT_LIBRARIES ${QT_LIBRARIES})
> -
> --endif()
> --
> - set(SRCS
> - AddCacheEntry.cxx
> - AddCacheEntry.h
> -@@ -154,7 +58,7 @@ set(SRCS ${SRCS} ${UI_SRCS} ${MOC_SRCS} ${RC_SRCS})
> - if(WIN32)
> - set(SRCS ${SRCS} CMakeSetup.rc)
> - endif()
> --if(APPLE)
> -+if(APPLEBUNDLE)
> - set(SRCS ${SRCS} CMakeSetup.icns)
> - set(MACOSX_BUNDLE_ICON_FILE CMakeSetup.icns)
> - set_source_files_properties(CMakeSetup.icns PROPERTIES
> -@@ -171,7 +75,7 @@ endif()
> -
> - set(CMAKE_INCLUDE_CURRENT_DIR ON)
> -
> --add_executable(cmake-gui WIN32 MACOSX_BUNDLE ${SRCS} ${MANIFEST_FILE})
> -+add_executable(cmake-gui WIN32 ${SRCS} ${MANIFEST_FILE})
> - target_link_libraries(cmake-gui CMakeLib ${QT_QTMAIN_LIBRARY} ${CMake_QT_LIBRARIES})
> -
> - if(WIN32)
> -@@ -201,7 +105,7 @@ Checks: '-*,llvm-twine-local'
> - ...
> - ")
> -
> --if(APPLE)
> -+if(APPLEBUNDLE)
> - file(STRINGS "${CMake_SOURCE_DIR}/Copyright.txt" copyright_line
> - LIMIT_COUNT 1 REGEX "^Copyright 2000-20[0-9][0-9] Kitware")
> -
> -@@ -247,7 +151,7 @@ if(UNIX AND NOT APPLE)
> - ${COMPONENT})
> - endif()
> -
> --if(APPLE)
> -+if(APPLEBUNDLE)
> - install(CODE "
> - execute_process(COMMAND ln -s \"../MacOS/CMake\" cmake-gui
> - WORKING_DIRECTORY \$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/bin)
> -@@ -258,7 +162,7 @@ if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
> - # install rules for including 3rd party libs such as Qt
> - # if a system Qt is used (e.g. installed in /usr/lib/), it will not be included in the installation
> - set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/bin/cmake-gui${CMAKE_EXECUTABLE_SUFFIX}")
> -- if(APPLE)
> -+ if(APPLEBUNDLE)
> - set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/MacOS/CMake")
> - endif()
> - install(CODE "
> ---- CMakeLists.txt.orig
> -+++ CMakeLists.txt
> -@@ -718,12 +718,6 @@
> - set(CMAKE_BUNDLE_VERSION
> - "${CMake_VERSION_MAJOR}.${CMake_VERSION_MINOR}.${CMake_VERSION_PATCH}")
> - set(CMAKE_BUNDLE_LOCATION "${CMAKE_INSTALL_PREFIX}")
> -- # make sure CMAKE_INSTALL_PREFIX ends in /
> -- if(NOT CMAKE_INSTALL_PREFIX MATCHES "/$")
> -- set(CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}/")
> -- endif()
> -- set(CMAKE_INSTALL_PREFIX
> -- "${CMAKE_INSTALL_PREFIX}CMake.app/Contents")
> - endif()
> - endif()
> -
> diff --git a/devel/cmake/files/patch-qt5gui.devel.diff b/devel/cmake/files/patch-qt5gui.devel.diff
> deleted file mode 100644
> index c0b69d9b..0000000
> --- a/devel/cmake/files/patch-qt5gui.devel.diff
> +++ /dev/null
> @@ -1,93 +0,0 @@
> ---- Source/QtDialog/CMakeLists.txt.orig
> -+++ Source/QtDialog/CMakeLists.txt
> -@@ -4,7 +4,9 @@
> - project(QtDialog)
> - CMake_OPTIONAL_COMPONENT(cmake-gui)
> - find_package(Qt5Widgets QUIET)
> --if (Qt5Widgets_FOUND)
> -+if(NOT Qt5Widgets_FOUND)
> -+ message(FATAL_ERROR "Qt5 required but not found")
> -+endif()
> - include_directories(${Qt5Widgets_INCLUDE_DIRS})
> - add_definitions(${Qt5Widgets_DEFINITONS})
> - macro(qt4_wrap_ui)
> -@@ -96,19 +98,6 @@ if (Qt5Widgets_FOUND)
> - get_filename_component(Qt_BIN_DIR "${Qt_BIN_DIR}" PATH)
> - endif()
> - endif()
> --else()
> -- set(QT_MIN_VERSION "4.4.0")
> -- find_package(Qt4 REQUIRED)
> -- if(NOT QT4_FOUND)
> -- message(SEND_ERROR "Failed to find Qt 4.4 or greater.")
> -- return()
> -- endif()
> --
> -- include(${QT_USE_FILE})
> --
> -- set(CMake_QT_LIBRARIES ${QT_LIBRARIES})
> --
> --endif()
> -
> - set(SRCS
> - AddCacheEntry.cxx
> -@@ -154,7 +143,7 @@ set(SRCS ${SRCS} ${UI_SRCS} ${MOC_SRCS} ${RC_SRCS})
> - if(WIN32)
> - set(SRCS ${SRCS} CMakeSetup.rc)
> - endif()
> --if(APPLE)
> -+if(APPLEBUNDLE)
> - set(SRCS ${SRCS} CMakeSetup.icns)
> - set(MACOSX_BUNDLE_ICON_FILE CMakeSetup.icns)
> - set_source_files_properties(CMakeSetup.icns PROPERTIES
> -@@ -171,7 +160,7 @@ endif()
> -
> - set(CMAKE_INCLUDE_CURRENT_DIR ON)
> -
> --add_executable(cmake-gui WIN32 MACOSX_BUNDLE ${SRCS} ${MANIFEST_FILE})
> -+add_executable(cmake-gui WIN32 ${SRCS} ${MANIFEST_FILE})
> - target_link_libraries(cmake-gui CMakeLib ${QT_QTMAIN_LIBRARY} ${CMake_QT_LIBRARIES})
> -
> - if(WIN32)
> -@@ -201,7 +190,7 @@ Checks: '-*,llvm-twine-local'
> - ...
> - ")
> -
> --if(APPLE)
> -+if(APPLEBUNDLE)
> - file(STRINGS "${CMake_SOURCE_DIR}/Copyright.txt" copyright_line
> - LIMIT_COUNT 1 REGEX "^Copyright 2000-20[0-9][0-9] Kitware")
> -
> -@@ -247,7 +236,7 @@ if(UNIX AND NOT APPLE)
> - ${COMPONENT})
> - endif()
> -
> --if(APPLE)
> -+if(APPLEBUNDLE)
> - install(CODE "
> - execute_process(COMMAND ln -s \"../MacOS/CMake\" cmake-gui
> - WORKING_DIRECTORY \$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/bin)
> -@@ -258,7 +247,7 @@ if(CMake_INSTALL_DEPENDENCIES AND (APPLE OR WIN32))
> - # install rules for including 3rd party libs such as Qt
> - # if a system Qt is used (e.g. installed in /usr/lib/), it will not be included in the installation
> - set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/bin/cmake-gui${CMAKE_EXECUTABLE_SUFFIX}")
> -- if(APPLE)
> -+ if(APPLEBUNDLE)
> - set(fixup_exe "\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/MacOS/CMake")
> - endif()
> - install(CODE "
> ---- CMakeLists.txt.orig
> -+++ CMakeLists.txt
> -@@ -718,12 +718,6 @@
> - set(CMAKE_BUNDLE_VERSION
> - "${CMake_VERSION_MAJOR}.${CMake_VERSION_MINOR}.${CMake_VERSION_PATCH}")
> - set(CMAKE_BUNDLE_LOCATION "${CMAKE_INSTALL_PREFIX}")
> -- # make sure CMAKE_INSTALL_PREFIX ends in /
> -- if(NOT CMAKE_INSTALL_PREFIX MATCHES "/$")
> -- set(CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}/")
> -- endif()
> -- set(CMAKE_INSTALL_PREFIX
> -- "${CMAKE_INSTALL_PREFIX}CMake.app/Contents")
> - endif()
> - endif()
> -
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macports.org/pipermail/macports-dev/attachments/20200414/e707deb7/attachment-0001.html>
More information about the macports-dev
mailing list