From 1831ce4bcc6f0ca18c3425563bc2de8857f30e41 Mon Sep 17 00:00:00 2001 From: sigman Date: Wed, 7 Jun 2017 22:08:08 +0300 Subject: [PATCH 01/50] Magnum OpengGL 3d library port Added ports to support Magnum C++ OpenGL engine http://mosra.cz/blog/magnum.php and its direct dependencies --- ports/corrade/CONTROL | 3 +++ ports/corrade/portfile.cmake | 45 ++++++++++++++++++++++++++++++++++++ ports/magnum/CONTROL | 4 ++++ ports/magnum/portfile.cmake | 33 ++++++++++++++++++++++++++ 4 files changed, 85 insertions(+) create mode 100644 ports/corrade/CONTROL create mode 100644 ports/corrade/portfile.cmake create mode 100644 ports/magnum/CONTROL create mode 100644 ports/magnum/portfile.cmake diff --git a/ports/corrade/CONTROL b/ports/corrade/CONTROL new file mode 100644 index 000000000..487766e89 --- /dev/null +++ b/ports/corrade/CONTROL @@ -0,0 +1,3 @@ +Source: corrade +Version: jun2017 +Description: C++11/C++14 multiplatform utility library http://mosra.cz/blog/corrade.php diff --git a/ports/corrade/portfile.cmake b/ports/corrade/portfile.cmake new file mode 100644 index 000000000..91251ea6b --- /dev/null +++ b/ports/corrade/portfile.cmake @@ -0,0 +1,45 @@ +# + +set(CORRADE_HASH b87c50db3543367b6eb20dc72246c6687449b029) + +include(vcpkg_common_functions) + + +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/corrade-${CORRADE_HASH}) +vcpkg_download_distfile(ARCHIVE + URLS "https://github.com/mosra/corrade/archive/${CORRADE_HASH}.zip" + FILENAME "corrade-${CORRADE_HASH}.zip" + SHA512 b15b544f996b8c95fbdf73ff9b76deea465fdcf06f431b09f4bbb9a786f4e864fdb4f8c5a2977cb366ee2398c54eac4c469da29c2ab7c67d3b8f7cbf7d2120dc +) +vcpkg_extract_source_archive(${ARCHIVE}) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA # Disable this option if project cannot be built with Ninja + # OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2 + # OPTIONS_RELEASE -DOPTIMIZE=1 + # OPTIONS_DEBUG -DDEBUGGABLE=1 +) + +vcpkg_install_cmake() + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) + +# Drop a copy of tools +file(COPY ${CURRENT_PACKAGES_DIR}/bin/corrade-rc.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/) +# Tools require dlls +file(GLOB TO_COPY + ${CURRENT_PACKAGES_DIR}/bin/*.dll) +file(COPY ${TO_COPY} DESTINATION ${CURRENT_PACKAGES_DIR}/tools/) + +file(GLOB_RECURSE TO_REMOVE + ${CURRENT_PACKAGES_DIR}/bin/*.exe + ${CURRENT_PACKAGES_DIR}/debug/bin/*.exe) +file(REMOVE ${TO_REMOVE}) + +# Handle copyright +file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/corrade) +file(RENAME ${CURRENT_PACKAGES_DIR}/share/corrade/COPYING ${CURRENT_PACKAGES_DIR}/share/corrade/copyright) + +vcpkg_copy_pdbs() \ No newline at end of file diff --git a/ports/magnum/CONTROL b/ports/magnum/CONTROL new file mode 100644 index 000000000..d07dd3160 --- /dev/null +++ b/ports/magnum/CONTROL @@ -0,0 +1,4 @@ +Source: magnum +Version: jun2017 +Build-Depends: corrade, sdl2 +Description: C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake new file mode 100644 index 000000000..10f9be3c5 --- /dev/null +++ b/ports/magnum/portfile.cmake @@ -0,0 +1,33 @@ +### + +set(MAGNUM_HASH c8416ca4c3e9b68ba62acc9f73de235526cb3d6e) + +include(vcpkg_common_functions) +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/magnum-${MAGNUM_HASH}) +vcpkg_download_distfile(ARCHIVE + URLS "https://github.com/mosra/magnum/archive/${MAGNUM_HASH}.zip" + FILENAME "magnum-${MAGNUM_HASH}.zip" + SHA512 1248efaba22568a753396192624690a478c69946cdbbffe83e34cb85d54ec65756b693e025bf477fc192e6fecce56dc1b68631e1a763986267b83d6530af6ef4 +) +vcpkg_extract_source_archive(${ARCHIVE}) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA # Disable this option if project cannot be built with Ninja + OPTIONS -DWITH_SDL2APPLICATION=ON + # OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2 + # OPTIONS_RELEASE -DOPTIMIZE=1 + # OPTIONS_DEBUG -DDEBUGGABLE=1 +) + +vcpkg_install_cmake() + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) + + +# Handle copyright +file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/magnum) +file(RENAME ${CURRENT_PACKAGES_DIR}/share/magnum/COPYING ${CURRENT_PACKAGES_DIR}/share/magnum/copyright) + +vcpkg_copy_pdbs() \ No newline at end of file From f0605ca60a560ab1358177beec58a53068128753 Mon Sep 17 00:00:00 2001 From: sigman Date: Thu, 8 Jun 2017 02:48:04 +0300 Subject: [PATCH 02/50] [Magnum] Fix static library build Fixes cmake scripts to build a static version of the libraries. --- ports/corrade/portfile.cmake | 12 ++++++++++++ ports/magnum/portfile.cmake | 11 +++++++++++ 2 files changed, 23 insertions(+) diff --git a/ports/corrade/portfile.cmake b/ports/corrade/portfile.cmake index 91251ea6b..2f5578b43 100644 --- a/ports/corrade/portfile.cmake +++ b/ports/corrade/portfile.cmake @@ -13,9 +13,16 @@ vcpkg_download_distfile(ARCHIVE ) vcpkg_extract_source_archive(${ARCHIVE}) +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + set(BUILD_STATIC 1) +else() + set(BUILD_STATIC 0) +endif() + vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} PREFER_NINJA # Disable this option if project cannot be built with Ninja + OPTIONS -DBUILD_STATIC=${BUILD_STATIC} # OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2 # OPTIONS_RELEASE -DOPTIMIZE=1 # OPTIONS_DEBUG -DDEBUGGABLE=1 @@ -38,6 +45,11 @@ file(GLOB_RECURSE TO_REMOVE ${CURRENT_PACKAGES_DIR}/debug/bin/*.exe) file(REMOVE ${TO_REMOVE}) +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/bin) +endif() + # Handle copyright file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/corrade) file(RENAME ${CURRENT_PACKAGES_DIR}/share/corrade/COPYING ${CURRENT_PACKAGES_DIR}/share/corrade/copyright) diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake index 10f9be3c5..71517c15c 100644 --- a/ports/magnum/portfile.cmake +++ b/ports/magnum/portfile.cmake @@ -11,10 +11,17 @@ vcpkg_download_distfile(ARCHIVE ) vcpkg_extract_source_archive(${ARCHIVE}) +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + set(BUILD_STATIC 1) +else() + set(BUILD_STATIC 0) +endif() + vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} PREFER_NINJA # Disable this option if project cannot be built with Ninja OPTIONS -DWITH_SDL2APPLICATION=ON + OPTIONS -DBUILD_STATIC=${BUILD_STATIC} # OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2 # OPTIONS_RELEASE -DOPTIMIZE=1 # OPTIONS_DEBUG -DDEBUGGABLE=1 @@ -25,6 +32,10 @@ vcpkg_install_cmake() file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/bin) +endif() # Handle copyright file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/magnum) From 741caef3fb352f6fbd5d4d59592f0c2629892064 Mon Sep 17 00:00:00 2001 From: sigman Date: Fri, 9 Jun 2017 15:09:05 +0300 Subject: [PATCH 03/50] [Magnum][Corrade] Cleanup and Audio support Enabled audio support in magnum by default via openal-soft dependency. --- ports/corrade/portfile.cmake | 3 --- ports/magnum/CONTROL | 2 +- ports/magnum/portfile.cmake | 5 ++--- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/ports/corrade/portfile.cmake b/ports/corrade/portfile.cmake index 2f5578b43..76979496b 100644 --- a/ports/corrade/portfile.cmake +++ b/ports/corrade/portfile.cmake @@ -23,9 +23,6 @@ vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} PREFER_NINJA # Disable this option if project cannot be built with Ninja OPTIONS -DBUILD_STATIC=${BUILD_STATIC} - # OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2 - # OPTIONS_RELEASE -DOPTIMIZE=1 - # OPTIONS_DEBUG -DDEBUGGABLE=1 ) vcpkg_install_cmake() diff --git a/ports/magnum/CONTROL b/ports/magnum/CONTROL index d07dd3160..f934ba0a6 100644 --- a/ports/magnum/CONTROL +++ b/ports/magnum/CONTROL @@ -1,4 +1,4 @@ Source: magnum Version: jun2017 -Build-Depends: corrade, sdl2 +Build-Depends: corrade, sdl2, openal-soft Description: C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake index 71517c15c..dd934b31d 100644 --- a/ports/magnum/portfile.cmake +++ b/ports/magnum/portfile.cmake @@ -21,10 +21,9 @@ vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} PREFER_NINJA # Disable this option if project cannot be built with Ninja OPTIONS -DWITH_SDL2APPLICATION=ON + OPTIONS -DWITH_AUDIO=ON + OPTIONS -DWITH_WAVAUDIOIMPORTER=ON OPTIONS -DBUILD_STATIC=${BUILD_STATIC} - # OPTIONS -DUSE_THIS_IN_ALL_BUILDS=1 -DUSE_THIS_TOO=2 - # OPTIONS_RELEASE -DOPTIMIZE=1 - # OPTIONS_DEBUG -DDEBUGGABLE=1 ) vcpkg_install_cmake() From 1b761052002a9466704d53ea5b5029df9e89aaa0 Mon Sep 17 00:00:00 2001 From: sigman Date: Fri, 9 Jun 2017 15:17:01 +0300 Subject: [PATCH 04/50] [Magnum-plugins] Import plugins for the magnum opengl library Added magnum-plugins library with the reasonable defaults and minimal dependencies . --- ports/magnum-plugins/CONTROL | 4 +++ ports/magnum-plugins/portfile.cmake | 52 +++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+) create mode 100644 ports/magnum-plugins/CONTROL create mode 100644 ports/magnum-plugins/portfile.cmake diff --git a/ports/magnum-plugins/CONTROL b/ports/magnum-plugins/CONTROL new file mode 100644 index 000000000..0aec0062d --- /dev/null +++ b/ports/magnum-plugins/CONTROL @@ -0,0 +1,4 @@ +Source: magnum-plugins +Version: jun2017 +Build-Depends: stb, magnum +Description: Plugins for C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum-plugins/portfile.cmake b/ports/magnum-plugins/portfile.cmake new file mode 100644 index 000000000..fae2b08e7 --- /dev/null +++ b/ports/magnum-plugins/portfile.cmake @@ -0,0 +1,52 @@ +### + +set(MAGNUM_PLUGINS_HASH 645b50647d5164c5ec8f5bc83ba2578f6cfe7d80) + +include(vcpkg_common_functions) +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/magnum-plugins-${MAGNUM_PLUGINS_HASH}) +vcpkg_download_distfile(ARCHIVE + URLS "https://github.com/mosra/magnum-plugins/archive/${MAGNUM_PLUGINS_HASH}.zip" + FILENAME "magnum-plugins-${MAGNUM_PLUGINS_HASH}.zip" + SHA512 5ab603f50cee325113e3f1ccd67d294d32f7386334136304ad8135ac8ff0218cbd2834197c7db85bb5fd11c69e28d00217fa5d9dbdad71a83e372722a6f8bda0 +) +vcpkg_extract_source_archive(${ARCHIVE}) + +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + set(BUILD_STATIC 1) +else() + set(BUILD_STATIC 0) +endif() + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA # Disable this option if project cannot be built with Ninja + OPTIONS -DWITH_STBIMAGECONVERTER=ON + OPTIONS -DWITH_STBIMAGEIMPORTER=ON + OPTIONS -DWITH_STBTRUETYPEFONT=ON + OPTIONS -DWITH_STBTRUETYPEFONT=ON + OPTIONS -DWITH_MINIEXRIMAGECONVERTER=ON + OPTIONS -DWITH_OPENGEXIMPORTER=ON + OPTIONS -DWITH_OPENGEXIMPORTER=ON + OPTIONS -DWITH_STANFORDIMPORTER=ON + OPTIONS -DWITH_DRWAVAUDIOIMPORTER=ON + OPTIONS -DWITH_ANYAUDIOIMPORTER=ON + OPTIONS -DWITH_ANYIMAGECONVERTER=ON + OPTIONS -DWITH_ANYSCENEIMPORTER=ON + OPTIONS -DBUILD_STATIC=${BUILD_STATIC} +) + +vcpkg_install_cmake() + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) + +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/bin) +endif() + +# Handle copyright +file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/magnum-plugins) +file(RENAME ${CURRENT_PACKAGES_DIR}/share/magnum-plugins/COPYING ${CURRENT_PACKAGES_DIR}/share/magnum-plugins/copyright) + +vcpkg_copy_pdbs() \ No newline at end of file From 8cbadbffdcf0f1f4d5acd16012ecbb47532bdac9 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Fri, 9 Jun 2017 20:38:25 -0700 Subject: [PATCH 05/50] [corrade][magnum-plugins][magnum] Use vcpkg_from_github() --- ports/corrade/CONTROL | 2 +- ports/corrade/portfile.cmake | 25 ++++++----------- ports/magnum-plugins/CONTROL | 2 +- ports/magnum-plugins/portfile.cmake | 43 ++++++++++++++--------------- ports/magnum/CONTROL | 2 +- ports/magnum/portfile.cmake | 25 ++++++++--------- 6 files changed, 43 insertions(+), 56 deletions(-) diff --git a/ports/corrade/CONTROL b/ports/corrade/CONTROL index 487766e89..748d0c61a 100644 --- a/ports/corrade/CONTROL +++ b/ports/corrade/CONTROL @@ -1,3 +1,3 @@ Source: corrade -Version: jun2017 +Version: jun2017-1 Description: C++11/C++14 multiplatform utility library http://mosra.cz/blog/corrade.php diff --git a/ports/corrade/portfile.cmake b/ports/corrade/portfile.cmake index 76979496b..113d24dc7 100644 --- a/ports/corrade/portfile.cmake +++ b/ports/corrade/portfile.cmake @@ -1,17 +1,11 @@ -# - -set(CORRADE_HASH b87c50db3543367b6eb20dc72246c6687449b029) - include(vcpkg_common_functions) - - -set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/corrade-${CORRADE_HASH}) -vcpkg_download_distfile(ARCHIVE - URLS "https://github.com/mosra/corrade/archive/${CORRADE_HASH}.zip" - FILENAME "corrade-${CORRADE_HASH}.zip" - SHA512 b15b544f996b8c95fbdf73ff9b76deea465fdcf06f431b09f4bbb9a786f4e864fdb4f8c5a2977cb366ee2398c54eac4c469da29c2ab7c67d3b8f7cbf7d2120dc +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO mosra/corrade + REF b87c50db3543367b6eb20dc72246c6687449b029 + SHA512 882ccba210c6db7dc8a70e425e1cc119dd1c1a880b8b7d36b2c9478a2105294294680495e7bafb8c0bc7f667bd247dbd008e8ff133a8ea26b13df781a8896297 + HEAD_REF master ) -vcpkg_extract_source_archive(${ARCHIVE}) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(BUILD_STATIC 1) @@ -31,11 +25,10 @@ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) # Drop a copy of tools -file(COPY ${CURRENT_PACKAGES_DIR}/bin/corrade-rc.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/) +file(COPY ${CURRENT_PACKAGES_DIR}/bin/corrade-rc.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/corrade) + # Tools require dlls -file(GLOB TO_COPY - ${CURRENT_PACKAGES_DIR}/bin/*.dll) -file(COPY ${TO_COPY} DESTINATION ${CURRENT_PACKAGES_DIR}/tools/) +vcpkg_copy_tool_dependencies(${CURRENT_PACKAGES_DIR}/tools/corrade) file(GLOB_RECURSE TO_REMOVE ${CURRENT_PACKAGES_DIR}/bin/*.exe diff --git a/ports/magnum-plugins/CONTROL b/ports/magnum-plugins/CONTROL index 0aec0062d..1bf1111c4 100644 --- a/ports/magnum-plugins/CONTROL +++ b/ports/magnum-plugins/CONTROL @@ -1,4 +1,4 @@ Source: magnum-plugins -Version: jun2017 +Version: jun2017-1 Build-Depends: stb, magnum Description: Plugins for C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum-plugins/portfile.cmake b/ports/magnum-plugins/portfile.cmake index fae2b08e7..199789c99 100644 --- a/ports/magnum-plugins/portfile.cmake +++ b/ports/magnum-plugins/portfile.cmake @@ -1,15 +1,11 @@ -### - -set(MAGNUM_PLUGINS_HASH 645b50647d5164c5ec8f5bc83ba2578f6cfe7d80) - include(vcpkg_common_functions) -set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/magnum-plugins-${MAGNUM_PLUGINS_HASH}) -vcpkg_download_distfile(ARCHIVE - URLS "https://github.com/mosra/magnum-plugins/archive/${MAGNUM_PLUGINS_HASH}.zip" - FILENAME "magnum-plugins-${MAGNUM_PLUGINS_HASH}.zip" - SHA512 5ab603f50cee325113e3f1ccd67d294d32f7386334136304ad8135ac8ff0218cbd2834197c7db85bb5fd11c69e28d00217fa5d9dbdad71a83e372722a6f8bda0 +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO mosra/magnum-plugins + REF 645b50647d5164c5ec8f5bc83ba2578f6cfe7d80 + SHA512 73c7fb7e9a5a9e2a4ee7314b5d41d98ada9cf1a50c1cd833c2ae19c5bdab66862f3696f142e987f9d2b551142e94f96a2d8ccad37625682c8391400091dcf879 + HEAD_REF master ) -vcpkg_extract_source_archive(${ARCHIVE}) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(BUILD_STATIC 1) @@ -20,19 +16,20 @@ endif() vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} PREFER_NINJA # Disable this option if project cannot be built with Ninja - OPTIONS -DWITH_STBIMAGECONVERTER=ON - OPTIONS -DWITH_STBIMAGEIMPORTER=ON - OPTIONS -DWITH_STBTRUETYPEFONT=ON - OPTIONS -DWITH_STBTRUETYPEFONT=ON - OPTIONS -DWITH_MINIEXRIMAGECONVERTER=ON - OPTIONS -DWITH_OPENGEXIMPORTER=ON - OPTIONS -DWITH_OPENGEXIMPORTER=ON - OPTIONS -DWITH_STANFORDIMPORTER=ON - OPTIONS -DWITH_DRWAVAUDIOIMPORTER=ON - OPTIONS -DWITH_ANYAUDIOIMPORTER=ON - OPTIONS -DWITH_ANYIMAGECONVERTER=ON - OPTIONS -DWITH_ANYSCENEIMPORTER=ON - OPTIONS -DBUILD_STATIC=${BUILD_STATIC} + OPTIONS + -DWITH_STBIMAGECONVERTER=ON + -DWITH_STBIMAGEIMPORTER=ON + -DWITH_STBTRUETYPEFONT=ON + -DWITH_STBTRUETYPEFONT=ON + -DWITH_MINIEXRIMAGECONVERTER=ON + -DWITH_OPENGEXIMPORTER=ON + -DWITH_OPENGEXIMPORTER=ON + -DWITH_STANFORDIMPORTER=ON + -DWITH_DRWAVAUDIOIMPORTER=ON + -DWITH_ANYAUDIOIMPORTER=ON + -DWITH_ANYIMAGECONVERTER=ON + -DWITH_ANYSCENEIMPORTER=ON + -DBUILD_STATIC=${BUILD_STATIC} ) vcpkg_install_cmake() diff --git a/ports/magnum/CONTROL b/ports/magnum/CONTROL index f934ba0a6..a110136f2 100644 --- a/ports/magnum/CONTROL +++ b/ports/magnum/CONTROL @@ -1,4 +1,4 @@ Source: magnum -Version: jun2017 +Version: jun2017-1 Build-Depends: corrade, sdl2, openal-soft Description: C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake index dd934b31d..67d1f825a 100644 --- a/ports/magnum/portfile.cmake +++ b/ports/magnum/portfile.cmake @@ -1,15 +1,11 @@ -### - -set(MAGNUM_HASH c8416ca4c3e9b68ba62acc9f73de235526cb3d6e) - include(vcpkg_common_functions) -set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/magnum-${MAGNUM_HASH}) -vcpkg_download_distfile(ARCHIVE - URLS "https://github.com/mosra/magnum/archive/${MAGNUM_HASH}.zip" - FILENAME "magnum-${MAGNUM_HASH}.zip" - SHA512 1248efaba22568a753396192624690a478c69946cdbbffe83e34cb85d54ec65756b693e025bf477fc192e6fecce56dc1b68631e1a763986267b83d6530af6ef4 +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO mosra/magnum + REF c8416ca4c3e9b68ba62acc9f73de235526cb3d6e + SHA512 d595be48ae44d944d5747880e0108bdc445b92fcc306f0169699e2b80500919647063ac88ef67491b2d8e92ae1f0612cd8768fc63d8cc4ffe4c625988b63504d + HEAD_REF master ) -vcpkg_extract_source_archive(${ARCHIVE}) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(BUILD_STATIC 1) @@ -20,10 +16,11 @@ endif() vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} PREFER_NINJA # Disable this option if project cannot be built with Ninja - OPTIONS -DWITH_SDL2APPLICATION=ON - OPTIONS -DWITH_AUDIO=ON - OPTIONS -DWITH_WAVAUDIOIMPORTER=ON - OPTIONS -DBUILD_STATIC=${BUILD_STATIC} + OPTIONS + -DWITH_SDL2APPLICATION=ON + -DWITH_AUDIO=ON + -DWITH_WAVAUDIOIMPORTER=ON + -DBUILD_STATIC=${BUILD_STATIC} ) vcpkg_install_cmake() From 27db5c14bbe9025dd5953b6cd4accb51e4be0501 Mon Sep 17 00:00:00 2001 From: sigman Date: Sat, 10 Jun 2017 17:48:40 +0300 Subject: [PATCH 06/50] [magnum-plugins] Patch for missing include vs2017 regression --- ports/magnum-plugins/001-fix-include.patch | 12 ++++++++++++ ports/magnum-plugins/CONTROL | 2 +- ports/magnum-plugins/portfile.cmake | 5 +++++ 3 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 ports/magnum-plugins/001-fix-include.patch diff --git a/ports/magnum-plugins/001-fix-include.patch b/ports/magnum-plugins/001-fix-include.patch new file mode 100644 index 000000000..c6aa9c755 --- /dev/null +++ b/ports/magnum-plugins/001-fix-include.patch @@ -0,0 +1,12 @@ +diff --git a/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp b/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp +index c94ee98..843d1ec 100644 +--- a/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp ++++ b/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp +@@ -25,6 +25,7 @@ + + #include + #include ++#include + #include + + #include "MagnumPlugins/OpenGexImporter/OpenDdl/Document.h" diff --git a/ports/magnum-plugins/CONTROL b/ports/magnum-plugins/CONTROL index 1bf1111c4..087383c4a 100644 --- a/ports/magnum-plugins/CONTROL +++ b/ports/magnum-plugins/CONTROL @@ -1,4 +1,4 @@ Source: magnum-plugins -Version: jun2017-1 +Version: jun2017-2 Build-Depends: stb, magnum Description: Plugins for C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum-plugins/portfile.cmake b/ports/magnum-plugins/portfile.cmake index 199789c99..dde435ee4 100644 --- a/ports/magnum-plugins/portfile.cmake +++ b/ports/magnum-plugins/portfile.cmake @@ -7,6 +7,11 @@ vcpkg_from_github( HEAD_REF master ) +vcpkg_apply_patches( + SOURCE_PATH ${SOURCE_PATH} + PATCHES ${CMAKE_CURRENT_LIST_DIR}/001-fix-include.patch +) + if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(BUILD_STATIC 1) else() From 61dbead6fc9dc3b27515db9fbc4d48e772f298bd Mon Sep 17 00:00:00 2001 From: sigman78 Date: Tue, 13 Jun 2017 12:35:54 +0300 Subject: [PATCH 07/50] [magnum] Patch SDL2 includes, msbuild compatibility Concerning SDL2 includes and how do they work. It is seems what the common practice is to append 'SDL2' include path to the compiler options and then do plain #include "SDL.h". While it works in cmake based projects it won't pass in msbuild ones. This patch changes #include to 'global' style and solves the problem. --- ports/magnum/001-sdl-includes.patch | 20 ++++++++++++++++++++ ports/magnum/CONTROL | 2 +- ports/magnum/portfile.cmake | 5 +++++ 3 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 ports/magnum/001-sdl-includes.patch diff --git a/ports/magnum/001-sdl-includes.patch b/ports/magnum/001-sdl-includes.patch new file mode 100644 index 000000000..afa1301d9 --- /dev/null +++ b/ports/magnum/001-sdl-includes.patch @@ -0,0 +1,20 @@ +diff --git a/src/Magnum/Platform/Sdl2Application.h b/src/Magnum/Platform/Sdl2Application.h +index 99c3174..311b2c1 100644 +--- a/src/Magnum/Platform/Sdl2Application.h ++++ b/src/Magnum/Platform/Sdl2Application.h +@@ -42,11 +42,11 @@ + #ifdef CORRADE_TARGET_WINDOWS /* Windows version of SDL2 redefines main(), we don't want that */ + #define SDL_MAIN_HANDLED + #endif +-#include +-#include ++#include ++#include + + #ifdef CORRADE_TARGET_WINDOWS_RT +-#include /* For SDL_WinRTRunApp */ ++#include /* For SDL_WinRTRunApp */ + #include /* For the WinMain entrypoint */ + #endif + + diff --git a/ports/magnum/CONTROL b/ports/magnum/CONTROL index a110136f2..c4530c254 100644 --- a/ports/magnum/CONTROL +++ b/ports/magnum/CONTROL @@ -1,4 +1,4 @@ Source: magnum -Version: jun2017-1 +Version: jun2017-2 Build-Depends: corrade, sdl2, openal-soft Description: C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake index 67d1f825a..81e2123b6 100644 --- a/ports/magnum/portfile.cmake +++ b/ports/magnum/portfile.cmake @@ -7,6 +7,11 @@ vcpkg_from_github( HEAD_REF master ) +vcpkg_apply_patches( + SOURCE_PATH ${SOURCE_PATH} + PATCHES ${CMAKE_CURRENT_LIST_DIR}/001-sdl-includes.patch +) + if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(BUILD_STATIC 1) else() From 4167807f09e3f772a87d0f1f0ae5f51f9cdc5610 Mon Sep 17 00:00:00 2001 From: sigman78 Date: Tue, 13 Jun 2017 15:20:29 +0300 Subject: [PATCH 08/50] [magnum] Emit plugin binary path to the header Drop-in solution for the msbuild users. --- ports/magnum/002-magnum-defs.patch | 26 ++++++++++++++++++++++++++ ports/magnum/CONTROL | 2 +- ports/magnum/portfile.cmake | 6 +++++- 3 files changed, 32 insertions(+), 2 deletions(-) create mode 100644 ports/magnum/002-magnum-defs.patch diff --git a/ports/magnum/002-magnum-defs.patch b/ports/magnum/002-magnum-defs.patch new file mode 100644 index 000000000..de7d1cb10 --- /dev/null +++ b/ports/magnum/002-magnum-defs.patch @@ -0,0 +1,26 @@ +diff --git a/src/Magnum/configure.h.cmake b/src/Magnum/configure.h.cmake +index 6a752d4..cd1277b 100644 +--- a/src/Magnum/configure.h.cmake ++++ b/src/Magnum/configure.h.cmake +@@ -35,4 +35,23 @@ + #cmakedefine MAGNUM_TARGET_WEBGL + #cmakedefine MAGNUM_TARGET_HEADLESS + ++// Plugin directories ++#ifdef _DEBUG ++#define MAGNUM_PLUGINS_DIR "${MAGNUM_PLUGINS_DEBUG_DIR}" ++#define MAGNUM_PLUGINS_FONT_DIR "${MAGNUM_PLUGINS_FONT_DEBUG_DIR}" ++#define MAGNUM_PLUGINS_FONTCONVERTER_DIR "${MAGNUM_PLUGINS_FONTCONVERTER_DEBUG_DIR}" ++#define MAGNUM_PLUGINS_IMAGECONVERTER_DIR "${MAGNUM_PLUGINS_IMAGECONVERTER_DEBUG_DIR}" ++#define MAGNUM_PLUGINS_IMPORTER_DIR "${MAGNUM_PLUGINS_IMPORTER_DEBUG_DIR}" ++#define MAGNUM_PLUGINS_AUDIOIMPORTER_DIR "${MAGNUM_PLUGINS_AUDIOIMPORTER_DEBUG_DIR}" ++#else ++#define MAGNUM_PLUGINS_DIR "${MAGNUM_PLUGINS_RELEASE_DIR}" ++#define MAGNUM_PLUGINS_FONT_DIR "${MAGNUM_PLUGINS_FONT_RELEASE_DIR}" ++#define MAGNUM_PLUGINS_FONTCONVERTER_DIR "${MAGNUM_PLUGINS_FONTCONVERTER_RELEASE_DIR}" ++#define MAGNUM_PLUGINS_IMAGECONVERTER_DIR "${MAGNUM_PLUGINS_IMAGECONVERTER_RELEASE_DIR}" ++#define MAGNUM_PLUGINS_IMPORTER_DIR "${MAGNUM_PLUGINS_IMPORTER_RELEASE_DIR}" ++#define MAGNUM_PLUGINS_AUDIOIMPORTER_DIR "${MAGNUM_PLUGINS_AUDIOIMPORTER_RELEASE_DIR}" ++#endif ++ + #endif diff --git a/ports/magnum/CONTROL b/ports/magnum/CONTROL index c4530c254..9160e2287 100644 --- a/ports/magnum/CONTROL +++ b/ports/magnum/CONTROL @@ -1,4 +1,4 @@ Source: magnum -Version: jun2017-2 +Version: jun2017-3 Build-Depends: corrade, sdl2, openal-soft Description: C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake index 81e2123b6..3aed5a737 100644 --- a/ports/magnum/portfile.cmake +++ b/ports/magnum/portfile.cmake @@ -9,7 +9,9 @@ vcpkg_from_github( vcpkg_apply_patches( SOURCE_PATH ${SOURCE_PATH} - PATCHES ${CMAKE_CURRENT_LIST_DIR}/001-sdl-includes.patch + PATCHES + ${CMAKE_CURRENT_LIST_DIR}/001-sdl-includes.patch + ${CMAKE_CURRENT_LIST_DIR}/002-magnum-defs.patch ) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) @@ -26,6 +28,8 @@ vcpkg_configure_cmake( -DWITH_AUDIO=ON -DWITH_WAVAUDIOIMPORTER=ON -DBUILD_STATIC=${BUILD_STATIC} + -DMAGNUM_PLUGINS_DEBUG_DIR=${CURRENT_INSTALLED_DIR}/debug/bin/magnum-d + -DMAGNUM_PLUGINS_RELEASE_DIR=${CURRENT_INSTALLED_DIR}/bin/magnum ) vcpkg_install_cmake() From 7b9275f1b35e6533dc63d1f1dd7b61066216e3f1 Mon Sep 17 00:00:00 2001 From: sigman Date: Thu, 15 Jun 2017 17:49:43 +0300 Subject: [PATCH 09/50] [corrade][magnum][magnum-plugins] Updated to upstream, enabled more features in [magnum] Removed plugin location defines. Fixed tools search path in FindCorrade, FindMagnum cmake modules. --- ports/corrade/CONTROL | 2 +- ports/corrade/portfile.cmake | 4 +-- ports/magnum-plugins/001-fix-include.patch | 12 --------- ports/magnum-plugins/001-tools-path.patch | 26 +++++++++++++++++++ ports/magnum-plugins/CONTROL | 2 +- ports/magnum-plugins/portfile.cmake | 7 ++--- ports/magnum/002-magnum-defs.patch | 26 ------------------- ports/magnum/002-tools-path.patch | 26 +++++++++++++++++++ ports/magnum/CONTROL | 2 +- ports/magnum/portfile.cmake | 30 +++++++++++++++++++--- 10 files changed, 88 insertions(+), 49 deletions(-) delete mode 100644 ports/magnum-plugins/001-fix-include.patch create mode 100644 ports/magnum-plugins/001-tools-path.patch delete mode 100644 ports/magnum/002-magnum-defs.patch create mode 100644 ports/magnum/002-tools-path.patch diff --git a/ports/corrade/CONTROL b/ports/corrade/CONTROL index 748d0c61a..d8fb3681a 100644 --- a/ports/corrade/CONTROL +++ b/ports/corrade/CONTROL @@ -1,3 +1,3 @@ Source: corrade -Version: jun2017-1 +Version: jun2017-2 Description: C++11/C++14 multiplatform utility library http://mosra.cz/blog/corrade.php diff --git a/ports/corrade/portfile.cmake b/ports/corrade/portfile.cmake index 113d24dc7..3ae3710f6 100644 --- a/ports/corrade/portfile.cmake +++ b/ports/corrade/portfile.cmake @@ -2,8 +2,8 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO mosra/corrade - REF b87c50db3543367b6eb20dc72246c6687449b029 - SHA512 882ccba210c6db7dc8a70e425e1cc119dd1c1a880b8b7d36b2c9478a2105294294680495e7bafb8c0bc7f667bd247dbd008e8ff133a8ea26b13df781a8896297 + REF c182fe636894a998f241212d0205d0c126b7926f + SHA512 e62486368eab9c5f90ef9f4af91500f465d9e3baa6e5f6e9f2a49844d09676faefcb965a9d5b27a54eda19436af6b23dcda19504be6cd0dcd52dfad2ad4bfa21 HEAD_REF master ) diff --git a/ports/magnum-plugins/001-fix-include.patch b/ports/magnum-plugins/001-fix-include.patch deleted file mode 100644 index c6aa9c755..000000000 --- a/ports/magnum-plugins/001-fix-include.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp b/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp -index c94ee98..843d1ec 100644 ---- a/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp -+++ b/src/MagnumPlugins/OpenGexImporter/OpenDdl/OpenDdl.cpp -@@ -25,6 +25,7 @@ - - #include - #include -+#include - #include - - #include "MagnumPlugins/OpenGexImporter/OpenDdl/Document.h" diff --git a/ports/magnum-plugins/001-tools-path.patch b/ports/magnum-plugins/001-tools-path.patch new file mode 100644 index 000000000..18a351c2e --- /dev/null +++ b/ports/magnum-plugins/001-tools-path.patch @@ -0,0 +1,26 @@ +diff --git a/modules/FindCorrade.cmake b/modules/FindCorrade.cmake +index e63bc03..052006f 100644 +--- a/modules/FindCorrade.cmake ++++ b/modules/FindCorrade.cmake +@@ -397,7 +397,7 @@ foreach(_component ${Corrade_FIND_COMPONENTS}) + if(_component MATCHES ${_CORRADE_EXECUTABLE_COMPONENTS}) + add_executable(Corrade::${_component} IMPORTED) + +- find_program(CORRADE_${_COMPONENT}_EXECUTABLE corrade-${_component}) ++ find_program(CORRADE_${_COMPONENT}_EXECUTABLE corrade-${_component} PATH_SUFFIXES corrade) + mark_as_advanced(CORRADE_${_COMPONENT}_EXECUTABLE) + + if(CORRADE_${_COMPONENT}_EXECUTABLE) +diff --git a/modules/FindMagnum.cmake b/modules/FindMagnum.cmake +index 8df555d..12f7aa4 100644 +--- a/modules/FindMagnum.cmake ++++ b/modules/FindMagnum.cmake +@@ -493,7 +493,7 @@ foreach(_component ${Magnum_FIND_COMPONENTS}) + if(_component MATCHES ${_MAGNUM_EXECUTABLE_COMPONENTS}) + add_executable(Magnum::${_component} IMPORTED) + +- find_program(MAGNUM_${_COMPONENT}_EXECUTABLE magnum-${_component}) ++ find_program(MAGNUM_${_COMPONENT}_EXECUTABLE magnum-${_component} PATH_SUFFIXES magnum) + mark_as_advanced(MAGNUM_${_COMPONENT}_EXECUTABLE) + + if(MAGNUM_${_COMPONENT}_EXECUTABLE) diff --git a/ports/magnum-plugins/CONTROL b/ports/magnum-plugins/CONTROL index 087383c4a..9d684689a 100644 --- a/ports/magnum-plugins/CONTROL +++ b/ports/magnum-plugins/CONTROL @@ -1,4 +1,4 @@ Source: magnum-plugins -Version: jun2017-2 +Version: jun2017-3 Build-Depends: stb, magnum Description: Plugins for C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum-plugins/portfile.cmake b/ports/magnum-plugins/portfile.cmake index dde435ee4..0fe8f83a1 100644 --- a/ports/magnum-plugins/portfile.cmake +++ b/ports/magnum-plugins/portfile.cmake @@ -2,14 +2,15 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO mosra/magnum-plugins - REF 645b50647d5164c5ec8f5bc83ba2578f6cfe7d80 - SHA512 73c7fb7e9a5a9e2a4ee7314b5d41d98ada9cf1a50c1cd833c2ae19c5bdab66862f3696f142e987f9d2b551142e94f96a2d8ccad37625682c8391400091dcf879 + REF 34a3bc34335ca05097e735db19fe1fae81dbfbb5 + SHA512 918c3eeae246d1ac67e3595c50ff599872a0c1498e9a8a0386ad656f3d9d2209b048b53c25f198660e15201147795578c5c931b00116da46fd77d8e91c0826cb HEAD_REF master ) vcpkg_apply_patches( SOURCE_PATH ${SOURCE_PATH} - PATCHES ${CMAKE_CURRENT_LIST_DIR}/001-fix-include.patch + PATCHES + ${CMAKE_CURRENT_LIST_DIR}/001-tools-path.patch ) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) diff --git a/ports/magnum/002-magnum-defs.patch b/ports/magnum/002-magnum-defs.patch deleted file mode 100644 index de7d1cb10..000000000 --- a/ports/magnum/002-magnum-defs.patch +++ /dev/null @@ -1,26 +0,0 @@ -diff --git a/src/Magnum/configure.h.cmake b/src/Magnum/configure.h.cmake -index 6a752d4..cd1277b 100644 ---- a/src/Magnum/configure.h.cmake -+++ b/src/Magnum/configure.h.cmake -@@ -35,4 +35,23 @@ - #cmakedefine MAGNUM_TARGET_WEBGL - #cmakedefine MAGNUM_TARGET_HEADLESS - -+// Plugin directories -+#ifdef _DEBUG -+#define MAGNUM_PLUGINS_DIR "${MAGNUM_PLUGINS_DEBUG_DIR}" -+#define MAGNUM_PLUGINS_FONT_DIR "${MAGNUM_PLUGINS_FONT_DEBUG_DIR}" -+#define MAGNUM_PLUGINS_FONTCONVERTER_DIR "${MAGNUM_PLUGINS_FONTCONVERTER_DEBUG_DIR}" -+#define MAGNUM_PLUGINS_IMAGECONVERTER_DIR "${MAGNUM_PLUGINS_IMAGECONVERTER_DEBUG_DIR}" -+#define MAGNUM_PLUGINS_IMPORTER_DIR "${MAGNUM_PLUGINS_IMPORTER_DEBUG_DIR}" -+#define MAGNUM_PLUGINS_AUDIOIMPORTER_DIR "${MAGNUM_PLUGINS_AUDIOIMPORTER_DEBUG_DIR}" -+#else -+#define MAGNUM_PLUGINS_DIR "${MAGNUM_PLUGINS_RELEASE_DIR}" -+#define MAGNUM_PLUGINS_FONT_DIR "${MAGNUM_PLUGINS_FONT_RELEASE_DIR}" -+#define MAGNUM_PLUGINS_FONTCONVERTER_DIR "${MAGNUM_PLUGINS_FONTCONVERTER_RELEASE_DIR}" -+#define MAGNUM_PLUGINS_IMAGECONVERTER_DIR "${MAGNUM_PLUGINS_IMAGECONVERTER_RELEASE_DIR}" -+#define MAGNUM_PLUGINS_IMPORTER_DIR "${MAGNUM_PLUGINS_IMPORTER_RELEASE_DIR}" -+#define MAGNUM_PLUGINS_AUDIOIMPORTER_DIR "${MAGNUM_PLUGINS_AUDIOIMPORTER_RELEASE_DIR}" -+#endif -+ - #endif diff --git a/ports/magnum/002-tools-path.patch b/ports/magnum/002-tools-path.patch new file mode 100644 index 000000000..18a351c2e --- /dev/null +++ b/ports/magnum/002-tools-path.patch @@ -0,0 +1,26 @@ +diff --git a/modules/FindCorrade.cmake b/modules/FindCorrade.cmake +index e63bc03..052006f 100644 +--- a/modules/FindCorrade.cmake ++++ b/modules/FindCorrade.cmake +@@ -397,7 +397,7 @@ foreach(_component ${Corrade_FIND_COMPONENTS}) + if(_component MATCHES ${_CORRADE_EXECUTABLE_COMPONENTS}) + add_executable(Corrade::${_component} IMPORTED) + +- find_program(CORRADE_${_COMPONENT}_EXECUTABLE corrade-${_component}) ++ find_program(CORRADE_${_COMPONENT}_EXECUTABLE corrade-${_component} PATH_SUFFIXES corrade) + mark_as_advanced(CORRADE_${_COMPONENT}_EXECUTABLE) + + if(CORRADE_${_COMPONENT}_EXECUTABLE) +diff --git a/modules/FindMagnum.cmake b/modules/FindMagnum.cmake +index 8df555d..12f7aa4 100644 +--- a/modules/FindMagnum.cmake ++++ b/modules/FindMagnum.cmake +@@ -493,7 +493,7 @@ foreach(_component ${Magnum_FIND_COMPONENTS}) + if(_component MATCHES ${_MAGNUM_EXECUTABLE_COMPONENTS}) + add_executable(Magnum::${_component} IMPORTED) + +- find_program(MAGNUM_${_COMPONENT}_EXECUTABLE magnum-${_component}) ++ find_program(MAGNUM_${_COMPONENT}_EXECUTABLE magnum-${_component} PATH_SUFFIXES magnum) + mark_as_advanced(MAGNUM_${_COMPONENT}_EXECUTABLE) + + if(MAGNUM_${_COMPONENT}_EXECUTABLE) diff --git a/ports/magnum/CONTROL b/ports/magnum/CONTROL index 9160e2287..9245e4380 100644 --- a/ports/magnum/CONTROL +++ b/ports/magnum/CONTROL @@ -1,4 +1,4 @@ Source: magnum -Version: jun2017-3 +Version: jun2017-4 Build-Depends: corrade, sdl2, openal-soft Description: C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake index 3aed5a737..14d5e0846 100644 --- a/ports/magnum/portfile.cmake +++ b/ports/magnum/portfile.cmake @@ -2,8 +2,8 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO mosra/magnum - REF c8416ca4c3e9b68ba62acc9f73de235526cb3d6e - SHA512 d595be48ae44d944d5747880e0108bdc445b92fcc306f0169699e2b80500919647063ac88ef67491b2d8e92ae1f0612cd8768fc63d8cc4ffe4c625988b63504d + REF ed7eac0b42a598dff8984830e7f943dd6af07deb + SHA512 843e209b82b4f6f7c3f9612aec2641a28cb09361eefefe435bb7d2c06d0e4df65b6b9adf5893222cf31ddc3ccec967eb343da1da6180e9fbfef1b26234e145d5 HEAD_REF master ) @@ -11,7 +11,7 @@ vcpkg_apply_patches( SOURCE_PATH ${SOURCE_PATH} PATCHES ${CMAKE_CURRENT_LIST_DIR}/001-sdl-includes.patch - ${CMAKE_CURRENT_LIST_DIR}/002-magnum-defs.patch + ${CMAKE_CURRENT_LIST_DIR}/002-tools-path.patch ) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) @@ -25,15 +25,39 @@ vcpkg_configure_cmake( PREFER_NINJA # Disable this option if project cannot be built with Ninja OPTIONS -DWITH_SDL2APPLICATION=ON + -DWITH_WINDOWLESSWGLAPPLICATION=ON + -DWITH_WGLCONTEXT=ON + -DWITH_OPENGLTESTER=ON -DWITH_AUDIO=ON -DWITH_WAVAUDIOIMPORTER=ON + -DWITH_MAGNUMFONT=ON + -DWITH_MAGNUMFONTCONVERTER=ON + -DWITH_OBJIMPORTER=ON + -DWITH_TGAIMPORTER=ON + -DWITH_DISTANCEFIELDCONVERTER=ON + -DWITH_FONTCONVERTER=ON + -DWITH_TGAIMAGECONVERTER=ON -DBUILD_STATIC=${BUILD_STATIC} -DMAGNUM_PLUGINS_DEBUG_DIR=${CURRENT_INSTALLED_DIR}/debug/bin/magnum-d -DMAGNUM_PLUGINS_RELEASE_DIR=${CURRENT_INSTALLED_DIR}/bin/magnum + --trace ) vcpkg_install_cmake() +# Drop a copy of tools +file(COPY ${CURRENT_PACKAGES_DIR}/bin/magnum-distancefieldconverter.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/magnum) +file(COPY ${CURRENT_PACKAGES_DIR}/bin/magnum-fontconverter.exe DESTINATION ${CURRENT_PACKAGES_DIR}/tools/magnum) + +# Tools require dlls +vcpkg_copy_tool_dependencies(${CURRENT_PACKAGES_DIR}/tools/magnum) + +file(GLOB_RECURSE TO_REMOVE + ${CURRENT_PACKAGES_DIR}/bin/*.exe + ${CURRENT_PACKAGES_DIR}/debug/bin/*.exe) +file(REMOVE ${TO_REMOVE}) + + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) From 79d4a2e297a0cc481ecfd8a100b2e1a78b40d0a4 Mon Sep 17 00:00:00 2001 From: codicodi Date: Tue, 20 Jun 2017 23:35:49 +0200 Subject: [PATCH 10/50] [opus] update to 1.2 --- ports/opus/CONTROL | 2 +- ports/opus/portfile.cmake | 71 +++++++++++++++++++-------------------- 2 files changed, 36 insertions(+), 37 deletions(-) diff --git a/ports/opus/CONTROL b/ports/opus/CONTROL index 7177b2199..dbff6715a 100644 --- a/ports/opus/CONTROL +++ b/ports/opus/CONTROL @@ -1,3 +1,3 @@ Source: opus -Version: 1.1.4 +Version: 1.2 Description: Totally open, royalty-free, highly versatile audio codec diff --git a/ports/opus/portfile.cmake b/ports/opus/portfile.cmake index a004f09dd..f2a6dc018 100644 --- a/ports/opus/portfile.cmake +++ b/ports/opus/portfile.cmake @@ -1,11 +1,26 @@ +if(VCPKG_CMAKE_SYSTEM_NAME STREQUAL WindowsStore) + message(FATAL_ERROR "UWP builds not supported") +endif() + include(vcpkg_common_functions) -set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/opus-1.1.4) -vcpkg_download_distfile(ARCHIVE - URLS "http://downloads.xiph.org/releases/opus/opus-1.1.4.tar.gz" - FILENAME "opus-1.1.4.tar.gz" - SHA512 57f14b9e8037eaa02a4d86535d3bbcceca249310fbc9ef1a452cc19dd442d4cf338d5db241d20605c236e22549df2c8266b7486c5f1666b80c532afd52cb3585 +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO xiph/opus + REF v1.2 + SHA512 4fef70e3b439613f85ede30cc401b84c77f1828f56908d04cb76061b8116c083cc035b50eaec4205110481e9d8b794b9c05f6778d8428cc68f6d57bd3db721ca + HEAD_REF master ) -vcpkg_extract_source_archive(${ARCHIVE}) + +# Ensure proper crt linkage +file(READ ${SOURCE_PATH}/win32/VS2015/common.props OPUS_PROPS) +if(VCPKG_CRT_LINKAGE STREQUAL dynamic) + string(REPLACE ">MultiThreaded<" ">MultiThreadedDLL<" OPUS_PROPS "${OPUS_PROPS}") + string(REPLACE ">MultiThreadedDebug<" ">MultiThreadedDebugDLL<" OPUS_PROPS "${OPUS_PROPS}") +else() + string(REPLACE ">MultiThreadedDLL<" ">MultiThreaded<" OPUS_PROPS "${OPUS_PROPS}") + string(REPLACE ">MultiThreadedDebugDLL<" ">MultiThreadedDebug<" OPUS_PROPS "${OPUS_PROPS}") +endif() +file(WRITE ${SOURCE_PATH}/win32/VS2015/common.props "${OPUS_PROPS}") if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(RELEASE_CONFIGURATION "Release") @@ -20,44 +35,21 @@ if(TARGET_TRIPLET MATCHES "x86") elseif(TARGET_TRIPLET MATCHES "x64") set(ARCH_DIR "x64") else() - message("Architecture not supported") + message(FATAL_ERROR "Architecture not supported") endif() -function(build_project PROJECT_PATH) - vcpkg_build_msbuild( - PROJECT_PATH ${PROJECT_PATH} - RELEASE_CONFIGURATION ${RELEASE_CONFIGURATION} - DEBUG_CONFIGURATION ${DEBUG_CONFIGURATION} - ) -endfunction(build_project) - - -build_project(${SOURCE_PATH}/win32/VS2015/celt.vcxproj) -build_project(${SOURCE_PATH}/win32/VS2015/silk_common.vcxproj) -build_project(${SOURCE_PATH}/win32/VS2015/silk_float.vcxproj) -build_project(${SOURCE_PATH}/win32/VS2015/silk_fixed.vcxproj) -build_project(${SOURCE_PATH}/win32/VS2015/opus.vcxproj) - +vcpkg_build_msbuild( + PROJECT_PATH ${SOURCE_PATH}/win32/VS2015/opus.vcxproj + RELEASE_CONFIGURATION ${RELEASE_CONFIGURATION} + DEBUG_CONFIGURATION ${DEBUG_CONFIGURATION} +) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) # Install release build file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${RELEASE_CONFIGURATION}/opus.lib DESTINATION ${CURRENT_PACKAGES_DIR}/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${RELEASE_CONFIGURATION}/celt.lib DESTINATION ${CURRENT_PACKAGES_DIR}/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${RELEASE_CONFIGURATION}/silk_common.lib DESTINATION ${CURRENT_PACKAGES_DIR}/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${RELEASE_CONFIGURATION}/silk_fixed.lib DESTINATION ${CURRENT_PACKAGES_DIR}/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${RELEASE_CONFIGURATION}/silk_float.lib DESTINATION ${CURRENT_PACKAGES_DIR}/lib/) # Install debug build file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/opus.lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/opus.pdb DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/celt.lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/celt.pdb DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/silk_common.lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/silk_common.pdb DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/silk_fixed.lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/silk_fixed.pdb DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/silk_float.lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/silk_float.pdb DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) else() # Install release build file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${RELEASE_CONFIGURATION}/opus.lib DESTINATION ${CURRENT_PACKAGES_DIR}/lib/) @@ -66,11 +58,18 @@ else() # Install debug build file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/opus.lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib/) file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/opus.dll DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin/) - file(INSTALL ${SOURCE_PATH}/win32/VS2015/${ARCH_DIR}/${DEBUG_CONFIGURATION}/opus.pdb DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin/) endif() +vcpkg_copy_pdbs() + # Install headers file(INSTALL ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR}/include RENAME opus) +if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic) + file(READ ${CURRENT_PACKAGES_DIR}/include/opus/opus_defines.h OPUS_DEFINES) + string(REPLACE "define OPUS_EXPORT" "define OPUS_EXPORT __declspec(dllimport)" OPUS_DEFINES "${OPUS_DEFINES}") + file(WRITE ${CURRENT_PACKAGES_DIR}/include/opus/opus_defines.h "${OPUS_DEFINES}") +endif() + # Handle copyright file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/opus RENAME copyright) From 032692ad9e15537e6f6793498c7fea0515c77a35 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Tue, 20 Jun 2017 15:37:31 -0700 Subject: [PATCH 11/50] added thor #1319 --- ports/thor/CONTROL | 4 +++ ports/thor/portfile.cmake | 71 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 75 insertions(+) create mode 100644 ports/thor/CONTROL create mode 100644 ports/thor/portfile.cmake diff --git a/ports/thor/CONTROL b/ports/thor/CONTROL new file mode 100644 index 000000000..9da28972a --- /dev/null +++ b/ports/thor/CONTROL @@ -0,0 +1,4 @@ +Source: thor +Version: +Description: +Build-Depends: sfml diff --git a/ports/thor/portfile.cmake b/ports/thor/portfile.cmake new file mode 100644 index 000000000..046dd57b5 --- /dev/null +++ b/ports/thor/portfile.cmake @@ -0,0 +1,71 @@ +include(vcpkg_common_functions) + + + +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/tests) +vcpkg_from_github(ARCHIVE + OUT_SOURCE_PATH SOURCE_PATH + REPO Bromeon/Thor + REF v2.0 + SHA512 634fa5286405d9a8a837c082ace98bbb02e609521418935855b9e2fcad57003dbe35088bd771cf6a9292e55d3787f7e463d7a4cca0d0f007509de2520d9a8cf9 + HEAD_REF master +) + + +set(ENV{SFML_ROOT} ${CURRENT_INSTALLED_DIR}) + +if(VCPKG_CRT_LINKAGE STREQUAL static) + set(THOR_STATIC_STD_LIBS ON) +else() + set(THOR_STATIC_STD_LIBS OFF) +endif() + + +if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic) + set(THOR_SHARED_LIBS ON) +else() + set(THOR_SHARED_LIBS OFF) +endif() + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS + -DTHOR_SHARED_LIBS=${THOR_SHARED_LIBS} + -DTHOR_STATIC_STD_LIBS=${THOR_STATIC_STD_LIBS} +) + +vcpkg_build_cmake() + +file(GLOB DLLS + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*.dll" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/src/*.dll" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*/src/*.dll" +) +file(GLOB LIBS + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*.lib" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/src/*.lib" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*/src/*.lib" +) +file(GLOB DEBUG_DLLS + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*.dll" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/src/*.dll" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*/src/*.dll" +) +file(GLOB DEBUG_LIBS + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*.lib" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/src/*.lib" + "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*/src/*.lib" +) +if(DLLS) + file(INSTALL ${DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/bin) +endif() +file(INSTALL ${LIBS} DESTINATION ${CURRENT_PACKAGES_DIR}/lib) +if(DEBUG_DLLS) + file(INSTALL ${DEBUG_DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin) +endif() + +file(INSTALL ${DEBUG_LIBS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib) + +file(INSTALL ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR}/include/thor) +file(INSTALL ${SOURCE_PATH}/License.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/thor RENAME copyright) From ab3b3e4fa435c560383367cd8f836f06d35b0460 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Tue, 20 Jun 2017 15:39:42 -0700 Subject: [PATCH 12/50] added description and version to control --- ports/thor/CONTROL | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ports/thor/CONTROL b/ports/thor/CONTROL index 9da28972a..ddaad1c5d 100644 --- a/ports/thor/CONTROL +++ b/ports/thor/CONTROL @@ -1,4 +1,4 @@ Source: thor -Version: -Description: +Version: v2.0 +Description: Extends the multimedia library SFML with higher-level features Build-Depends: sfml From 0cb1ec56b14c7906c48c28cc8f430cdd12386e44 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Tue, 20 Jun 2017 15:56:52 -0700 Subject: [PATCH 13/50] fix include folder --- ports/thor/portfile.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/thor/portfile.cmake b/ports/thor/portfile.cmake index 046dd57b5..710d464b9 100644 --- a/ports/thor/portfile.cmake +++ b/ports/thor/portfile.cmake @@ -67,5 +67,5 @@ endif() file(INSTALL ${DEBUG_LIBS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib) -file(INSTALL ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR}/include/thor) +file(INSTALL ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR}) file(INSTALL ${SOURCE_PATH}/License.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/thor RENAME copyright) From 053f3ee32f309208ac3af9c71b95253d4a144436 Mon Sep 17 00:00:00 2001 From: Tsukasa Sugiura Date: Thu, 22 Jun 2017 00:21:29 +0900 Subject: [PATCH 14/50] Fix QHull port to use release version Fix QHull port to use latest release version, because master/HEAD of QHull has some bugs. --- ports/qhull/CONTROL | 2 +- ports/qhull/portfile.cmake | 46 ++++++++++++++++++++++++-------------- 2 files changed, 30 insertions(+), 18 deletions(-) diff --git a/ports/qhull/CONTROL b/ports/qhull/CONTROL index aaf569f25..a36061285 100644 --- a/ports/qhull/CONTROL +++ b/ports/qhull/CONTROL @@ -1,3 +1,3 @@ Source: qhull -Version:1.0 +Version: 2015.2 Description: computes the convex hull, Delaunay triangulation, Voronoi diagram diff --git a/ports/qhull/portfile.cmake b/ports/qhull/portfile.cmake index 77c585b40..493a14e38 100644 --- a/ports/qhull/portfile.cmake +++ b/ports/qhull/portfile.cmake @@ -1,7 +1,7 @@ # Common Ambient Variables: # CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT} # CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET} -# CURRENT_PORT DIR = ${VCPKG_ROOT_DIR}\ports\${PORT} +# CURRENT_PORT_DIR = ${VCPKG_ROOT_DIR}\ports\${PORT} # PORT = current port name (zlib, etc) # TARGET_TRIPLET = current triplet (x86-windows, x64-windows-static, etc) # VCPKG_CRT_LINKAGE = C runtime linkage type (static, dynamic) @@ -13,33 +13,45 @@ include(vcpkg_common_functions) vcpkg_from_github( - OUT_SOURCE_PATH SOURCE_PATH + OUT_SOURCE_PATH SOURCE_PATH REPO qhull/qhull - REF master - SHA512 16aa9f93ce6fe8342a3b579881f10bb417679b0a70849e6b0cc5a89551e4de773a43bb0d54948196690d68d168f3a2a215e4600745ff1566302b0b426565fb25 + REF 5a79a0009454c86e9848646b3c296009125231bf # Qhull 2015.2 + SHA512 ebcbf452eff420c62f92b734e5359b275493930b3e6798801eb1a81aa4fbf631b41e298a6071698c3b18c0939c55ddbc1b66b7019091bb4988dcfc7deb25e287 + HEAD_REF master ) vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} - #PREFER_NINJA # Disable this option if project cannot be built with Ninja - OPTIONS - -DINCLUDE_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/include - -DMAN_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/doc/qhull - -DDOC_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/doc/qhull - - OPTIONS_RELEASE - -Dqhull_TARGETS_INSTALL=qhullcpp - -DLIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/lib - - OPTIONS_DEBUG - -Dqhull_TARGETS_INSTALL=qhullcpp_d - -DLIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/debug/lib + #PREFER_NINJA # Disable this option if project cannot be built with Ninja + OPTIONS + -DINCLUDE_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/include + -DMAN_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/doc/qhull + -DDOC_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/doc/qhull + OPTIONS_RELEASE + -DLIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/lib + OPTIONS_DEBUG + -DLIB_INSTALL_DIR=${CURRENT_PACKAGES_DIR}/debug/lib ) vcpkg_install_cmake() + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) file(GLOB_RECURSE HTMFILES ${CURRENT_PACKAGES_DIR}/include/*.htm) file(REMOVE ${HTMFILES}) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/doc) + +file(GLOB EXEFILES_RELEASE ${CURRENT_PACKAGES_DIR}/bin/*.exe) +file(GLOB EXEFILES_DEBUG ${CURRENT_PACKAGES_DIR}/debug/bin/*.exe) +file(COPY ${EXEFILES_RELEASE} DESTINATION ${CURRENT_PACKAGES_DIR}/tools/qhull) +file(COPY ${EXEFILES_DEBUG} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/tools/qhull) +file(REMOVE ${EXEFILES_RELEASE} ${EXEFILES_DEBUG}) + +if(VCPKG_LIBRARY_LINKAGE STREQUAL "static") + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin) + file(REMOVE ${CURRENT_PACKAGES_DIR}/lib/qhull.lib ${CURRENT_PACKAGES_DIR}/debug/lib/qhull_d.lib) + file(REMOVE ${CURRENT_PACKAGES_DIR}/lib/qhull_p.lib ${CURRENT_PACKAGES_DIR}/debug/lib/qhull_pd.lib) + file(REMOVE ${CURRENT_PACKAGES_DIR}/lib/qhull_r.lib ${CURRENT_PACKAGES_DIR}/debug/lib/qhull_rd.lib) +endif() # Handle copyright file(COPY ${SOURCE_PATH}/README.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/qhull) From dab6693550dcee29544058e72e108b540a4c08e3 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Wed, 21 Jun 2017 08:23:27 -0700 Subject: [PATCH 15/50] Added aurora as independant portfile --- ports/aurora/CONTROL | 3 +++ ports/aurora/portfile.cmake | 11 +++++++++++ 2 files changed, 14 insertions(+) create mode 100644 ports/aurora/CONTROL create mode 100644 ports/aurora/portfile.cmake diff --git a/ports/aurora/CONTROL b/ports/aurora/CONTROL new file mode 100644 index 000000000..172c019cd --- /dev/null +++ b/ports/aurora/CONTROL @@ -0,0 +1,3 @@ +Source: aurora +Version: 2017-06-21-c75699d2a8caa726260c29b6d7a0fd35f8f28933 +Description: Aurora is an open-source C++ library providing various rather uncommon C++ utilities diff --git a/ports/aurora/portfile.cmake b/ports/aurora/portfile.cmake new file mode 100644 index 000000000..32e3d804f --- /dev/null +++ b/ports/aurora/portfile.cmake @@ -0,0 +1,11 @@ +include(vcpkg_common_functions) +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO Bromeon/Aurora + REF c75699d2a8caa726260c29b6d7a0fd35f8f28933 + SHA512 862253e281eb441b773feb330d5ce4d7fe10769f516e927c0f875477ec912671fc35132a48986b2394f6d0a7160a5cb70afe868c597350c385ce23686b9613d6 + HEAD_REF master +) +file(INSTALL ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR}) +file(INSTALL ${SOURCE_PATH}/License.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/aurora RENAME copyright) +vcpkg_copy_pdbs() From f58052047adb5d9a3e3dee17feb9ff8f784d48e9 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Wed, 21 Jun 2017 09:04:57 -0700 Subject: [PATCH 16/50] [thor] Fixes aurora headers, defines SFML_STATIC, uses install target --- ports/thor/CONTROL | 2 +- ports/thor/portfile.cmake | 53 ++++++++++++++++++--------------------- 2 files changed, 26 insertions(+), 29 deletions(-) diff --git a/ports/thor/CONTROL b/ports/thor/CONTROL index ddaad1c5d..46396427b 100644 --- a/ports/thor/CONTROL +++ b/ports/thor/CONTROL @@ -1,4 +1,4 @@ Source: thor Version: v2.0 Description: Extends the multimedia library SFML with higher-level features -Build-Depends: sfml +Build-Depends: sfml, aurora diff --git a/ports/thor/portfile.cmake b/ports/thor/portfile.cmake index 710d464b9..32602a84c 100644 --- a/ports/thor/portfile.cmake +++ b/ports/thor/portfile.cmake @@ -35,37 +35,34 @@ vcpkg_configure_cmake( -DTHOR_STATIC_STD_LIBS=${THOR_STATIC_STD_LIBS} ) -vcpkg_build_cmake() +vcpkg_install_cmake() -file(GLOB DLLS - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*.dll" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/src/*.dll" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*/src/*.dll" + +set(CONFIG_FILE "${CURRENT_PACKAGES_DIR}/include/Thor/Config.hpp") + +file(READ ${CONFIG_FILE} CONFIG_H) + if(VCPKG_LIBRARY_LINKAGE STREQUAL "static") + string(REPLACE "defined(SFML_STATIC)" "1" CONFIG_H "${CONFIG_H}") + else() + string(REPLACE "defined(SFML_STATIC)" "0" CONFIG_H "${CONFIG_H}") + endif() + +file(WRITE ${CONFIG_FILE} "${CONFIG_H}") + +file(GLOB LICENSE + "${CURRENT_PACKAGES_DIR}/debug/LicenseThor.txt" + "${CURRENT_PACKAGES_DIR}/debug/LicenseAurora.txt" + "${CURRENT_PACKAGES_DIR}/LicenseThor.txt" + "${CURRENT_PACKAGES_DIR}/LicenseAurora.txt" ) -file(GLOB LIBS - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*.lib" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/src/*.lib" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-rel/*/src/*.lib" -) -file(GLOB DEBUG_DLLS - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*.dll" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/src/*.dll" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*/src/*.dll" -) -file(GLOB DEBUG_LIBS - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*.lib" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/src/*.lib" - "${CURRENT_BUILDTREES_DIR}/${TARGET_TRIPLET}-dbg/*/src/*.lib" -) -if(DLLS) - file(INSTALL ${DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/bin) -endif() -file(INSTALL ${LIBS} DESTINATION ${CURRENT_PACKAGES_DIR}/lib) -if(DEBUG_DLLS) - file(INSTALL ${DEBUG_DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin) + +if(LICENSE) + file(REMOVE ${LICENSE}) endif() -file(INSTALL ${DEBUG_LIBS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/Aurora) -file(INSTALL ${SOURCE_PATH}/include DESTINATION ${CURRENT_PACKAGES_DIR}) file(INSTALL ${SOURCE_PATH}/License.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/thor RENAME copyright) + +vcpkg_copy_pdbs() From cf27696e5a213bed7077dd33d6012a88bbcabd96 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Wed, 21 Jun 2017 09:29:50 -0700 Subject: [PATCH 17/50] remove internal copy used during build --- ports/thor/portfile.cmake | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ports/thor/portfile.cmake b/ports/thor/portfile.cmake index 32602a84c..c96df4728 100644 --- a/ports/thor/portfile.cmake +++ b/ports/thor/portfile.cmake @@ -11,6 +11,8 @@ vcpkg_from_github(ARCHIVE HEAD_REF master ) +file(COPY ${CURRENT_INSTALLED_DIR}/include/Aurora DESTINATION ${SOURCE_PATH}/extlibs/aurora/include) + set(ENV{SFML_ROOT} ${CURRENT_INSTALLED_DIR}) From bffa100a43c995b56b782f0de64dbaabb4f1f2a1 Mon Sep 17 00:00:00 2001 From: sigman Date: Thu, 22 Jun 2017 13:29:00 +0300 Subject: [PATCH 18/50] [magnum][magnum-plugins] Fixed plugins location, static plugins build Static libray linkage should work now, including plugins. --- ports/magnum-plugins/CONTROL | 2 +- ports/magnum-plugins/portfile.cmake | 20 ++++++++++++++++++++ ports/magnum/CONTROL | 2 +- ports/magnum/portfile.cmake | 15 +++++++++++++++ 4 files changed, 37 insertions(+), 2 deletions(-) diff --git a/ports/magnum-plugins/CONTROL b/ports/magnum-plugins/CONTROL index 9d684689a..f6e194c9f 100644 --- a/ports/magnum-plugins/CONTROL +++ b/ports/magnum-plugins/CONTROL @@ -1,4 +1,4 @@ Source: magnum-plugins -Version: jun2017-3 +Version: jun2017-4 Build-Depends: stb, magnum Description: Plugins for C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum-plugins/portfile.cmake b/ports/magnum-plugins/portfile.cmake index 0fe8f83a1..b26262490 100644 --- a/ports/magnum-plugins/portfile.cmake +++ b/ports/magnum-plugins/portfile.cmake @@ -15,8 +15,10 @@ vcpkg_apply_patches( if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(BUILD_STATIC 1) + set(BUILD_PLUGINS_STATIC 1) else() set(BUILD_STATIC 0) + set(BUILD_PLUGINS_STATIC 0) endif() vcpkg_configure_cmake( @@ -36,6 +38,9 @@ vcpkg_configure_cmake( -DWITH_ANYIMAGECONVERTER=ON -DWITH_ANYSCENEIMPORTER=ON -DBUILD_STATIC=${BUILD_STATIC} + -DBUILD_PLUGINS_STATIC=${BUILD_PLUGINS_STATIC} + -DMAGNUM_PLUGINS_DEBUG_DIR=${CURRENT_INSTALLED_DIR}/debug/bin/magnum-d + -DMAGNUM_PLUGINS_RELEASE_DIR=${CURRENT_INSTALLED_DIR}/bin/magnum ) vcpkg_install_cmake() @@ -46,6 +51,21 @@ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/bin) + # move plugin libs to conventional place + file(GLOB_RECURSE LIB_TO_MOVE ${CURRENT_PACKAGES_DIR}/lib/magnum/*) + file(COPY ${LIB_TO_MOVE} DESTINATION ${CURRENT_PACKAGES_DIR}/lib) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/magnum) + file(GLOB_RECURSE LIB_TO_MOVE_DBG ${CURRENT_PACKAGES_DIR}/debug/lib/magnum/*) + file(COPY ${LIB_TO_MOVE_DBG} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/magnum) +else() + # remove headers and libs for plugins + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib) + # hint vcpkg + set(VCPKG_POLICY_EMPTY_INCLUDE_FOLDER enabled) + set(VCPKG_POLICY_DLLS_WITHOUT_LIBS enabled) endif() # Handle copyright diff --git a/ports/magnum/CONTROL b/ports/magnum/CONTROL index 9245e4380..a040014da 100644 --- a/ports/magnum/CONTROL +++ b/ports/magnum/CONTROL @@ -1,4 +1,4 @@ Source: magnum -Version: jun2017-4 +Version: jun2017-5 Build-Depends: corrade, sdl2, openal-soft Description: C++11/C++14 and OpenGL graphics engine http://mosra.cz/blog/magnum.php diff --git a/ports/magnum/portfile.cmake b/ports/magnum/portfile.cmake index 14d5e0846..9eff36dcf 100644 --- a/ports/magnum/portfile.cmake +++ b/ports/magnum/portfile.cmake @@ -16,8 +16,10 @@ vcpkg_apply_patches( if(VCPKG_LIBRARY_LINKAGE STREQUAL static) set(BUILD_STATIC 1) + set(BUILD_PLUGINS_STATIC 1) else() set(BUILD_STATIC 0) + set(BUILD_PLUGINS_STATIC 0) endif() vcpkg_configure_cmake( @@ -38,6 +40,7 @@ vcpkg_configure_cmake( -DWITH_FONTCONVERTER=ON -DWITH_TGAIMAGECONVERTER=ON -DBUILD_STATIC=${BUILD_STATIC} + -DBUILD_PLUGINS_STATIC=${BUILD_PLUGINS_STATIC} -DMAGNUM_PLUGINS_DEBUG_DIR=${CURRENT_INSTALLED_DIR}/debug/bin/magnum-d -DMAGNUM_PLUGINS_RELEASE_DIR=${CURRENT_INSTALLED_DIR}/bin/magnum --trace @@ -64,6 +67,18 @@ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) if(VCPKG_LIBRARY_LINKAGE STREQUAL static) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/bin) + # move plugin libs to conventional place + file(GLOB_RECURSE LIB_TO_MOVE ${CURRENT_PACKAGES_DIR}/lib/magnum/*) + file(COPY ${LIB_TO_MOVE} DESTINATION ${CURRENT_PACKAGES_DIR}/lib) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/magnum) + file(GLOB_RECURSE LIB_TO_MOVE_DBG ${CURRENT_PACKAGES_DIR}/debug/lib/magnum/*) + file(COPY ${LIB_TO_MOVE_DBG} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/magnum) +else() + # remove headers and libs for plugins + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/MagnumPlugins) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/magnum) + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/magnum-d) endif() # Handle copyright From 5c93bc0102c2c90c31c14f7a978c946adc0ea904 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Thu, 22 Jun 2017 14:54:34 -0700 Subject: [PATCH 19/50] [dlib] Fix static builds. Add cmake files back in. --- ports/dlib/CONTROL | 2 +- ports/dlib/portfile.cmake | 47 ++++++++++++++++++++++----------------- 2 files changed, 27 insertions(+), 22 deletions(-) diff --git a/ports/dlib/CONTROL b/ports/dlib/CONTROL index a6e886c4a..d9db5b99d 100644 --- a/ports/dlib/CONTROL +++ b/ports/dlib/CONTROL @@ -1,4 +1,4 @@ Source: dlib -Version: 19.4-3 +Version: 19.4-4 Build-Depends: libjpeg-turbo, libpng, sqlite3, fftw3 Description: Modern C++ toolkit containing machine learning algorithms and tools for creating complex software in C++ diff --git a/ports/dlib/portfile.cmake b/ports/dlib/portfile.cmake index 2a5ae6f44..6c1bad0f8 100644 --- a/ports/dlib/portfile.cmake +++ b/ports/dlib/portfile.cmake @@ -8,43 +8,48 @@ include(vcpkg_common_functions) set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/dlib-19.4) vcpkg_download_distfile(ARCHIVE - URLS "http://dlib.net/files/dlib-19.4.tar.bz2" - FILENAME "dlib-19.4.tar.bz2" - SHA512 c5ae22c507b57a13d880d79e9671730829114d0276508b0a41b373d3abae9057d960fce84fafe1be468d943910853baaa70c88f2516e20a0c41f3895bf217f7b + URLS "http://dlib.net/files/dlib-19.4.tar.bz2" + FILENAME "dlib-19.4.tar.bz2" + SHA512 c5ae22c507b57a13d880d79e9671730829114d0276508b0a41b373d3abae9057d960fce84fafe1be468d943910853baaa70c88f2516e20a0c41f3895bf217f7b ) vcpkg_extract_source_archive(${ARCHIVE}) file(REMOVE_RECURSE ${SOURCE_PATH}/dlib/external/libjpeg) file(REMOVE_RECURSE ${SOURCE_PATH}/dlib/external/libpng) file(REMOVE_RECURSE ${SOURCE_PATH}/dlib/external/zlib) +# This fixes static builds; dlib doesn't pull in the needed transitive dependencies +file(READ "${SOURCE_PATH}/dlib/CMakeLists.txt" DLIB_CMAKE) +string(REPLACE "PNG_LIBRARY" "PNG_LIBRARIES" DLIB_CMAKE "${DLIB_CMAKE}") +file(WRITE "${SOURCE_PATH}/dlib/CMakeLists.txt" "${DLIB_CMAKE}") + vcpkg_configure_cmake( - SOURCE_PATH ${SOURCE_PATH} - PREFER_NINJA - OPTIONS - -DDLIB_LINK_WITH_SQLITE3=ON - -DDLIB_USE_FFTW=ON - -DDLIB_PNG_SUPPORT=ON - -DDLIB_JPEG_SUPPORT=ON - -DDLIB_USE_BLAS=OFF - -DDLIB_USE_LAPACK=OFF - -DDLIB_USE_CUDA=OFF - -DDLIB_GIF_SUPPORT=OFF - -DDLIB_USE_MKL_FFT=OFF - #-DDLIB_USE_CUDA=ON - OPTIONS_DEBUG - -DDLIB_ENABLE_ASSERTS=ON - #-DDLIB_ENABLE_STACK_TRACE=ON + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS + -DDLIB_LINK_WITH_SQLITE3=ON + -DDLIB_USE_FFTW=ON + -DDLIB_PNG_SUPPORT=ON + -DDLIB_JPEG_SUPPORT=ON + -DDLIB_USE_BLAS=OFF + -DDLIB_USE_LAPACK=OFF + -DDLIB_USE_CUDA=OFF + -DDLIB_GIF_SUPPORT=OFF + -DDLIB_USE_MKL_FFT=OFF + #-DDLIB_USE_CUDA=ON + OPTIONS_DEBUG + -DDLIB_ENABLE_ASSERTS=ON + #-DDLIB_ENABLE_STACK_TRACE=ON ) vcpkg_install_cmake() +vcpkg_fixup_cmake_targets(CONFIG_PATH lib/cmake) + # There is no way to suppress installation of the headers and resource files in debug build. file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) -file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/cmake) # Remove other files not required in package -file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/cmake) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/dlib/all) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/dlib/test) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/dlib/travis) From b0b186643c0ae0bc268bbf4ec2adeeb81c953004 Mon Sep 17 00:00:00 2001 From: Jozef Izso Date: Fri, 23 Jun 2017 13:49:56 +0200 Subject: [PATCH 20/50] grpc 1.4.0 --- ports/grpc/CONTROL | 2 +- ports/grpc/portfile.cmake | 5 ++--- ports/grpc/revert-c019e05.patch | 18 ------------------ 3 files changed, 3 insertions(+), 22 deletions(-) delete mode 100644 ports/grpc/revert-c019e05.patch diff --git a/ports/grpc/CONTROL b/ports/grpc/CONTROL index 47290a0d3..8298a047c 100644 --- a/ports/grpc/CONTROL +++ b/ports/grpc/CONTROL @@ -1,4 +1,4 @@ Source: grpc -Version: 1.3.1-1 +Version: 1.4.0 Build-Depends: zlib, openssl, protobuf, c-ares Description: An RPC library and framework \ No newline at end of file diff --git a/ports/grpc/portfile.cmake b/ports/grpc/portfile.cmake index 10e79cd55..3397e86dc 100644 --- a/ports/grpc/portfile.cmake +++ b/ports/grpc/portfile.cmake @@ -12,8 +12,8 @@ endif() vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO grpc/grpc - REF v1.3.1 - SHA512 1c9f35e84995158b75bb8694bb9d8c5ddafccf347c4827213290b221f9fc3ab9071c9f79a10a563e9cdfabae3f4b83d6148907f106066f54093242f818038438 + REF v1.4.0 + SHA512 183254e62604bae0ef8b97c3cda9718ec7ac03a1f29e29ecc582adf670d07ee177ae1ad92ffc042f8b12715f3afa8a0e4db34f88b826fe307249fd6eb7efd249 HEAD_REF master ) @@ -21,7 +21,6 @@ vcpkg_from_github( vcpkg_apply_patches( SOURCE_PATH ${SOURCE_PATH} PATCHES - ${CMAKE_CURRENT_LIST_DIR}/revert-c019e05.patch ${CMAKE_CURRENT_LIST_DIR}/disable-csharp-ext.patch ) diff --git a/ports/grpc/revert-c019e05.patch b/ports/grpc/revert-c019e05.patch deleted file mode 100644 index 77c501f77..000000000 --- a/ports/grpc/revert-c019e05.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index e09f729..c85a20a 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -11847,7 +11847,12 @@ endif (gRPC_BUILD_TESTS) - - - -- -+if (gRPC_INSTALL) -+ install(EXPORT gRPCTargets -+ DESTINATION ${CMAKE_INSTALL_CMAKEDIR} -+ NAMESPACE gRPC:: -+ ) -+endif() - - foreach(_config gRPCConfig gRPCConfigVersion) - configure_file(tools/cmake/${_config}.cmake.in From c21a0604e0b0590444f13aac632143f6df6685ff Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Fri, 23 Jun 2017 12:25:20 -0700 Subject: [PATCH 21/50] [apr] port update --- ports/apr/CONTROL | 2 +- ports/apr/portfile.cmake | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ports/apr/CONTROL b/ports/apr/CONTROL index eed3c518d..ac1b7d5c3 100644 --- a/ports/apr/CONTROL +++ b/ports/apr/CONTROL @@ -1,3 +1,3 @@ Source: apr -Version: 1.5.2 +Version: 1.6.2 Description: The Apache Portable Runtime (APR) is a C library that forms a system portability layer that covers many operating systems. diff --git a/ports/apr/portfile.cmake b/ports/apr/portfile.cmake index f65b44649..414ca1dda 100644 --- a/ports/apr/portfile.cmake +++ b/ports/apr/portfile.cmake @@ -7,11 +7,11 @@ # include(vcpkg_common_functions) -set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/apr-1.5.2) +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/apr-1.6.2) vcpkg_download_distfile(ARCHIVE - URLS "https://www.apache.org/dist/apr/apr-1.5.2.tar.bz2" - FILENAME "apr-1.5.2.tar.bz2" - SHA512 d1156ad16abf07887797777b56c2147c890f16d8445829b3e3b4917950d24c5fd2f8febd439992467a5ea0511da562c0fb4a7cfd8a235ab55882388bfa2b919d + URLS "https://www.apache.org/dist/apr/apr-1.6.2.tar.bz2" + FILENAME "apr-1.6.2.tar.bz2" + SHA512 20f449fde522f186b919b64ce6f90073b267557e17438607d31af917eca7941222dd7a7379d66f1430ff68f7e28fbccd140d24f3ca7aae8a876a550b19de284a ) vcpkg_extract_source_archive(${ARCHIVE}) From 77310c8722ae5f715e4c3477a1bd8a39a4644e0a Mon Sep 17 00:00:00 2001 From: Gilles Khouzam Date: Fri, 23 Jun 2017 14:12:50 -0700 Subject: [PATCH 22/50] Updating the OpenSSL UWP port to 1.0.2l --- ports/openssl/CONTROL | 2 +- ports/openssl/portfile-uwp.cmake | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ports/openssl/CONTROL b/ports/openssl/CONTROL index fb5861cd4..465f941b7 100644 --- a/ports/openssl/CONTROL +++ b/ports/openssl/CONTROL @@ -1,3 +1,3 @@ Source: openssl -Version: 1.0.2k-5 +Version: 1.0.21-1 Description: OpenSSL is an open source project that provides a robust, commercial-grade, and full-featured toolkit for the Transport Layer Security (TLS) and Secure Sockets Layer (SSL) protocols. It is also a general-purpose cryptography library. diff --git a/ports/openssl/portfile-uwp.cmake b/ports/openssl/portfile-uwp.cmake index cc29c7e4d..e1f7a7932 100644 --- a/ports/openssl/portfile-uwp.cmake +++ b/ports/openssl/portfile-uwp.cmake @@ -27,7 +27,7 @@ endif() include(vcpkg_common_functions) -set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/openssl-OpenSSL_1_0_2k_WinRT) +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/openssl-OpenSSL_1_0_2l_WinRT) vcpkg_find_acquire_program(PERL) vcpkg_find_acquire_program(JOM) @@ -36,9 +36,9 @@ get_filename_component(PERL_EXE_PATH ${PERL} DIRECTORY) set(ENV{PATH} "$ENV{PATH};${PERL_EXE_PATH};${JOM_EXE_PATH}") vcpkg_download_distfile(ARCHIVE - URLS "https://github.com/Microsoft/openssl/archive/OpenSSL_1_0_2k_WinRT.zip" - FILENAME "openssl-microsoft-1.0.2k_WinRT.zip" - SHA512 afb434ef69c399f690f7ce723fabb228f77a12428f19062c5df3b8b841a2a7881c01150fdcfd2fab23867e3963292874a08ad227b37d168907b507fb1d7fede7 + URLS "https://github.com/Microsoft/openssl/archive/OpenSSL_1_0_2l_WinRT.zip" + FILENAME "openssl-microsoft-1.0.2l_WinRT.zip" + SHA512 238b3daad7f1a2486e09d47e6d1bd4b0aa8e8a896358c6dfe11a77c2654da1b29d3c7612f9d200d5be5a020f33d96fe39cd75b99aa35aa4129feb756f7f98ee8 ) vcpkg_extract_source_archive(${ARCHIVE}) From bffc9699991d51bd627b606d6dc47eef2cfd3955 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Fri, 23 Jun 2017 14:58:52 -0700 Subject: [PATCH 23/50] [dirent] new port need by #1343 --- ports/dirent/CONTROL | 3 +++ ports/dirent/portfile.cmake | 11 +++++++++++ 2 files changed, 14 insertions(+) create mode 100644 ports/dirent/CONTROL create mode 100644 ports/dirent/portfile.cmake diff --git a/ports/dirent/CONTROL b/ports/dirent/CONTROL new file mode 100644 index 000000000..50f6d7ede --- /dev/null +++ b/ports/dirent/CONTROL @@ -0,0 +1,3 @@ +Source: dirent +Version: 2017-06-23-5c7194c2fe2c68c1a8212712c0b4b6195382d27d +Description: Dirent is a C/C++ programming interface that allows programmers to retrieve information about files and directories under Linux/UNIX. This project provides Linux compatible Dirent interface for Microsoft Windows. diff --git a/ports/dirent/portfile.cmake b/ports/dirent/portfile.cmake new file mode 100644 index 000000000..9476a8dcd --- /dev/null +++ b/ports/dirent/portfile.cmake @@ -0,0 +1,11 @@ +include(vcpkg_common_functions) +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO tronkko/dirent + REF 8b1db5092479a73d47eafd3de739b27e876e6bf3 + SHA512 f529aa65c2a4b8249c1291f3bccad25fa3a9c2146a2c74abc0a4710f68e2bd6f73cd52682bb406fbcab71d6a5225a354f9e8bdc22ce63b7a4e64bb65bab34b9f + HEAD_REF master +) +file(INSTALL ${SOURCE_PATH}/include/ DESTINATION ${CURRENT_PACKAGES_DIR}/include) +file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/dirent RENAME copyright) +vcpkg_copy_pdbs() From d7989ade6913b95a84c1e57069fd82bd3a623c11 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Fri, 23 Jun 2017 16:25:31 -0700 Subject: [PATCH 24/50] [rtmidi] init port #582 --- ports/rtmidi/CMakeLists.txt | 41 +++++++++++++++++++++++++++++++++++++ ports/rtmidi/CONTROL | 3 +++ ports/rtmidi/portfile.cmake | 20 ++++++++++++++++++ 3 files changed, 64 insertions(+) create mode 100644 ports/rtmidi/CMakeLists.txt create mode 100644 ports/rtmidi/CONTROL create mode 100644 ports/rtmidi/portfile.cmake diff --git a/ports/rtmidi/CMakeLists.txt b/ports/rtmidi/CMakeLists.txt new file mode 100644 index 000000000..eac2d2f54 --- /dev/null +++ b/ports/rtmidi/CMakeLists.txt @@ -0,0 +1,41 @@ +cmake_minimum_required(VERSION 3.8) +project(rtmidi CXX) +set(RTMIDI_SOURCES + ${PROJECT_SOURCE_DIR}/RtMidi.cpp + ${PROJECT_SOURCE_DIR}/rtmidi_c.cpp +) + +set(RTMIDI_HEADERS + ${PROJECT_SOURCE_DIR}/RtMidi.h + ${PROJECT_SOURCE_DIR}/rtmidi_c.h +) + +include_directories(${RTMIDI_HEADERS}) + +if(BUILD_SHARED) + add_library(rtmidi SHARED ${RTMIDI_SOURCES}) + target_compile_definitions(rtmidi PRIVATE -DRTMIDI_EXPORT) +else() + add_library(rtmidi STATIC ${RTMIDI_SOURCES}) +endif() + + +file(READ "${PROJECT_SOURCE_DIR}/rtmidi_c.h" RTMIDI_EXPORT) +if (BUILD_SHARED) + string(REPLACE "if defined(RTMIDI_EXPORT)" "if 1" RTMIDI_EXPORT "${RTMIDI_EXPORT}") +else() + string(REPLACE "if defined(RTMIDI_EXPORT)" "if 0" RTMIDI_EXPORT "${RTMIDI_EXPORT}") +endif() +file(WRITE "${PROJECT_BINARY_DIR}/rtmidi_c.h" "${RTMIDI_EXPORT}") + +install( + TARGETS rtmidi + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib +) + +if(NOT DISABLE_INSTALL_HEADERS) + install(FILES "${PROJECT_SOURCE_DIR}/RtMidi.h" DESTINATION include) + install(FILES "${PROJECT_BINARY_DIR}/rtmidi_c.h" DESTINATION include) +endif() diff --git a/ports/rtmidi/CONTROL b/ports/rtmidi/CONTROL new file mode 100644 index 000000000..9cf64df9e --- /dev/null +++ b/ports/rtmidi/CONTROL @@ -0,0 +1,3 @@ +Source: rtmidi +Version: 2.1.1 +Description: A set of C++ classes that provide a common API for realtime MIDI input/output across Linux (ALSA & JACK), Macintosh OS X (CoreMidi & JACK) and Windows (Multimedia) diff --git a/ports/rtmidi/portfile.cmake b/ports/rtmidi/portfile.cmake new file mode 100644 index 000000000..cee6e1a73 --- /dev/null +++ b/ports/rtmidi/portfile.cmake @@ -0,0 +1,20 @@ +include(vcpkg_common_functions) + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO thestk/rtmidi + REF 2.1.1 + SHA512 4d378720dd0f7c0e1a87741c088756839878ed56465b053040f70a1e039828fe221a6b1669b77b2fdd146cb192934c5719cc934c2c6a6304f44dbee2972c68e8 + HEAD_REF master +) +file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH}) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=ON +) + +vcpkg_install_cmake() + +file(INSTALL ${SOURCE_PATH}/readme DESTINATION ${CURRENT_PACKAGES_DIR}/share/rtmidi RENAME copyright) From ac9cec6e1c3eea8d9dd28f94a3299bb4062fc224 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Fri, 23 Jun 2017 16:31:26 -0700 Subject: [PATCH 25/50] Small fix BUILD_SHARED_LIBS --- ports/rtmidi/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/rtmidi/CMakeLists.txt b/ports/rtmidi/CMakeLists.txt index eac2d2f54..6a09540b8 100644 --- a/ports/rtmidi/CMakeLists.txt +++ b/ports/rtmidi/CMakeLists.txt @@ -12,7 +12,7 @@ set(RTMIDI_HEADERS include_directories(${RTMIDI_HEADERS}) -if(BUILD_SHARED) +if(BUILD_SHARED_LIBS) add_library(rtmidi SHARED ${RTMIDI_SOURCES}) target_compile_definitions(rtmidi PRIVATE -DRTMIDI_EXPORT) else() From 2100e95c25db8b76058d9e125c5b2fcdce9fd74a Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Fri, 23 Jun 2017 16:33:25 -0700 Subject: [PATCH 26/50] Small fix BUILD_SHARED_LIBS --- ports/rtmidi/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/rtmidi/CMakeLists.txt b/ports/rtmidi/CMakeLists.txt index 6a09540b8..f334a598e 100644 --- a/ports/rtmidi/CMakeLists.txt +++ b/ports/rtmidi/CMakeLists.txt @@ -21,7 +21,7 @@ endif() file(READ "${PROJECT_SOURCE_DIR}/rtmidi_c.h" RTMIDI_EXPORT) -if (BUILD_SHARED) +if (BUILD_SHARED_LIBS) string(REPLACE "if defined(RTMIDI_EXPORT)" "if 1" RTMIDI_EXPORT "${RTMIDI_EXPORT}") else() string(REPLACE "if defined(RTMIDI_EXPORT)" "if 0" RTMIDI_EXPORT "${RTMIDI_EXPORT}") From 9eca90f2d1c4f2ddc0cd0153b7addbff3757bac4 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Fri, 23 Jun 2017 16:37:25 -0700 Subject: [PATCH 27/50] Small fix BUILD_SHARED_LIBS use vcpkg lib linkage --- ports/rtmidi/CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ports/rtmidi/CMakeLists.txt b/ports/rtmidi/CMakeLists.txt index f334a598e..0603fdcb8 100644 --- a/ports/rtmidi/CMakeLists.txt +++ b/ports/rtmidi/CMakeLists.txt @@ -12,6 +12,13 @@ set(RTMIDI_HEADERS include_directories(${RTMIDI_HEADERS}) +if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic) + set(BUILD_SHARED_LIBS ON) +else() + set(BUILD_SHARED_LIBS OFF) +endif() + + if(BUILD_SHARED_LIBS) add_library(rtmidi SHARED ${RTMIDI_SOURCES}) target_compile_definitions(rtmidi PRIVATE -DRTMIDI_EXPORT) From 26b489772842ad009aa5bd4bdd316c6a73d26503 Mon Sep 17 00:00:00 2001 From: Vinnie Falco Date: Fri, 23 Jun 2017 21:06:39 -0700 Subject: [PATCH 28/50] [beast] Update to version 66 --- ports/beast/CONTROL | 2 +- ports/beast/portfile.cmake | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ports/beast/CONTROL b/ports/beast/CONTROL index 1dc1e4a1c..c0dc43c05 100644 --- a/ports/beast/CONTROL +++ b/ports/beast/CONTROL @@ -1,4 +1,4 @@ Source: beast -Version: v63 +Version: v66 Build-Depends: boost Description: HTTP/1 and WebSocket, header-only using Boost.Asio and C++11 diff --git a/ports/beast/portfile.cmake b/ports/beast/portfile.cmake index 86011da55..726be4b1e 100644 --- a/ports/beast/portfile.cmake +++ b/ports/beast/portfile.cmake @@ -4,8 +4,8 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO vinniefalco/Beast - REF f68dc343e7c077caee8a95b2a59a2ccb9f979567 - SHA512 d1c4ce5ee4d4b7cb20084c96af87ce106a4474631754a54a7cc19343e0767ed7a14cdb00f27bb1958e35f411b99c90444efd578e8c77e98d7e416703ea6f28bd + REF 7fb75d0627f7842a6a706b810d427962509e0e52 + SHA512 5d086d2edf18facc3f379c42ffcc2679f9c03f891d58f2c8e6cb1a9aa6ee73b232544d1c2a86ce9c42dbc9a41a58bd3480f958cc1c569e8b3b1890755ecfd7fc HEAD_REF master ) From 88fd6f14d8a66a20ccdaea06b5a22067a94387e9 Mon Sep 17 00:00:00 2001 From: atkawa7 Date: Fri, 23 Jun 2017 23:27:31 -0700 Subject: [PATCH 29/50] [ctemplate] new port #543 --- ports/ctemplate/CMakeLists.txt | 97 ++++++++++++++++++++++++++++++++++ ports/ctemplate/CONTROL | 3 ++ ports/ctemplate/fix-msvc.patch | 17 ++++++ ports/ctemplate/portfile.cmake | 39 ++++++++++++++ 4 files changed, 156 insertions(+) create mode 100644 ports/ctemplate/CMakeLists.txt create mode 100644 ports/ctemplate/CONTROL create mode 100644 ports/ctemplate/fix-msvc.patch create mode 100644 ports/ctemplate/portfile.cmake diff --git a/ports/ctemplate/CMakeLists.txt b/ports/ctemplate/CMakeLists.txt new file mode 100644 index 000000000..22869f7c5 --- /dev/null +++ b/ports/ctemplate/CMakeLists.txt @@ -0,0 +1,97 @@ +cmake_minimum_required(VERSION 3.5.1) +project(libctemplate C CXX) + +# find_package(PythonInterp) + +if(MSVC) + add_compile_options(/W3 /wd4005 /wd4996 /wd4018 -D_CRT_SECURE_NO_WARNINGS) + add_definitions(-D_VARIADIC_MAX=10) +endif() + +set(SOURCE_PATH ${PROJECT_SOURCE_DIR}/src) +set(BASE_SOURCE_PATH ${SOURCE_PATH}/base) +set(WINDOWS_SOURCE_PATH ${SOURCE_PATH}/windows) +set(HTMLPARSER_SOURCE_PATH ${SOURCE_PATH}/htmlparser) + +set(COMMON_INCLUDES ${PROJECT_BINARY_DIR}/include) + +set(HTMLPARSER_CONFIG ${HTMLPARSER_SOURCE_PATH}/htmlparser_fsm.config) +set(JSPASPER_CONFIG ${HTMLPARSER_SOURCE_PATH}/jsparser_fsm.config) +set(FSM_GENERATOR ${HTMLPARSER_SOURCE_PATH}/generate_fsm.py) + +set(BASE_HEADERS + "${BASE_SOURCE_PATH}/arena.h" + "${BASE_SOURCE_PATH}/manual_constructor.h" + "${BASE_SOURCE_PATH}/mutex.h" + "${BASE_SOURCE_PATH}/small_map.h" + "${BASE_SOURCE_PATH}/thread_annotations.h" + "${BASE_SOURCE_PATH}/util.h" + "${BASE_SOURCE_PATH}/arena-inl.h" +) + +set( + HTMLPARSER_HEADERS + "${HTMLPARSER_SOURCE_PATH}/htmlparser.h" + "${HTMLPARSER_SOURCE_PATH}/htmlparser_cpp.h" + "${HTMLPARSER_SOURCE_PATH}/jsparser.h" + "${HTMLPARSER_SOURCE_PATH}/statemachine.h" +) +set(SRC_FILES + "${SOURCE_PATH}/base/arena.cc" + "${SOURCE_PATH}/htmlparser/htmlparser.cc" + "${SOURCE_PATH}/htmlparser/jsparser.cc" + "${SOURCE_PATH}/htmlparser/statemachine.cc" + "${SOURCE_PATH}/per_expand_data.cc" + "${SOURCE_PATH}/template.cc" + "${SOURCE_PATH}/template_annotator.cc" + "${SOURCE_PATH}/template_cache.cc" + "${SOURCE_PATH}/template_dictionary.cc" + "${SOURCE_PATH}/template_modifiers.cc" + "${SOURCE_PATH}/template_namelist.cc" + "${SOURCE_PATH}/template_pathops.cc" + "${SOURCE_PATH}/template_string.cc" + "${SOURCE_PATH}/windows/port.cc" +) + +file(COPY "${WINDOWS_SOURCE_PATH}/" DESTINATION ${COMMON_INCLUDES}) +file(COPY "${WINDOWS_SOURCE_PATH}/config.h" DESTINATION ${COMMON_INCLUDES}/windows) +file(COPY "${WINDOWS_SOURCE_PATH}/port.h" DESTINATION ${COMMON_INCLUDES}/windows) +file(COPY ${HTMLPARSER_HEADERS} DESTINATION ${COMMON_INCLUDES}/htmlparser) +file(COPY ${BASE_HEADERS} DESTINATION ${COMMON_INCLUDES}/base) + +execute_process( + COMMAND ${PYTHON_EXECUTABLE} ${FSM_GENERATOR} ${HTMLPARSER_CONFIG} + WORKING_DIRECTORY ${COMMON_INCLUDES}/htmlparser + OUTPUT_VARIABLE HTMLPARSER_CONFIG_H +) +execute_process( + COMMAND ${PYTHON_EXECUTABLE} ${FSM_GENERATOR} ${JSPASPER_CONFIG} + WORKING_DIRECTORY ${COMMON_INCLUDES}/htmlparser + OUTPUT_VARIABLE JSPASPER_CONFIG_H +) + +file(WRITE "${COMMON_INCLUDES}/htmlparser/htmlparser_fsm.h" "${HTMLPARSER_CONFIG_H}") +file(WRITE "${COMMON_INCLUDES}/htmlparser/jsparser_fsm.h" "${JSPASPER_CONFIG_H}") + +option(BUILD_SHARED_LIBRARY "Building shared library" ON) + +include_directories(${COMMON_INCLUDES}) + +if(BUILD_SHARED_LIBRARY) + add_library(libctemplate SHARED ${SRC_FILES}) +else() + add_library(libctemplate STATIC ${SRC_FILES} ) + # Note: CTEMPLATE_DLL_DECL should be empty to build static file + target_compile_definitions(libctemplate PRIVATE -DCTEMPLATE_DLL_DECL=) +endif() + +install( + TARGETS libctemplate + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib +) + +if(NOT DISABLE_INSTALL_HEADERS) + install(DIRECTORY "${COMMON_INCLUDES}/" DESTINATION include FILES_MATCHING PATTERN "*.h") +endif() diff --git a/ports/ctemplate/CONTROL b/ports/ctemplate/CONTROL new file mode 100644 index 000000000..eb78d4c0f --- /dev/null +++ b/ports/ctemplate/CONTROL @@ -0,0 +1,3 @@ +Source: ctemplate +Version: 2017-06-23-44b7c5b918a08ad561c63e9d28beecb40c10ebca +Description: C++ CTemplate system diff --git a/ports/ctemplate/fix-msvc.patch b/ports/ctemplate/fix-msvc.patch new file mode 100644 index 000000000..acfbce4bf --- /dev/null +++ b/ports/ctemplate/fix-msvc.patch @@ -0,0 +1,17 @@ +diff --git a/src/per_expand_data.cc b/src/per_expand_data.cc +index f8f3025..0a468cf 100644 +--- a/src/per_expand_data.cc ++++ b/src/per_expand_data.cc +@@ -42,10 +42,12 @@ namespace ctemplate { + + using std::string; + ++#ifndef _MSC_VER + bool PerExpandData::DataEq::operator()(const char* s1, const char* s2) const { + return ((s1 == 0 && s2 == 0) || + (s1 && s2 && *s1 == *s2 && strcmp(s1, s2) == 0)); + } ++#endif + + PerExpandData::~PerExpandData() { + delete map_; diff --git a/ports/ctemplate/portfile.cmake b/ports/ctemplate/portfile.cmake new file mode 100644 index 000000000..cb1e07b74 --- /dev/null +++ b/ports/ctemplate/portfile.cmake @@ -0,0 +1,39 @@ +include(vcpkg_common_functions) + +set(GIT_REF 44b7c5b918a08ad561c63e9d28beecb40c10ebca) +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO OlafvdSpek/ctemplate + REF 44b7c5b918a08ad561c63e9d28beecb40c10ebca + SHA512 b572f6d0d182e977d3a459e68bde6244dad7196c44c16407990dc1fb6a7a93bcd8d6851e515d50b6051c1d011f71695f895f6ab233664baadae0bf6a3d464305 + HEAD_REF master +) + +file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH}) + +vcpkg_find_acquire_program(PYTHON2) + +vcpkg_apply_patches( + SOURCE_PATH ${SOURCE_PATH} + PATCHES + ${CMAKE_CURRENT_LIST_DIR}/fix-msvc.patch +) + +if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic) + set (BUILD_SHARED_LIBRARY ON) +else() + set(BUILD_SHARED_LIBRARY OFF) +endif() + + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + OPTIONS -DPYTHON_EXECUTABLE=${PYTHON2} -DBUILD_SHARED_LIBRARY=${BUILD_SHARED_LIBRARY} + OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=ON +) + +vcpkg_install_cmake() + +file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/ctemplate RENAME copyright) + +vcpkg_copy_pdbs() From b64935e67ac6817defd862fc7fbc3a1f4819d79c Mon Sep 17 00:00:00 2001 From: Tsukasa Sugiura Date: Sun, 25 Jun 2017 04:07:09 +0900 Subject: [PATCH 30/50] Add Kinect SDK v1.x port Add Kinect for Windows SDK v1.x port. --- ports/kinectsdk1/CONTROL | 3 ++ ports/kinectsdk1/portfile.cmake | 52 +++++++++++++++++++++++++++++++++ 2 files changed, 55 insertions(+) create mode 100644 ports/kinectsdk1/CONTROL create mode 100644 ports/kinectsdk1/portfile.cmake diff --git a/ports/kinectsdk1/CONTROL b/ports/kinectsdk1/CONTROL new file mode 100644 index 000000000..21f531425 --- /dev/null +++ b/ports/kinectsdk1/CONTROL @@ -0,0 +1,3 @@ +Source: kinectsdk1 +Version: 1.8 +Description: Kinect for Windows SDK for Kinect v1 sensor. diff --git a/ports/kinectsdk1/portfile.cmake b/ports/kinectsdk1/portfile.cmake new file mode 100644 index 000000000..61f006492 --- /dev/null +++ b/ports/kinectsdk1/portfile.cmake @@ -0,0 +1,52 @@ +# Common Ambient Variables: +# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT} +# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET} +# CURRENT_PORT_DIR = ${VCPKG_ROOT_DIR}\ports\${PORT} +# PORT = current port name (zlib, etc) +# TARGET_TRIPLET = current triplet (x86-windows, x64-windows-static, etc) +# VCPKG_CRT_LINKAGE = C runtime linkage type (static, dynamic) +# VCPKG_LIBRARY_LINKAGE = target library linkage type (static, dynamic) +# VCPKG_ROOT_DIR = +# VCPKG_TARGET_ARCHITECTURE = target architecture (x64, x86, arm) +# + +include(vcpkg_common_functions) + +get_filename_component(KINECTSDK10_DIR "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Kinect;SDKInstallPath]" ABSOLUTE CACHE) +if(NOT EXISTS "${KINECTSDK10_DIR}") + message(FATAL_ERROR "Error: Could not find Kinect for Windows SDK v1.x.") +endif() + +file( + INSTALL + "${KINECTSDK10_DIR}/inc/NuiApi.h" + "${KINECTSDK10_DIR}/inc/NuiImageCamera.h" + "${KINECTSDK10_DIR}/inc/NuiSensor.h" + "${KINECTSDK10_DIR}/inc/NuiSkeleton.h" + DESTINATION + ${CURRENT_PACKAGES_DIR}/include/kinectsdk1 +) + +if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86") + set(ARCHITECTURE x86) +elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64") + set(ARCHITECTURE amd64) +endif() + +file( + INSTALL + "${KINECTSDK10_DIR}/lib/${ARCHITECTURE}/Kinect10.lib" + DESTINATION + ${CURRENT_PACKAGES_DIR}/lib +) + +file( + INSTALL + "${KINECTSDK10_DIR}/lib/${ARCHITECTURE}/Kinect10.lib" + DESTINATION + ${CURRENT_PACKAGES_DIR}/debug/lib +) + +# Handle copyright +file(COPY "${KINECTSDK10_DIR}/SDKEula.rtf" DESTINATION ${CURRENT_PACKAGES_DIR}/share/kinectsdk1) +file(RENAME ${CURRENT_PACKAGES_DIR}/share/kinectsdk1/SDKEula.rtf ${CURRENT_PACKAGES_DIR}/share/kinectsdk1/copyright) \ No newline at end of file From b9f718cbad306baba8bc1952593192d3efdb5c57 Mon Sep 17 00:00:00 2001 From: Jens Frederich Date: Mon, 26 Jun 2017 16:51:36 +0200 Subject: [PATCH 31/50] [think-cell-range] Update to version 498839d --- ports/think-cell-range/CONTROL | 2 +- ports/think-cell-range/portfile.cmake | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ports/think-cell-range/CONTROL b/ports/think-cell-range/CONTROL index 3b5872232..b7d53af12 100644 --- a/ports/think-cell-range/CONTROL +++ b/ports/think-cell-range/CONTROL @@ -1,5 +1,5 @@ Source: think-cell-range Maintainer: jfrederich@gmail.com -Version: e2d3018 +Version: 498839d Description: think-cell's range library , , Build-Depends: boost diff --git a/ports/think-cell-range/portfile.cmake b/ports/think-cell-range/portfile.cmake index 858461e36..56d01a55e 100644 --- a/ports/think-cell-range/portfile.cmake +++ b/ports/think-cell-range/portfile.cmake @@ -1,9 +1,9 @@ include(vcpkg_common_functions) -set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/range-e2d3018c3a797e7328dea005e72b34cace8b1fc6) +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/range-498839d41519d38bb81089f7d0f517026bd042cc) vcpkg_download_distfile(ARCHIVE - URLS "https://github.com/think-cell/range/archive/e2d3018c3a797e7328dea005e72b34cace8b1fc6.zip" - FILENAME "think-cell_range-e2d3018.zip" - SHA512 13c74aba4950a84fdf446c976564030b18a740c5ce42b7650116a0559ba9e9a59471ff0f80132c626bc442402b3717805d3615b9ea70751e2dd1e648fd9f7916 + URLS "https://github.com/think-cell/range/archive/498839d41519d38bb81089f7d0f517026bd042cc.zip" + FILENAME "think-cell_range-498839d.zip" + SHA512 801e987c828c954cb50f9a6f9f2feee2ce05f7232d531ecce7394800ecc5a750992795da173fb72b6efcabd6978015a650730682b7db3f874fb8aaac28869711 ) vcpkg_extract_source_archive(${ARCHIVE}) From 81e9de89b9d6be074a62344dfd68bfea097ce3b7 Mon Sep 17 00:00:00 2001 From: codicodi Date: Mon, 26 Jun 2017 22:35:44 +0200 Subject: [PATCH 32/50] [opus] update to 1.2.1 --- ports/opus/CONTROL | 2 +- ports/opus/portfile.cmake | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ports/opus/CONTROL b/ports/opus/CONTROL index dbff6715a..6f794c986 100644 --- a/ports/opus/CONTROL +++ b/ports/opus/CONTROL @@ -1,3 +1,3 @@ Source: opus -Version: 1.2 +Version: 1.2.1 Description: Totally open, royalty-free, highly versatile audio codec diff --git a/ports/opus/portfile.cmake b/ports/opus/portfile.cmake index f2a6dc018..5bc9b6b60 100644 --- a/ports/opus/portfile.cmake +++ b/ports/opus/portfile.cmake @@ -6,8 +6,8 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO xiph/opus - REF v1.2 - SHA512 4fef70e3b439613f85ede30cc401b84c77f1828f56908d04cb76061b8116c083cc035b50eaec4205110481e9d8b794b9c05f6778d8428cc68f6d57bd3db721ca + REF v1.2.1 + SHA512 fdc64b43875dd07dc9eb1c37e9a61d1c10e3095de62ed9597d51b93445136958c9f5fee78c33ae7f90c72a20200083cdc727d8e79f2f9e580ad4e2f8c50cccb4 HEAD_REF master ) From 112041512d1b26caad3939bd5947a6305830c56d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Ho=C5=99e=C5=88ovsk=C3=BD?= Date: Tue, 27 Jun 2017 12:38:01 +0200 Subject: [PATCH 33/50] Update Catch to 1.9.6 --- ports/catch/CONTROL | 2 +- ports/catch/portfile.cmake | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ports/catch/CONTROL b/ports/catch/CONTROL index cce74b299..1c8d6b94a 100644 --- a/ports/catch/CONTROL +++ b/ports/catch/CONTROL @@ -1,3 +1,3 @@ Source: catch -Version: 1.9.5-1 +Version: 1.9.6 Description: C++ Automated Test Cases in Headers diff --git a/ports/catch/portfile.cmake b/ports/catch/portfile.cmake index d3cd5a2bb..98342e052 100644 --- a/ports/catch/portfile.cmake +++ b/ports/catch/portfile.cmake @@ -1,11 +1,11 @@ include(vcpkg_common_functions) -set(CATCH_VERSION v1.9.5) +set(CATCH_VERSION v1.9.6) vcpkg_download_distfile(HEADER URLS "https://github.com/philsquared/Catch/releases/download/${CATCH_VERSION}/catch.hpp" FILENAME "catch-${CATCH_VERSION}.hpp" - SHA512 4e5dc6959903282c90c7e7981238248072c7f5d4083ccfcd62ca8db494bed46cbd280624d1bafaf2221ca02e7877a4cc319f1adee06dfaeee9da3757b7a7ba56 + SHA512 a0e4d568a5d90e72cef6ae9e741a66909235498c2901e96623892e5b323cb3bc51d55617ee6a42b30938a0cf2564323c621bd201d94eb67ba9c4fe5de65c10ee ) vcpkg_download_distfile(LICENSE From f761259f34706c7c8529fc2340c5e55a9a0c69e8 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Tue, 27 Jun 2017 10:22:29 -0700 Subject: [PATCH 34/50] [boost] Update diff hash. No version bump required because contents are functionally identical. --- ports/boost/portfile.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ports/boost/portfile.cmake b/ports/boost/portfile.cmake index b8d56ee90..8db544237 100644 --- a/ports/boost/portfile.cmake +++ b/ports/boost/portfile.cmake @@ -15,8 +15,8 @@ vcpkg_extract_source_archive(${ARCHIVE_FILE}) # apply boost range hotfix vcpkg_download_distfile(DIFF URLS "https://github.com/boostorg/range/commit/e7ebe14707130cda7b72e0ae5e93b17157fdb6a2.diff" - FILENAME "boost-range-has_range_iterator-hotfix_e7ebe14707130cda7b72e0ae5e93b17157fdb6a2.diff" - SHA512 77dad42bfd9bbab2bbddf361d5b7ad3dd6f812f4294c6dd1a677bb4d0191a4fff43bca32fdd4fce05d428562abb6e38afd0fd33ca6a8b5f28481d70cd2f3dd67 + FILENAME "boost-range-has_range_iterator-hotfix_e7ebe14707130cda7b72e0ae5e93b17157fdb6a2-2.diff" + SHA512 88392fcf092d07ee2de66d937634688eef1d7491a4e2fb0fce064b4e631813a0814455a329f9eed8b968ff205883751d51a86edecc8e355790fc8a35d6742483 ) FILE(READ "${DIFF}" content) From e8f819e04e6aed6327537f954a9eda02fca49d1a Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Tue, 27 Jun 2017 11:24:31 -0700 Subject: [PATCH 35/50] [vcpkg-fixup-cmake-targets] Fix bug when port has no unused cmake config files. --- scripts/cmake/vcpkg_fixup_cmake_targets.cmake | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/scripts/cmake/vcpkg_fixup_cmake_targets.cmake b/scripts/cmake/vcpkg_fixup_cmake_targets.cmake index c56b96ccc..6fa096cbd 100644 --- a/scripts/cmake/vcpkg_fixup_cmake_targets.cmake +++ b/scripts/cmake/vcpkg_fixup_cmake_targets.cmake @@ -73,7 +73,9 @@ function(vcpkg_fixup_cmake_targets) "${DEBUG_SHARE}/*[Cc]onfigVersion.cmake" "${DEBUG_SHARE}/*[Cc]onfig-version.cmake" ) - file(REMOVE ${UNUSED_FILES}) + if(UNUSED_FILES) + file(REMOVE ${UNUSED_FILES}) + endif() file(GLOB RELEASE_TARGETS "${RELEASE_SHARE}/*[Tt]argets-release.cmake" From 0ee8ad5cb2ed21731885fa40bd0e2776eec39c71 Mon Sep 17 00:00:00 2001 From: codicodi Date: Tue, 27 Jun 2017 20:47:20 +0200 Subject: [PATCH 36/50] [fmt] update to 4.0.0 --- ports/fmt/CONTROL | 2 +- ports/fmt/portfile.cmake | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ports/fmt/CONTROL b/ports/fmt/CONTROL index e5749ab1f..c4fd79f76 100644 --- a/ports/fmt/CONTROL +++ b/ports/fmt/CONTROL @@ -1,3 +1,3 @@ Source: fmt -Version: 3.0.2 +Version: 4.0.0 Description: Formatting library for C++. It can be used as a safe alternative to printf or as a fast alternative to IOStreams. diff --git a/ports/fmt/portfile.cmake b/ports/fmt/portfile.cmake index 49728fbe0..f40e2adc9 100644 --- a/ports/fmt/portfile.cmake +++ b/ports/fmt/portfile.cmake @@ -2,8 +2,8 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO fmtlib/fmt - REF 3.0.2 - SHA512 50f5a25d1a10fd5b265f3811fa11886b9efdae2952f2aefc9f22c87c1a748128369f4d530b320e5e9c67c745cdab4607d1cb08940f4cf968300dee22e1150117 + REF 4.0.0 + SHA512 8b9f7ce4720c3caef6de4a75b8d4b0fd7db4f1638edca98d5ea95f4a5157aef8faefbac68438236691bd373111ca089b4d3864f7352f3fba1fe44392e9644f8b HEAD_REF master ) From 3d31f16c01774bd470bdee81354be82fdbdc6bb5 Mon Sep 17 00:00:00 2001 From: Mitchell Mebane Date: Wed, 28 Jun 2017 09:50:05 -0500 Subject: [PATCH 37/50] Fix OpenSSL version number --- ports/openssl/CONTROL | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/openssl/CONTROL b/ports/openssl/CONTROL index 465f941b7..bb00f9cc3 100644 --- a/ports/openssl/CONTROL +++ b/ports/openssl/CONTROL @@ -1,3 +1,3 @@ Source: openssl -Version: 1.0.21-1 +Version: 1.0.2l-1 Description: OpenSSL is an open source project that provides a robust, commercial-grade, and full-featured toolkit for the Transport Layer Security (TLS) and Secure Sockets Layer (SSL) protocols. It is also a general-purpose cryptography library. From 6c9d51451091470a6414a1e466a1f6f6d9b870ff Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Thu, 22 Jun 2017 00:26:41 -0700 Subject: [PATCH 38/50] [angle] Initial commit with cmake buildsystem --- ports/angle/CMakeLists.txt | 149 +++++++++++++++++++++++++++++++++++++ ports/angle/CONTROL | 4 + ports/angle/portfile.cmake | 22 ++++++ 3 files changed, 175 insertions(+) create mode 100644 ports/angle/CMakeLists.txt create mode 100644 ports/angle/CONTROL create mode 100644 ports/angle/portfile.cmake diff --git a/ports/angle/CMakeLists.txt b/ports/angle/CMakeLists.txt new file mode 100644 index 000000000..4f4138a05 --- /dev/null +++ b/ports/angle/CMakeLists.txt @@ -0,0 +1,149 @@ +cmake_minimum_required(VERSION 3.8) +project(angle) + +add_compile_options(/d2guard4 /Wv:18 /WX) +set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} /guard:cf") + +add_definitions(-D_CRT_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS -D_HAS_EXCEPTIONS=0 -DNOMINMAX -DANGLE_STANDALONE_BUILD -DANGLE_ENABLE_DEBUG_ANNOTATIONS) + +file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/include/id/commit.h" "#define ANGLE_COMMIT_HASH \"invalid-hash\"\n#define ANGLE_COMMIT_HASH_SIZE 12\n#define ANGLE_COMMIT_DATE \"invalid-date\"\n") + +include_directories(include src ${CMAKE_CURRENT_BINARY_DIR}/include) + +########## +# numerics +add_library(numerics INTERFACE) +file(GLOB_RECURSE NUMERICS_SOURCES "src/common/third_party/numerics/*.h") +target_sources(numerics INTERFACE ${NUMERICS_SOURCES}) +target_include_directories(numerics INTERFACE src/common/third_party/numerics) + +########## +# angle_common +file(GLOB ANGLE_COMMON_SOURCES "src/common/*.h" "src/common/*.inl" "src/common/*.cpp") +list(FILTER ANGLE_COMMON_SOURCES EXCLUDE REGEX "_unittest|event_tracer|_linux|_mac") +add_library(angle_common STATIC ${ANGLE_COMMON_SOURCES} ${NUMERICS_SOURCES}) +target_link_libraries(angle_common PUBLIC numerics) + +########## +# angle_image_util +file(GLOB ANGLE_IMAGE_UTIL_SOURCES "src/image_util/*.h" "src/image_util/*.inl" "src/image_util/*.cpp") +add_library(angle_image_util STATIC ${ANGLE_IMAGE_UTIL_SOURCES}) +target_link_libraries(angle_image_util PRIVATE angle_common) + +########## +# translator +file(GLOB TRANSLATOR_SOURCES + "src/compiler/translator/glslang.l" + "src/compiler/translator/glslang.y" + "src/compiler/translator/*.h" + "src/compiler/translator/*.cpp" + "src/third_party/compiler/ArrayBoundsClamper.cpp" +) +add_library(translator STATIC ${TRANSLATOR_SOURCES}) +target_compile_definitions(translator PUBLIC + -DANGLE_ENABLE_ESSL + -DANGLE_ENABLE_GLSL + -DANGLE_ENABLE_HLSL +) +target_link_libraries(translator PRIVATE angle_common) + +########## +# preprocessor +file(GLOB PREPROCESSOR_SOURCES + "src/compiler/preprocessor/*.h" + "src/compiler/preprocessor/*.cpp" +) +add_library(preprocessor STATIC ${PREPROCESSOR_SOURCES}) +target_link_libraries(preprocessor PRIVATE angle_common) + +########## +# libANGLE +file(GLOB LIBANGLE_SOURCES + "src/third_party/systeminfo/SystemInfo.cpp" + "src/third_party/murmurhash/MurmurHash3.cpp" + "src/common/event_tracer.cpp" + + "src/libANGLE/*.cpp" + "src/libANGLE/*.inl" + "src/libANGLE/*.h" + + "src/libANGLE/renderer/*.cpp" + "src/libANGLE/renderer/*.inl" + "src/libANGLE/renderer/*.h" + + "src/libANGLE/renderer/gl/*.cpp" + "src/libANGLE/renderer/gl/*.inl" + "src/libANGLE/renderer/gl/*.h" + + "src/libANGLE/renderer/gl/wgl/*.cpp" + "src/libANGLE/renderer/gl/wgl/*.inl" + "src/libANGLE/renderer/gl/wgl/*.h" + + "src/libANGLE/renderer/vulkan/*.cpp" + "src/libANGLE/renderer/vulkan/*.inl" + "src/libANGLE/renderer/vulkan/*.h" + + "src/libANGLE/renderer/null/*.cpp" + "src/libANGLE/renderer/null/*.inl" + "src/libANGLE/renderer/null/*.h" +) +file(GLOB_RECURSE LIBANGLE_D3D_SOURCES "src/libANGLE/renderer/d3d/*.h" "src/libANGLE/renderer/d3d/*.cpp" "src/libANGLE/renderer/d3d/*.inl") +list(FILTER LIBANGLE_SOURCES EXCLUDE REGEX "_unittest") +list(FILTER LIBANGLE_D3D_SOURCES EXCLUDE REGEX "_unittest|winrt") +add_library(libANGLE STATIC ${LIBANGLE_SOURCES} ${LIBANGLE_D3D_SOURCES}) +# kernel32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;user32.lib;uuid.lib;odbc32.lib;odbccp32.lib;delayimp.lib;d3d9.lib;dxguid.lib +find_library(D3D9_LIB NAMES d3d9) +find_library(DXGUID_LIB NAMES dxguid) +target_link_libraries(libANGLE PRIVATE angle_common angle_image_util translator ${D3D9_LIB} ${DXGUID_LIB} preprocessor) +target_include_directories(libANGLE PRIVATE "src/third_party/khronos") +target_compile_definitions(libANGLE PUBLIC + -DANGLE_ENABLE_D3D9 + -DANGLE_ENABLE_D3D11 + -DANGLE_ENABLE_OPENGL + -DANGLE_ENABLE_VULKAN + -DANGLE_ENABLE_NULL +) +target_compile_definitions(libANGLE PRIVATE -DLIBANGLE_IMPLEMENTATION) + +########## +# libGLESv2 +file(GLOB LIBGLESV2_SOURCES "src/libGLESv2/*.h" "src/libGLESv2/*.cpp" "src/libGLESv2/libGLESv2.def") +add_library(libGLESv2 ${LIBGLESV2_SOURCES}) +target_link_libraries(libGLESv2 PRIVATE angle_common libANGLE) +target_compile_definitions(libGLESv2 PRIVATE + -DLIBGLESV2_IMPLEMENTATION + -DLIBANGLE_IMPLEMENTATION + -DGL_GLEXT_PROTOTYPES + "-DANGLE_PRELOADED_D3DCOMPILER_MODULE_NAMES={ \"d3dcompiler_47.dll\", \"d3dcompiler_46.dll\", \"d3dcompiler_43.dll\" }" + -DGL_APICALL= + -DEGLAPI= +) + +########## +# libEGL +add_library(libEGL "src/libEGL/libEGL.def" "src/libEGL/libEGL.cpp" "src/libEGL/libEGL.rc" "src/libEGL/resource.h") +target_link_libraries(libEGL PRIVATE angle_common libANGLE libGLESv2) +target_compile_definitions(libEGL PRIVATE + -DLIBANGLE_IMPLEMENTATION + -DGL_GLEXT_PROTOTYPES + "-DANGLE_PRELOADED_D3DCOMPILER_MODULE_NAMES={ \"d3dcompiler_47.dll\", \"d3dcompiler_46.dll\", \"d3dcompiler_43.dll\" }" + -DGL_APICALL= + -DEGLAPI= +) + + +install(TARGETS libEGL libGLESv2 + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib +) + +if(NOT DISABLE_INSTALL_HEADERS) + install( + DIRECTORY include/ + DESTINATION include + FILES_MATCHING PATTERN "*.h" + PATTERN "GLSLANG" EXCLUDE + PATTERN "export.h" EXCLUDE + ) +endif() diff --git a/ports/angle/CONTROL b/ports/angle/CONTROL new file mode 100644 index 000000000..4f5f8880d --- /dev/null +++ b/ports/angle/CONTROL @@ -0,0 +1,4 @@ +Source: angle +Version: 2017-06-14-8d471f +Description: A conformant OpenGL ES implementation for Windows, Mac and Linux. + The goal of ANGLE is to allow users of multiple operating systems to seamlessly run WebGL and other OpenGL ES content by translating OpenGL ES API calls to one of the hardware-supported APIs available for that platform. ANGLE currently provides translation from OpenGL ES 2.0 and 3.0 to desktop OpenGL, OpenGL ES, Direct3D 9, and Direct3D 11. Support for translation from OpenGL ES to Vulkan is underway, and future plans include compute shader support (ES 3.1) and MacOS support. diff --git a/ports/angle/portfile.cmake b/ports/angle/portfile.cmake new file mode 100644 index 000000000..1499fa623 --- /dev/null +++ b/ports/angle/portfile.cmake @@ -0,0 +1,22 @@ +include(vcpkg_common_functions) + +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO google/angle + REF 8d471f907d8d4ec1d46bc9366493bd76c11c1870 + SHA512 b9235d2a98330bc8533c3fe871129e7235c680420eac16610eae4ca7224c5284313ab6377f30ddfb8a2da39b69f3ef0d16023fe1e7cec3fc2198f4eb4bdccb26 + HEAD_REF master +) + +file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH}) + +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=1 +) + +vcpkg_install_cmake() +vcpkg_copy_pdbs() + +file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/angle RENAME copyright) From 52d5091f85d182abb9b6581cfbb8b73909da1696 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Thu, 22 Jun 2017 00:33:28 -0700 Subject: [PATCH 39/50] [angle] Disable static builds --- ports/angle/CMakeLists.txt | 1 - ports/angle/portfile.cmake | 5 +++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ports/angle/CMakeLists.txt b/ports/angle/CMakeLists.txt index 4f4138a05..a4895f938 100644 --- a/ports/angle/CMakeLists.txt +++ b/ports/angle/CMakeLists.txt @@ -91,7 +91,6 @@ file(GLOB_RECURSE LIBANGLE_D3D_SOURCES "src/libANGLE/renderer/d3d/*.h" "src/libA list(FILTER LIBANGLE_SOURCES EXCLUDE REGEX "_unittest") list(FILTER LIBANGLE_D3D_SOURCES EXCLUDE REGEX "_unittest|winrt") add_library(libANGLE STATIC ${LIBANGLE_SOURCES} ${LIBANGLE_D3D_SOURCES}) -# kernel32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib;shell32.lib;ole32.lib;oleaut32.lib;user32.lib;uuid.lib;odbc32.lib;odbccp32.lib;delayimp.lib;d3d9.lib;dxguid.lib find_library(D3D9_LIB NAMES d3d9) find_library(DXGUID_LIB NAMES dxguid) target_link_libraries(libANGLE PRIVATE angle_common angle_image_util translator ${D3D9_LIB} ${DXGUID_LIB} preprocessor) diff --git a/ports/angle/portfile.cmake b/ports/angle/portfile.cmake index 1499fa623..4668b7dea 100644 --- a/ports/angle/portfile.cmake +++ b/ports/angle/portfile.cmake @@ -1,5 +1,10 @@ include(vcpkg_common_functions) +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + message(STATUS "ANGLE currently only supports being built as a dynamic library") + set(VCPKG_LIBRARY_LINKAGE dynamic) +endif() + vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO google/angle From 305d649307464ef439b241fb66f5718e8bc9af01 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Thu, 22 Jun 2017 14:52:35 -0700 Subject: [PATCH 40/50] [angle] Fix build --- ports/angle/CMakeLists.txt | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/ports/angle/CMakeLists.txt b/ports/angle/CMakeLists.txt index a4895f938..2d7af54cc 100644 --- a/ports/angle/CMakeLists.txt +++ b/ports/angle/CMakeLists.txt @@ -11,18 +11,18 @@ file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/include/id/commit.h" "#define ANGLE_COMM include_directories(include src ${CMAKE_CURRENT_BINARY_DIR}/include) ########## -# numerics -add_library(numerics INTERFACE) -file(GLOB_RECURSE NUMERICS_SOURCES "src/common/third_party/numerics/*.h") -target_sources(numerics INTERFACE ${NUMERICS_SOURCES}) -target_include_directories(numerics INTERFACE src/common/third_party/numerics) +# anglebase +add_library(anglebase INTERFACE) +file(GLOB_RECURSE anglebase_SOURCES "src/common/third_party/base/*.h") +target_sources(anglebase INTERFACE ${anglebase_SOURCES}) +target_include_directories(anglebase INTERFACE src/common/third_party/base) ########## # angle_common file(GLOB ANGLE_COMMON_SOURCES "src/common/*.h" "src/common/*.inl" "src/common/*.cpp") list(FILTER ANGLE_COMMON_SOURCES EXCLUDE REGEX "_unittest|event_tracer|_linux|_mac") -add_library(angle_common STATIC ${ANGLE_COMMON_SOURCES} ${NUMERICS_SOURCES}) -target_link_libraries(angle_common PUBLIC numerics) +add_library(angle_common STATIC ${ANGLE_COMMON_SOURCES}) +target_link_libraries(angle_common PUBLIC anglebase) ########## # angle_image_util @@ -60,7 +60,7 @@ target_link_libraries(preprocessor PRIVATE angle_common) # libANGLE file(GLOB LIBANGLE_SOURCES "src/third_party/systeminfo/SystemInfo.cpp" - "src/third_party/murmurhash/MurmurHash3.cpp" + "src/common/third_party/murmurhash/MurmurHash3.cpp" "src/common/event_tracer.cpp" "src/libANGLE/*.cpp" @@ -79,9 +79,9 @@ file(GLOB LIBANGLE_SOURCES "src/libANGLE/renderer/gl/wgl/*.inl" "src/libANGLE/renderer/gl/wgl/*.h" - "src/libANGLE/renderer/vulkan/*.cpp" - "src/libANGLE/renderer/vulkan/*.inl" - "src/libANGLE/renderer/vulkan/*.h" + # "src/libANGLE/renderer/vulkan/*.cpp" + # "src/libANGLE/renderer/vulkan/*.inl" + # "src/libANGLE/renderer/vulkan/*.h" "src/libANGLE/renderer/null/*.cpp" "src/libANGLE/renderer/null/*.inl" @@ -99,7 +99,7 @@ target_compile_definitions(libANGLE PUBLIC -DANGLE_ENABLE_D3D9 -DANGLE_ENABLE_D3D11 -DANGLE_ENABLE_OPENGL - -DANGLE_ENABLE_VULKAN + # -DANGLE_ENABLE_VULKAN -DANGLE_ENABLE_NULL ) target_compile_definitions(libANGLE PRIVATE -DLIBANGLE_IMPLEMENTATION) From 4509e764cc691a0ae097ef512bda2095cf477152 Mon Sep 17 00:00:00 2001 From: bagong Date: Tue, 20 Jun 2017 00:31:34 +0200 Subject: [PATCH 41/50] [AUBIO] Add new package --- ports/aubio/CONTROL | 4 + ports/aubio/aubio-5.def | 442 ++++++++++++++++++++++++++++++ ports/aubio/crt_lib_linkage.patch | 68 +++++ ports/aubio/portfile.cmake | 106 +++++++ 4 files changed, 620 insertions(+) create mode 100644 ports/aubio/CONTROL create mode 100644 ports/aubio/aubio-5.def create mode 100644 ports/aubio/crt_lib_linkage.patch create mode 100644 ports/aubio/portfile.cmake diff --git a/ports/aubio/CONTROL b/ports/aubio/CONTROL new file mode 100644 index 000000000..f7aee6191 --- /dev/null +++ b/ports/aubio/CONTROL @@ -0,0 +1,4 @@ +Source: aubio +Version: 0.46~alpha +Description: Aubio is a tool designed for the extraction of annotations from audio signals. Its features include segmenting a sound file before each of its attacks, performing pitch detection, tapping the beat and producing midi streams from live audio. +Build-Depends: ffmpeg, libsndfile diff --git a/ports/aubio/aubio-5.def b/ports/aubio/aubio-5.def new file mode 100644 index 000000000..8b3fb9b7d --- /dev/null +++ b/ports/aubio/aubio-5.def @@ -0,0 +1,442 @@ +EXPORTS +aubio_autocorr +aubio_beattracking_checkstate +aubio_beattracking_do +aubio_beattracking_get_bpm +aubio_beattracking_get_confidence +aubio_beattracking_get_period +aubio_beattracking_get_period_s +aubio_bintofreq +aubio_bintomidi +aubio_cleanup +aubio_db_spl +aubio_default_log +aubio_fft_do +aubio_fft_do_complex +aubio_fft_get_imag +aubio_fft_get_norm +aubio_fft_get_phas +aubio_fft_get_real +aubio_fft_get_realimag +aubio_fft_get_spectrum +aubio_fft_rdo +aubio_fft_rdo_complex +aubio_filter_do +aubio_filter_do_filtfilt +aubio_filter_do_outplace +aubio_filter_do_reset +aubio_filter_get_feedback +aubio_filter_get_feedforward +aubio_filter_get_order +aubio_filter_get_samplerate +aubio_filter_set_a_weighting +aubio_filter_set_biquad +aubio_filter_set_c_weighting +aubio_filter_set_samplerate +aubio_filterbank_do +aubio_filterbank_get_coeffs +aubio_filterbank_set_coeffs +aubio_filterbank_set_mel_coeffs_slaney +aubio_filterbank_set_triangle_bands +aubio_freqtobin +aubio_freqtomidi +aubio_hist_do +aubio_hist_do_notnull +aubio_hist_dyn_notnull +aubio_hist_mean +aubio_hist_weight +aubio_io_validate_channels +aubio_io_validate_samplerate +aubio_is_power_of_two +aubio_level_detection +aubio_level_lin +aubio_log +aubio_log_reset +aubio_log_set_function +aubio_log_set_level_function +aubio_mfcc_do +aubio_miditobin +aubio_miditofreq +aubio_next_power_of_two +aubio_notes_do +aubio_notes_get_minioi_ms +aubio_notes_get_silence +aubio_notes_set_minioi_ms +aubio_notes_set_silence +aubio_onset_do +aubio_onset_get_awhitening +aubio_onset_get_compression +aubio_onset_get_delay +aubio_onset_get_delay_ms +aubio_onset_get_delay_s +aubio_onset_get_descriptor +aubio_onset_get_last +aubio_onset_get_last_ms +aubio_onset_get_last_s +aubio_onset_get_minioi +aubio_onset_get_minioi_ms +aubio_onset_get_minioi_s +aubio_onset_get_silence +aubio_onset_get_threshold +aubio_onset_get_thresholded_descriptor +aubio_onset_reset +aubio_onset_set_awhitening +aubio_onset_set_compression +aubio_onset_set_default_parameters +aubio_onset_set_delay +aubio_onset_set_delay_ms +aubio_onset_set_delay_s +aubio_onset_set_minioi +aubio_onset_set_minioi_ms +aubio_onset_set_minioi_s +aubio_onset_set_silence +aubio_onset_set_threshold +aubio_ooura_cdft +aubio_ooura_ddct +aubio_ooura_ddst +aubio_ooura_dfct +aubio_ooura_dfst +aubio_ooura_rdft +aubio_parameter_get_current_value +aubio_parameter_get_max_value +aubio_parameter_get_min_value +aubio_parameter_get_next_value +aubio_parameter_get_steps +aubio_parameter_set_current_value +aubio_parameter_set_max_value +aubio_parameter_set_min_value +aubio_parameter_set_steps +aubio_parameter_set_target_value +aubio_peakpicker_do +aubio_peakpicker_get_threshold +aubio_peakpicker_get_thresholded_input +aubio_peakpicker_get_thresholdfn +aubio_peakpicker_set_threshold +aubio_peakpicker_set_thresholdfn +aubio_pitch_cands +aubio_pitch_do +aubio_pitch_get_confidence +aubio_pitch_get_silence +aubio_pitch_get_tolerance +aubio_pitch_set_silence +aubio_pitch_set_tolerance +aubio_pitch_set_unit +aubio_pitch_slideblock +aubio_pitchfcomb_do +aubio_pitchmcomb_combdet +aubio_pitchmcomb_do +aubio_pitchmcomb_get_root_peak +aubio_pitchmcomb_quadpick +aubio_pitchmcomb_sort_cand_ene +aubio_pitchmcomb_sort_cand_freq +aubio_pitchmcomb_sort_peak +aubio_pitchmcomb_spectral_pp +aubio_pitchschmitt_do +aubio_pitchspecacf_do +aubio_pitchspecacf_get_confidence +aubio_pitchspecacf_get_tolerance +aubio_pitchspecacf_set_tolerance +aubio_pitchyin_diff +aubio_pitchyin_do +aubio_pitchyin_get_confidence +aubio_pitchyin_get_tolerance +aubio_pitchyin_getcum +aubio_pitchyin_getpitch +aubio_pitchyin_set_tolerance +aubio_pitchyinfft_do +aubio_pitchyinfft_get_confidence +aubio_pitchyinfft_get_tolerance +aubio_pitchyinfft_set_tolerance +aubio_pvoc_do +aubio_pvoc_rdo +aubio_quadfrac +aubio_resampler_do +aubio_sampler_do +aubio_sampler_do_multi +aubio_sampler_get_playing +aubio_sampler_load +aubio_sampler_play +aubio_sampler_set_playing +aubio_sampler_stop +aubio_scale_do +aubio_scale_set_limits +aubio_schmittS16LE +aubio_silence_detection +aubio_sink_close +aubio_sink_do +aubio_sink_do_multi +aubio_sink_get_channels +aubio_sink_get_samplerate +aubio_sink_preset_channels +aubio_sink_preset_samplerate +aubio_sink_sndfile_close +aubio_sink_sndfile_do +aubio_sink_sndfile_do_multi +aubio_sink_sndfile_get_channels +aubio_sink_sndfile_get_samplerate +aubio_sink_sndfile_open +aubio_sink_sndfile_preset_channels +aubio_sink_sndfile_preset_samplerate +aubio_sink_wavwrite_close +aubio_sink_wavwrite_do +aubio_sink_wavwrite_do_multi +aubio_sink_wavwrite_get_channels +aubio_sink_wavwrite_get_samplerate +aubio_sink_wavwrite_open +aubio_sink_wavwrite_preset_channels +aubio_sink_wavwrite_preset_samplerate +aubio_source_avcodec_close +aubio_source_avcodec_do +aubio_source_avcodec_do_multi +aubio_source_avcodec_get_channels +aubio_source_avcodec_get_duration +aubio_source_avcodec_get_samplerate +aubio_source_avcodec_has_network_url +aubio_source_avcodec_readframe +aubio_source_avcodec_reset_resampler +aubio_source_avcodec_seek +aubio_source_close +aubio_source_do +aubio_source_do_multi +aubio_source_get_channels +aubio_source_get_duration +aubio_source_get_samplerate +aubio_source_seek +aubio_source_sndfile_close +aubio_source_sndfile_do +aubio_source_sndfile_do_multi +aubio_source_sndfile_get_channels +aubio_source_sndfile_get_duration +aubio_source_sndfile_get_samplerate +aubio_source_sndfile_seek +aubio_source_wavread_close +aubio_source_wavread_do +aubio_source_wavread_do_multi +aubio_source_wavread_get_channels +aubio_source_wavread_get_duration +aubio_source_wavread_get_samplerate +aubio_source_wavread_readframe +aubio_source_wavread_seek +aubio_specdesc_centroid +aubio_specdesc_complex +aubio_specdesc_decrease +aubio_specdesc_do +aubio_specdesc_energy +aubio_specdesc_hfc +aubio_specdesc_kl +aubio_specdesc_kurtosis +aubio_specdesc_mkl +aubio_specdesc_phase +aubio_specdesc_rolloff +aubio_specdesc_skewness +aubio_specdesc_slope +aubio_specdesc_specdiff +aubio_specdesc_specflux +aubio_specdesc_spread +aubio_specdesc_wphase +aubio_spectral_whitening_do +aubio_spectral_whitening_get_floor +aubio_spectral_whitening_get_relax_time +aubio_spectral_whitening_reset +aubio_spectral_whitening_set_floor +aubio_spectral_whitening_set_relax_time +aubio_tempo_do +aubio_tempo_get_bpm +aubio_tempo_get_confidence +aubio_tempo_get_delay +aubio_tempo_get_delay_ms +aubio_tempo_get_delay_s +aubio_tempo_get_last +aubio_tempo_get_last_ms +aubio_tempo_get_last_s +aubio_tempo_get_last_tatum +aubio_tempo_get_period +aubio_tempo_get_period_s +aubio_tempo_get_silence +aubio_tempo_get_threshold +aubio_tempo_set_delay +aubio_tempo_set_delay_ms +aubio_tempo_set_delay_s +aubio_tempo_set_silence +aubio_tempo_set_tatum_signature +aubio_tempo_set_threshold +aubio_tempo_was_tatum +aubio_tss_do +aubio_tss_set_alpha +aubio_tss_set_beta +aubio_tss_set_threshold +aubio_unwrap2pi +aubio_wavetable_do +aubio_wavetable_do_multi +aubio_wavetable_get_amp +aubio_wavetable_get_freq +aubio_wavetable_get_playing +aubio_wavetable_play +aubio_wavetable_set_amp +aubio_wavetable_set_freq +aubio_wavetable_set_playing +aubio_wavetable_stop +aubio_zero_crossing_rate +cvec_centroid +cvec_copy +cvec_logmag +cvec_mean +cvec_moment +cvec_norm_get_data +cvec_norm_get_sample +cvec_norm_ones +cvec_norm_set_all +cvec_norm_set_sample +cvec_norm_zeros +cvec_phas_get_data +cvec_phas_get_sample +cvec_phas_ones +cvec_phas_set_all +cvec_phas_set_sample +cvec_phas_zeros +cvec_print +cvec_sum +cvec_zeros +del_aubio_beattracking +del_aubio_fft +del_aubio_filter +del_aubio_filterbank +del_aubio_hist +del_aubio_mfcc +del_aubio_notes +del_aubio_onset +del_aubio_parameter +del_aubio_peakpicker +del_aubio_pitch +del_aubio_pitchfcomb +del_aubio_pitchmcomb +del_aubio_pitchschmitt +del_aubio_pitchspecacf +del_aubio_pitchyin +del_aubio_pitchyinfft +del_aubio_pvoc +del_aubio_resampler +del_aubio_sampler +del_aubio_scale +del_aubio_sink +del_aubio_sink_sndfile +del_aubio_sink_wavwrite +del_aubio_source +del_aubio_source_avcodec +del_aubio_source_sndfile +del_aubio_source_wavread +del_aubio_specdesc +del_aubio_spectral_whitening +del_aubio_tempo +del_aubio_tss +del_aubio_wavetable +del_cvec +del_fmat +del_fvec +del_lvec +fmat_copy +fmat_get_channel +fmat_get_channel_data +fmat_get_data +fmat_get_sample +fmat_ones +fmat_print +fmat_rev +fmat_set +fmat_set_sample +fmat_vecmul +fmat_weight +fmat_zeros +fvec_abs +fvec_adapt_thres +fvec_add +fvec_alpha_norm +fvec_alpha_normalise +fvec_ceil +fvec_clamp +fvec_copy +fvec_cos +fvec_exp +fvec_floor +fvec_get_data +fvec_get_sample +fvec_gettimesig +fvec_ishift +fvec_local_hfc +fvec_log +fvec_log10 +fvec_max +fvec_max_elem +fvec_mean +fvec_median +fvec_min +fvec_min_elem +fvec_min_removal +fvec_moving_thres +fvec_ones +fvec_peakpick +fvec_pow +fvec_print +fvec_push +fvec_quadratic_peak_mag +fvec_quadratic_peak_pos +fvec_rev +fvec_round +fvec_set_all +fvec_set_sample +fvec_set_window +fvec_shift +fvec_sin +fvec_sqrt +fvec_sum +fvec_weight +fvec_weighted_copy +fvec_zeros +lvec_get_data +lvec_get_sample +lvec_ones +lvec_print +lvec_set_all +lvec_set_sample +lvec_zeros +new_aubio_beattracking +new_aubio_fft +new_aubio_filter +new_aubio_filter_a_weighting +new_aubio_filter_biquad +new_aubio_filter_c_weighting +new_aubio_filterbank +new_aubio_hist +new_aubio_mfcc +new_aubio_notes +new_aubio_onset +new_aubio_parameter +new_aubio_peakpicker +new_aubio_pitch +new_aubio_pitchfcomb +new_aubio_pitchmcomb +new_aubio_pitchschmitt +new_aubio_pitchspecacf +new_aubio_pitchyin +new_aubio_pitchyinfft +new_aubio_pvoc +new_aubio_resampler +new_aubio_sampler +new_aubio_scale +new_aubio_sink +new_aubio_sink_sndfile +new_aubio_sink_wavwrite +new_aubio_source +new_aubio_source_avcodec +new_aubio_source_sndfile +new_aubio_source_wavread +new_aubio_specdesc +new_aubio_spectral_whitening +new_aubio_tempo +new_aubio_tss +new_aubio_wavetable +new_aubio_window +new_cvec +new_fmat +new_fvec +new_lvec diff --git a/ports/aubio/crt_lib_linkage.patch b/ports/aubio/crt_lib_linkage.patch new file mode 100644 index 000000000..36a8a3640 --- /dev/null +++ b/ports/aubio/crt_lib_linkage.patch @@ -0,0 +1,68 @@ +diff --git a/src/wscript_build b/src/wscript_build +index 0a7d72a..bf84227 100644 +--- a/src/wscript_build ++++ b/src/wscript_build +@@ -24,7 +24,12 @@ ctx(features = 'c', + if ctx.env['DEST_OS'] in ['ios', 'iosimulator']: + build_features = ['cstlib', 'cshlib'] + elif ctx.env['DEST_OS'] in ['win32', 'win64']: +- build_features = ['cstlib', 'cshlib'] ++ if ctx.options.library_linkage == "static": ++ build_features = ['cstlib'] ++ elif ctx.options.library_linkage == "dynamic": ++ build_features = ['cshlib'] ++ else: ++ build_features = ['cstlib', 'cshlib'] + elif ctx.env['DEST_OS'] in ['emscripten']: + build_features = ['cstlib'] + elif '--static' in ctx.env['LDFLAGS'] or '--static' in ctx.env['LINKFLAGS']: +diff --git a/wscript b/wscript +index 6363f1e..e0d57a4 100644 +--- a/wscript ++++ b/wscript +@@ -44,6 +44,16 @@ def options(ctx): + dest = 'build_type', + help = 'whether to compile with (--build-type=release) or without (--build-type=debug) '\ + ' compiler opimizations [default: release]') ++ ctx.add_option('--crt-linkage', action = 'store', ++ default = "dynamic", ++ choices = ('static', 'dynamic'), ++ dest = 'crt_linkage', ++ help = 'whether to compile with static CRT linkage (--crt-linkage=static) or the default dynamic (--crt-linkage=dynamic)') ++ ctx.add_option('--library-linkage', action = 'store', ++ default = "both", ++ choices = ('dynamic', 'static', 'both'), ++ dest = 'library_linkage', ++ help = 'whether to compile a dynamic (shared) (--library-linkage=dynamic) or static library (--library-linkage=static) ("both" is broken for msvc)') + add_option_enable_disable(ctx, 'fftw3f', default = False, + help_str = 'compile with fftw3f instead of ooura (recommended)', + help_disable_str = 'do not compile with fftw3f') +@@ -139,16 +149,25 @@ def configure(ctx): + else: + # enable debug symbols + ctx.env.CFLAGS += ['/Z7', '/FS'] +- ctx.env.LINKFLAGS += ['/DEBUG', '/INCREMENTAL:NO'] ++ if ctx.options.library_linkage == "dynamic": ++ ctx.env.LINKFLAGS += ['/DEBUG', '/INCREMENTAL:NO', '/DEF:..\\aubio-5.def'] ++ else: ++ ctx.env.LINKFLAGS += ['/DEBUG', '/INCREMENTAL:NO'] + # configure warnings + ctx.env.CFLAGS += ['/W4', '/D_CRT_SECURE_NO_WARNINGS'] + # set optimization level and runtime libs + if (ctx.options.build_type == "release"): + ctx.env.CFLAGS += ['/Ox'] +- ctx.env.CFLAGS += ['/MD'] ++ if (ctx.options.crt_linkage == "static"): ++ ctx.env.CFLAGS += ['/MT'] ++ else: ++ ctx.env.CFLAGS += ['/MD'] + else: + assert(ctx.options.build_type == "debug") +- ctx.env.CFLAGS += ['/MDd'] ++ if (ctx.options.crt_linkage == "static"): ++ ctx.env.CFLAGS += ['/MTd'] ++ else: ++ ctx.env.CFLAGS += ['/MDd'] + + ctx.check_cc(lib='m', uselib_store='M', mandatory=False) + diff --git a/ports/aubio/portfile.cmake b/ports/aubio/portfile.cmake new file mode 100644 index 000000000..714ec3ae8 --- /dev/null +++ b/ports/aubio/portfile.cmake @@ -0,0 +1,106 @@ +# NOTES +# - if you get a codepage/unicode related error (non-critical) during configuration, +# ignore it or, try switching the console codepage to windows english (`chcp 1252`) +# - the build breaks with "missing pthreads" if --enable-fftw3(f) is added (if fftw3 +# is not added, the embedded ooura fft lib is used) +# - the port uses ffmpeg and libsndfile as dependencies and also depends on possibilty to acquire waf and pkg-config(-lite) in vcpkg. +# - crt-linkage is handled here, not in the generic waf-configure function because it is controlled via a patch to the aubio wscript +# Waf seems to have no generic way to switch crt-linkage. +# - The static build works, but: vcpkg's static ffmpegs build is fake ;), therefore it is still required to make the ffmpeg dlls +# available in order to run exectables with statically linked aubio. + +include(vcpkg_common_functions) +set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/aubio-3c230fae309e9ea3298783368dd71bae6172359a) +vcpkg_download_distfile(ARCHIVE + URLS "https://github.com/aubio/aubio/archive/3c230fae309e9ea3298783368dd71bae6172359a.zip" + FILENAME "aubio-0.4.6-3c230f.zip" + SHA512 081fe59612f0b1860f465208739b1377869c64b91cecf4a6f6fbdea19204b801c650ff956b34be5988ef1905f3546d3c55846037487e0b34b014f1adbb68629c +) +vcpkg_extract_source_archive(${ARCHIVE}) + +# Pkg-config is equired by aubio to detect ffmpeg and libsndfile +vcpkg_find_acquire_program(PKG-CONFIG) + +# Waf depends on python, so this also installs python3 +vcpkg_acquire_waf() + +# Configure pkg-config dir +get_filename_component(PKG_CONFIG_DIR ${PKG-CONFIG} DIRECTORY) +# Add pkg-config and vcpkg-bin-dir to environment search path +set(ENV{PATH} "${CURRENT_INSTALLED_DIR}/bin;${CURRENT_INSTALLED_DIR}/debug/bin;${PKG_CONFIG_DIR};$ENV{PATH}") +# Set pkg-config search-path +set(ENV{PKG_CONFIG_PATH} "${CURRENT_INSTALLED_DIR}/lib/pkgconfig") + +# Add waf executable if missing +if(NOT EXISTS "${SOURCE_PATH}/waf") + file(COPY "${WAF_DIR}/waf" DESTINATION "${SOURCE_PATH}") +endif() + +# Add arguments for crt linkage and library linkage +vcpkg_apply_patches( + SOURCE_PATH ${SOURCE_PATH} + PATCHES "${CMAKE_CURRENT_LIST_DIR}/crt_lib_linkage.patch" +) + +file(COPY ${CMAKE_CURRENT_LIST_DIR}/aubio-5.def DESTINATION ${SOURCE_PATH}) + +vcpkg_configure_waf( + SOURCE_PATH ${SOURCE_PATH} + OPTIONS + --library-linkage=${VCPKG_LIBRARY_LINKAGE} + --crt-linkage=${VCPKG_CRT_LINKAGE} + --enable-sndfile + --enable-avcodec + --disable-docs + --verbose + # OPTIONS_DEBUG + # OPTIONS_RELEASE + OPTIONS_BUILD + --library-linkage=${VCPKG_LIBRARY_LINKAGE} + --verbose + --notests + # OPTIONS_BUILD_RELEASE + # OPTIONS_BUILD_DEBUG + # TARGETS +) + +# Postinstall cleanup debug +message(STATUS "Cleaning up build") +# Remove unused files +# Debug executable and include folder +file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") +file(GLOB DEBUG_EXECS ${CURRENT_PACKAGES_DIR}/debug/bin/*) +file(REMOVE ${DEBUG_EXECS}) +# In release branch move execs to tools +file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/tools/aubio) +file(GLOB RELEASE_EXECS ${CURRENT_PACKAGES_DIR}/bin/*.exe) +file(GLOB RELEASE_EXE_SYMBOLS ${CURRENT_PACKAGES_DIR}/bin/*.pdb) +FILE(COPY ${RELEASE_EXECS} DESTINATION ${CURRENT_PACKAGES_DIR}/tools/aubio) +FILE(REMOVE ${RELEASE_EXECS} ${RELEASE_EXE_SYMBOLS}) + +# Prepare (re-)moving dynamic libs +file(GLOB DEBUG_DLLS ${CURRENT_PACKAGES_DIR}/debug/lib/*.dll ${CURRENT_PACKAGES_DIR}/debug/lib/*.pdb) +file(GLOB RELEASE_DLLS ${CURRENT_PACKAGES_DIR}/lib/*.dll ${CURRENT_PACKAGES_DIR}/lib/*.pdb) + +if(${VCPKG_LIBRARY_LINKAGE} MATCHES "dynamic") + # Move dlls + file(COPY ${DEBUG_DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin) + file(COPY ${RELEASE_DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/bin) + file(REMOVE ${DEBUG_DLLS} ${RELEASE_DLLS}) +elseif(${VCPKG_LIBRARY_LINKAGE} MATCHES "static") + file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin) +endif() + +# Handle copyright and credentials +file(COPY + ${SOURCE_PATH}/COPYING + ${SOURCE_PATH}/AUTHORS + ${SOURCE_PATH}/ChangeLog + ${SOURCE_PATH}/README.md + DESTINATION + ${CURRENT_PACKAGES_DIR}/share/aubio) + +file(RENAME ${CURRENT_PACKAGES_DIR}/share/aubio/COPYING ${CURRENT_PACKAGES_DIR}/share/aubio/copyright) + +# TODO +# Add python script for dynamic symbols export in dynamic linking From a2cee615e4c444d5ce84fac618bfb2b18cd6985f Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Tue, 20 Jun 2017 02:52:02 -0700 Subject: [PATCH 42/50] [aubio] CMake buildsystem replacement --- ports/aubio/CMakeLists.txt | 54 ++++++++++++++++++++++ ports/aubio/portfile.cmake | 91 +++----------------------------------- 2 files changed, 61 insertions(+), 84 deletions(-) create mode 100644 ports/aubio/CMakeLists.txt diff --git a/ports/aubio/CMakeLists.txt b/ports/aubio/CMakeLists.txt new file mode 100644 index 000000000..df2c598f9 --- /dev/null +++ b/ports/aubio/CMakeLists.txt @@ -0,0 +1,54 @@ +cmake_minimum_required(VERSION 3.8) +project(aubio C) + +add_definitions( + -DHAVE_STDLIB_H=1 + -DHAVE_STDIO_H=1 + -DHAVE_MATH_H=1 + -DHAVE_STRING_H=1 + -DHAVE_LIMITS_H=1 + -DHAVE_STDARG_H=1 + -DHAVE_C99_VARARGS_MACROS=1 + + -DHAVE_SNDFILE=1 + -DHAVE_WAVWRITE=1 + -DHAVE_WAVREAD=1 + -DHAVE_LIBAV=1 + -DHAVE_SWRESAMPLE=1 +) + +find_path(LIBSNDFILE_H sndfile.h) +find_library(LIBSNDFILE_LIB libsndfile-1) +find_library(AVCODEC_LIB avcodec) +find_library(AVUTIL_LIB avutil) +find_library(AVDEVICE_LIB avdevice) +find_library(AVFILTER_LIB avfilter) +find_library(AVFORMAT_LIB avformat) +find_library(SWRESAMPLE_LIB swresample) + +include_directories(src ${LIBSNDFILE_H}) +link_libraries(${LIBSNDFILE_LIB} ${AVCODEC_LIB} ${AVUTIL_LIB} ${AVDEVICE_LIB} ${AVFILTER_LIB} ${AVFORMAT_LIB} ${SWRESAMPLE_LIB} ws2_32.lib) + +file(GLOB_RECURSE SOURCES src/*.c aubio-5.def) +set_source_files_properties(src/io/sink_wavwrite.c PROPERTIES COMPILE_FLAGS /FIWinsock2.h) +add_library(aubio ${SOURCES}) + +set(CMAKE_DEBUG_POSTFIX d) + +install( + TARGETS aubio + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib +) + +if(NOT DISABLE_INSTALL_HEADERS) + install( + DIRECTORY src/ + DESTINATION include/aubio + FILES_MATCHING + PATTERN "*.h" + PATTERN "*_priv.h" EXCLUDE + PATTERN "config.h" EXCLUDE + ) +endif() diff --git a/ports/aubio/portfile.cmake b/ports/aubio/portfile.cmake index 714ec3ae8..e8a7d4551 100644 --- a/ports/aubio/portfile.cmake +++ b/ports/aubio/portfile.cmake @@ -1,14 +1,3 @@ -# NOTES -# - if you get a codepage/unicode related error (non-critical) during configuration, -# ignore it or, try switching the console codepage to windows english (`chcp 1252`) -# - the build breaks with "missing pthreads" if --enable-fftw3(f) is added (if fftw3 -# is not added, the embedded ooura fft lib is used) -# - the port uses ffmpeg and libsndfile as dependencies and also depends on possibilty to acquire waf and pkg-config(-lite) in vcpkg. -# - crt-linkage is handled here, not in the generic waf-configure function because it is controlled via a patch to the aubio wscript -# Waf seems to have no generic way to switch crt-linkage. -# - The static build works, but: vcpkg's static ffmpegs build is fake ;), therefore it is still required to make the ffmpeg dlls -# available in order to run exectables with statically linked aubio. - include(vcpkg_common_functions) set(SOURCE_PATH ${CURRENT_BUILDTREES_DIR}/src/aubio-3c230fae309e9ea3298783368dd71bae6172359a) vcpkg_download_distfile(ARCHIVE @@ -18,78 +7,14 @@ vcpkg_download_distfile(ARCHIVE ) vcpkg_extract_source_archive(${ARCHIVE}) -# Pkg-config is equired by aubio to detect ffmpeg and libsndfile -vcpkg_find_acquire_program(PKG-CONFIG) +file(COPY ${CMAKE_CURRENT_LIST_DIR}/aubio-5.def ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH}) -# Waf depends on python, so this also installs python3 -vcpkg_acquire_waf() - -# Configure pkg-config dir -get_filename_component(PKG_CONFIG_DIR ${PKG-CONFIG} DIRECTORY) -# Add pkg-config and vcpkg-bin-dir to environment search path -set(ENV{PATH} "${CURRENT_INSTALLED_DIR}/bin;${CURRENT_INSTALLED_DIR}/debug/bin;${PKG_CONFIG_DIR};$ENV{PATH}") -# Set pkg-config search-path -set(ENV{PKG_CONFIG_PATH} "${CURRENT_INSTALLED_DIR}/lib/pkgconfig") - -# Add waf executable if missing -if(NOT EXISTS "${SOURCE_PATH}/waf") - file(COPY "${WAF_DIR}/waf" DESTINATION "${SOURCE_PATH}") -endif() - -# Add arguments for crt linkage and library linkage -vcpkg_apply_patches( - SOURCE_PATH ${SOURCE_PATH} - PATCHES "${CMAKE_CURRENT_LIST_DIR}/crt_lib_linkage.patch" +vcpkg_configure_cmake( + SOURCE_PATH ${SOURCE_PATH} + PREFER_NINJA + OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=1 ) - -file(COPY ${CMAKE_CURRENT_LIST_DIR}/aubio-5.def DESTINATION ${SOURCE_PATH}) - -vcpkg_configure_waf( - SOURCE_PATH ${SOURCE_PATH} - OPTIONS - --library-linkage=${VCPKG_LIBRARY_LINKAGE} - --crt-linkage=${VCPKG_CRT_LINKAGE} - --enable-sndfile - --enable-avcodec - --disable-docs - --verbose - # OPTIONS_DEBUG - # OPTIONS_RELEASE - OPTIONS_BUILD - --library-linkage=${VCPKG_LIBRARY_LINKAGE} - --verbose - --notests - # OPTIONS_BUILD_RELEASE - # OPTIONS_BUILD_DEBUG - # TARGETS -) - -# Postinstall cleanup debug -message(STATUS "Cleaning up build") -# Remove unused files -# Debug executable and include folder -file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include") -file(GLOB DEBUG_EXECS ${CURRENT_PACKAGES_DIR}/debug/bin/*) -file(REMOVE ${DEBUG_EXECS}) -# In release branch move execs to tools -file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/tools/aubio) -file(GLOB RELEASE_EXECS ${CURRENT_PACKAGES_DIR}/bin/*.exe) -file(GLOB RELEASE_EXE_SYMBOLS ${CURRENT_PACKAGES_DIR}/bin/*.pdb) -FILE(COPY ${RELEASE_EXECS} DESTINATION ${CURRENT_PACKAGES_DIR}/tools/aubio) -FILE(REMOVE ${RELEASE_EXECS} ${RELEASE_EXE_SYMBOLS}) - -# Prepare (re-)moving dynamic libs -file(GLOB DEBUG_DLLS ${CURRENT_PACKAGES_DIR}/debug/lib/*.dll ${CURRENT_PACKAGES_DIR}/debug/lib/*.pdb) -file(GLOB RELEASE_DLLS ${CURRENT_PACKAGES_DIR}/lib/*.dll ${CURRENT_PACKAGES_DIR}/lib/*.pdb) - -if(${VCPKG_LIBRARY_LINKAGE} MATCHES "dynamic") - # Move dlls - file(COPY ${DEBUG_DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin) - file(COPY ${RELEASE_DLLS} DESTINATION ${CURRENT_PACKAGES_DIR}/bin) - file(REMOVE ${DEBUG_DLLS} ${RELEASE_DLLS}) -elseif(${VCPKG_LIBRARY_LINKAGE} MATCHES "static") - file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin) -endif() +vcpkg_install_cmake() # Handle copyright and credentials file(COPY @@ -100,7 +25,5 @@ file(COPY DESTINATION ${CURRENT_PACKAGES_DIR}/share/aubio) +vcpkg_copy_pdbs() file(RENAME ${CURRENT_PACKAGES_DIR}/share/aubio/COPYING ${CURRENT_PACKAGES_DIR}/share/aubio/copyright) - -# TODO -# Add python script for dynamic symbols export in dynamic linking From ced194257dd35c5ccd38f3ed19a3cafdaadb5393 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Tue, 20 Jun 2017 03:06:29 -0700 Subject: [PATCH 43/50] [aubio] Fix static build --- ports/aubio/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/aubio/CMakeLists.txt b/ports/aubio/CMakeLists.txt index df2c598f9..d1124b46c 100644 --- a/ports/aubio/CMakeLists.txt +++ b/ports/aubio/CMakeLists.txt @@ -18,7 +18,7 @@ add_definitions( ) find_path(LIBSNDFILE_H sndfile.h) -find_library(LIBSNDFILE_LIB libsndfile-1) +find_library(LIBSNDFILE_LIB NAMES libsndfile-1 libsndfile) find_library(AVCODEC_LIB avcodec) find_library(AVUTIL_LIB avutil) find_library(AVDEVICE_LIB avdevice) From b7efd0e07d1a397e701f038569204d6a2879ed67 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Tue, 20 Jun 2017 03:16:23 -0700 Subject: [PATCH 44/50] [aubio] Use CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS --- ports/aubio/CMakeLists.txt | 4 +- ports/aubio/aubio-5.def | 442 ------------------------------ ports/aubio/crt_lib_linkage.patch | 68 ----- ports/aubio/portfile.cmake | 14 +- 4 files changed, 10 insertions(+), 518 deletions(-) delete mode 100644 ports/aubio/aubio-5.def delete mode 100644 ports/aubio/crt_lib_linkage.patch diff --git a/ports/aubio/CMakeLists.txt b/ports/aubio/CMakeLists.txt index d1124b46c..6577e075c 100644 --- a/ports/aubio/CMakeLists.txt +++ b/ports/aubio/CMakeLists.txt @@ -17,6 +17,8 @@ add_definitions( -DHAVE_SWRESAMPLE=1 ) +set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) + find_path(LIBSNDFILE_H sndfile.h) find_library(LIBSNDFILE_LIB NAMES libsndfile-1 libsndfile) find_library(AVCODEC_LIB avcodec) @@ -29,7 +31,7 @@ find_library(SWRESAMPLE_LIB swresample) include_directories(src ${LIBSNDFILE_H}) link_libraries(${LIBSNDFILE_LIB} ${AVCODEC_LIB} ${AVUTIL_LIB} ${AVDEVICE_LIB} ${AVFILTER_LIB} ${AVFORMAT_LIB} ${SWRESAMPLE_LIB} ws2_32.lib) -file(GLOB_RECURSE SOURCES src/*.c aubio-5.def) +file(GLOB_RECURSE SOURCES src/*.c) set_source_files_properties(src/io/sink_wavwrite.c PROPERTIES COMPILE_FLAGS /FIWinsock2.h) add_library(aubio ${SOURCES}) diff --git a/ports/aubio/aubio-5.def b/ports/aubio/aubio-5.def deleted file mode 100644 index 8b3fb9b7d..000000000 --- a/ports/aubio/aubio-5.def +++ /dev/null @@ -1,442 +0,0 @@ -EXPORTS -aubio_autocorr -aubio_beattracking_checkstate -aubio_beattracking_do -aubio_beattracking_get_bpm -aubio_beattracking_get_confidence -aubio_beattracking_get_period -aubio_beattracking_get_period_s -aubio_bintofreq -aubio_bintomidi -aubio_cleanup -aubio_db_spl -aubio_default_log -aubio_fft_do -aubio_fft_do_complex -aubio_fft_get_imag -aubio_fft_get_norm -aubio_fft_get_phas -aubio_fft_get_real -aubio_fft_get_realimag -aubio_fft_get_spectrum -aubio_fft_rdo -aubio_fft_rdo_complex -aubio_filter_do -aubio_filter_do_filtfilt -aubio_filter_do_outplace -aubio_filter_do_reset -aubio_filter_get_feedback -aubio_filter_get_feedforward -aubio_filter_get_order -aubio_filter_get_samplerate -aubio_filter_set_a_weighting -aubio_filter_set_biquad -aubio_filter_set_c_weighting -aubio_filter_set_samplerate -aubio_filterbank_do -aubio_filterbank_get_coeffs -aubio_filterbank_set_coeffs -aubio_filterbank_set_mel_coeffs_slaney -aubio_filterbank_set_triangle_bands -aubio_freqtobin -aubio_freqtomidi -aubio_hist_do -aubio_hist_do_notnull -aubio_hist_dyn_notnull -aubio_hist_mean -aubio_hist_weight -aubio_io_validate_channels -aubio_io_validate_samplerate -aubio_is_power_of_two -aubio_level_detection -aubio_level_lin -aubio_log -aubio_log_reset -aubio_log_set_function -aubio_log_set_level_function -aubio_mfcc_do -aubio_miditobin -aubio_miditofreq -aubio_next_power_of_two -aubio_notes_do -aubio_notes_get_minioi_ms -aubio_notes_get_silence -aubio_notes_set_minioi_ms -aubio_notes_set_silence -aubio_onset_do -aubio_onset_get_awhitening -aubio_onset_get_compression -aubio_onset_get_delay -aubio_onset_get_delay_ms -aubio_onset_get_delay_s -aubio_onset_get_descriptor -aubio_onset_get_last -aubio_onset_get_last_ms -aubio_onset_get_last_s -aubio_onset_get_minioi -aubio_onset_get_minioi_ms -aubio_onset_get_minioi_s -aubio_onset_get_silence -aubio_onset_get_threshold -aubio_onset_get_thresholded_descriptor -aubio_onset_reset -aubio_onset_set_awhitening -aubio_onset_set_compression -aubio_onset_set_default_parameters -aubio_onset_set_delay -aubio_onset_set_delay_ms -aubio_onset_set_delay_s -aubio_onset_set_minioi -aubio_onset_set_minioi_ms -aubio_onset_set_minioi_s -aubio_onset_set_silence -aubio_onset_set_threshold -aubio_ooura_cdft -aubio_ooura_ddct -aubio_ooura_ddst -aubio_ooura_dfct -aubio_ooura_dfst -aubio_ooura_rdft -aubio_parameter_get_current_value -aubio_parameter_get_max_value -aubio_parameter_get_min_value -aubio_parameter_get_next_value -aubio_parameter_get_steps -aubio_parameter_set_current_value -aubio_parameter_set_max_value -aubio_parameter_set_min_value -aubio_parameter_set_steps -aubio_parameter_set_target_value -aubio_peakpicker_do -aubio_peakpicker_get_threshold -aubio_peakpicker_get_thresholded_input -aubio_peakpicker_get_thresholdfn -aubio_peakpicker_set_threshold -aubio_peakpicker_set_thresholdfn -aubio_pitch_cands -aubio_pitch_do -aubio_pitch_get_confidence -aubio_pitch_get_silence -aubio_pitch_get_tolerance -aubio_pitch_set_silence -aubio_pitch_set_tolerance -aubio_pitch_set_unit -aubio_pitch_slideblock -aubio_pitchfcomb_do -aubio_pitchmcomb_combdet -aubio_pitchmcomb_do -aubio_pitchmcomb_get_root_peak -aubio_pitchmcomb_quadpick -aubio_pitchmcomb_sort_cand_ene -aubio_pitchmcomb_sort_cand_freq -aubio_pitchmcomb_sort_peak -aubio_pitchmcomb_spectral_pp -aubio_pitchschmitt_do -aubio_pitchspecacf_do -aubio_pitchspecacf_get_confidence -aubio_pitchspecacf_get_tolerance -aubio_pitchspecacf_set_tolerance -aubio_pitchyin_diff -aubio_pitchyin_do -aubio_pitchyin_get_confidence -aubio_pitchyin_get_tolerance -aubio_pitchyin_getcum -aubio_pitchyin_getpitch -aubio_pitchyin_set_tolerance -aubio_pitchyinfft_do -aubio_pitchyinfft_get_confidence -aubio_pitchyinfft_get_tolerance -aubio_pitchyinfft_set_tolerance -aubio_pvoc_do -aubio_pvoc_rdo -aubio_quadfrac -aubio_resampler_do -aubio_sampler_do -aubio_sampler_do_multi -aubio_sampler_get_playing -aubio_sampler_load -aubio_sampler_play -aubio_sampler_set_playing -aubio_sampler_stop -aubio_scale_do -aubio_scale_set_limits -aubio_schmittS16LE -aubio_silence_detection -aubio_sink_close -aubio_sink_do -aubio_sink_do_multi -aubio_sink_get_channels -aubio_sink_get_samplerate -aubio_sink_preset_channels -aubio_sink_preset_samplerate -aubio_sink_sndfile_close -aubio_sink_sndfile_do -aubio_sink_sndfile_do_multi -aubio_sink_sndfile_get_channels -aubio_sink_sndfile_get_samplerate -aubio_sink_sndfile_open -aubio_sink_sndfile_preset_channels -aubio_sink_sndfile_preset_samplerate -aubio_sink_wavwrite_close -aubio_sink_wavwrite_do -aubio_sink_wavwrite_do_multi -aubio_sink_wavwrite_get_channels -aubio_sink_wavwrite_get_samplerate -aubio_sink_wavwrite_open -aubio_sink_wavwrite_preset_channels -aubio_sink_wavwrite_preset_samplerate -aubio_source_avcodec_close -aubio_source_avcodec_do -aubio_source_avcodec_do_multi -aubio_source_avcodec_get_channels -aubio_source_avcodec_get_duration -aubio_source_avcodec_get_samplerate -aubio_source_avcodec_has_network_url -aubio_source_avcodec_readframe -aubio_source_avcodec_reset_resampler -aubio_source_avcodec_seek -aubio_source_close -aubio_source_do -aubio_source_do_multi -aubio_source_get_channels -aubio_source_get_duration -aubio_source_get_samplerate -aubio_source_seek -aubio_source_sndfile_close -aubio_source_sndfile_do -aubio_source_sndfile_do_multi -aubio_source_sndfile_get_channels -aubio_source_sndfile_get_duration -aubio_source_sndfile_get_samplerate -aubio_source_sndfile_seek -aubio_source_wavread_close -aubio_source_wavread_do -aubio_source_wavread_do_multi -aubio_source_wavread_get_channels -aubio_source_wavread_get_duration -aubio_source_wavread_get_samplerate -aubio_source_wavread_readframe -aubio_source_wavread_seek -aubio_specdesc_centroid -aubio_specdesc_complex -aubio_specdesc_decrease -aubio_specdesc_do -aubio_specdesc_energy -aubio_specdesc_hfc -aubio_specdesc_kl -aubio_specdesc_kurtosis -aubio_specdesc_mkl -aubio_specdesc_phase -aubio_specdesc_rolloff -aubio_specdesc_skewness -aubio_specdesc_slope -aubio_specdesc_specdiff -aubio_specdesc_specflux -aubio_specdesc_spread -aubio_specdesc_wphase -aubio_spectral_whitening_do -aubio_spectral_whitening_get_floor -aubio_spectral_whitening_get_relax_time -aubio_spectral_whitening_reset -aubio_spectral_whitening_set_floor -aubio_spectral_whitening_set_relax_time -aubio_tempo_do -aubio_tempo_get_bpm -aubio_tempo_get_confidence -aubio_tempo_get_delay -aubio_tempo_get_delay_ms -aubio_tempo_get_delay_s -aubio_tempo_get_last -aubio_tempo_get_last_ms -aubio_tempo_get_last_s -aubio_tempo_get_last_tatum -aubio_tempo_get_period -aubio_tempo_get_period_s -aubio_tempo_get_silence -aubio_tempo_get_threshold -aubio_tempo_set_delay -aubio_tempo_set_delay_ms -aubio_tempo_set_delay_s -aubio_tempo_set_silence -aubio_tempo_set_tatum_signature -aubio_tempo_set_threshold -aubio_tempo_was_tatum -aubio_tss_do -aubio_tss_set_alpha -aubio_tss_set_beta -aubio_tss_set_threshold -aubio_unwrap2pi -aubio_wavetable_do -aubio_wavetable_do_multi -aubio_wavetable_get_amp -aubio_wavetable_get_freq -aubio_wavetable_get_playing -aubio_wavetable_play -aubio_wavetable_set_amp -aubio_wavetable_set_freq -aubio_wavetable_set_playing -aubio_wavetable_stop -aubio_zero_crossing_rate -cvec_centroid -cvec_copy -cvec_logmag -cvec_mean -cvec_moment -cvec_norm_get_data -cvec_norm_get_sample -cvec_norm_ones -cvec_norm_set_all -cvec_norm_set_sample -cvec_norm_zeros -cvec_phas_get_data -cvec_phas_get_sample -cvec_phas_ones -cvec_phas_set_all -cvec_phas_set_sample -cvec_phas_zeros -cvec_print -cvec_sum -cvec_zeros -del_aubio_beattracking -del_aubio_fft -del_aubio_filter -del_aubio_filterbank -del_aubio_hist -del_aubio_mfcc -del_aubio_notes -del_aubio_onset -del_aubio_parameter -del_aubio_peakpicker -del_aubio_pitch -del_aubio_pitchfcomb -del_aubio_pitchmcomb -del_aubio_pitchschmitt -del_aubio_pitchspecacf -del_aubio_pitchyin -del_aubio_pitchyinfft -del_aubio_pvoc -del_aubio_resampler -del_aubio_sampler -del_aubio_scale -del_aubio_sink -del_aubio_sink_sndfile -del_aubio_sink_wavwrite -del_aubio_source -del_aubio_source_avcodec -del_aubio_source_sndfile -del_aubio_source_wavread -del_aubio_specdesc -del_aubio_spectral_whitening -del_aubio_tempo -del_aubio_tss -del_aubio_wavetable -del_cvec -del_fmat -del_fvec -del_lvec -fmat_copy -fmat_get_channel -fmat_get_channel_data -fmat_get_data -fmat_get_sample -fmat_ones -fmat_print -fmat_rev -fmat_set -fmat_set_sample -fmat_vecmul -fmat_weight -fmat_zeros -fvec_abs -fvec_adapt_thres -fvec_add -fvec_alpha_norm -fvec_alpha_normalise -fvec_ceil -fvec_clamp -fvec_copy -fvec_cos -fvec_exp -fvec_floor -fvec_get_data -fvec_get_sample -fvec_gettimesig -fvec_ishift -fvec_local_hfc -fvec_log -fvec_log10 -fvec_max -fvec_max_elem -fvec_mean -fvec_median -fvec_min -fvec_min_elem -fvec_min_removal -fvec_moving_thres -fvec_ones -fvec_peakpick -fvec_pow -fvec_print -fvec_push -fvec_quadratic_peak_mag -fvec_quadratic_peak_pos -fvec_rev -fvec_round -fvec_set_all -fvec_set_sample -fvec_set_window -fvec_shift -fvec_sin -fvec_sqrt -fvec_sum -fvec_weight -fvec_weighted_copy -fvec_zeros -lvec_get_data -lvec_get_sample -lvec_ones -lvec_print -lvec_set_all -lvec_set_sample -lvec_zeros -new_aubio_beattracking -new_aubio_fft -new_aubio_filter -new_aubio_filter_a_weighting -new_aubio_filter_biquad -new_aubio_filter_c_weighting -new_aubio_filterbank -new_aubio_hist -new_aubio_mfcc -new_aubio_notes -new_aubio_onset -new_aubio_parameter -new_aubio_peakpicker -new_aubio_pitch -new_aubio_pitchfcomb -new_aubio_pitchmcomb -new_aubio_pitchschmitt -new_aubio_pitchspecacf -new_aubio_pitchyin -new_aubio_pitchyinfft -new_aubio_pvoc -new_aubio_resampler -new_aubio_sampler -new_aubio_scale -new_aubio_sink -new_aubio_sink_sndfile -new_aubio_sink_wavwrite -new_aubio_source -new_aubio_source_avcodec -new_aubio_source_sndfile -new_aubio_source_wavread -new_aubio_specdesc -new_aubio_spectral_whitening -new_aubio_tempo -new_aubio_tss -new_aubio_wavetable -new_aubio_window -new_cvec -new_fmat -new_fvec -new_lvec diff --git a/ports/aubio/crt_lib_linkage.patch b/ports/aubio/crt_lib_linkage.patch deleted file mode 100644 index 36a8a3640..000000000 --- a/ports/aubio/crt_lib_linkage.patch +++ /dev/null @@ -1,68 +0,0 @@ -diff --git a/src/wscript_build b/src/wscript_build -index 0a7d72a..bf84227 100644 ---- a/src/wscript_build -+++ b/src/wscript_build -@@ -24,7 +24,12 @@ ctx(features = 'c', - if ctx.env['DEST_OS'] in ['ios', 'iosimulator']: - build_features = ['cstlib', 'cshlib'] - elif ctx.env['DEST_OS'] in ['win32', 'win64']: -- build_features = ['cstlib', 'cshlib'] -+ if ctx.options.library_linkage == "static": -+ build_features = ['cstlib'] -+ elif ctx.options.library_linkage == "dynamic": -+ build_features = ['cshlib'] -+ else: -+ build_features = ['cstlib', 'cshlib'] - elif ctx.env['DEST_OS'] in ['emscripten']: - build_features = ['cstlib'] - elif '--static' in ctx.env['LDFLAGS'] or '--static' in ctx.env['LINKFLAGS']: -diff --git a/wscript b/wscript -index 6363f1e..e0d57a4 100644 ---- a/wscript -+++ b/wscript -@@ -44,6 +44,16 @@ def options(ctx): - dest = 'build_type', - help = 'whether to compile with (--build-type=release) or without (--build-type=debug) '\ - ' compiler opimizations [default: release]') -+ ctx.add_option('--crt-linkage', action = 'store', -+ default = "dynamic", -+ choices = ('static', 'dynamic'), -+ dest = 'crt_linkage', -+ help = 'whether to compile with static CRT linkage (--crt-linkage=static) or the default dynamic (--crt-linkage=dynamic)') -+ ctx.add_option('--library-linkage', action = 'store', -+ default = "both", -+ choices = ('dynamic', 'static', 'both'), -+ dest = 'library_linkage', -+ help = 'whether to compile a dynamic (shared) (--library-linkage=dynamic) or static library (--library-linkage=static) ("both" is broken for msvc)') - add_option_enable_disable(ctx, 'fftw3f', default = False, - help_str = 'compile with fftw3f instead of ooura (recommended)', - help_disable_str = 'do not compile with fftw3f') -@@ -139,16 +149,25 @@ def configure(ctx): - else: - # enable debug symbols - ctx.env.CFLAGS += ['/Z7', '/FS'] -- ctx.env.LINKFLAGS += ['/DEBUG', '/INCREMENTAL:NO'] -+ if ctx.options.library_linkage == "dynamic": -+ ctx.env.LINKFLAGS += ['/DEBUG', '/INCREMENTAL:NO', '/DEF:..\\aubio-5.def'] -+ else: -+ ctx.env.LINKFLAGS += ['/DEBUG', '/INCREMENTAL:NO'] - # configure warnings - ctx.env.CFLAGS += ['/W4', '/D_CRT_SECURE_NO_WARNINGS'] - # set optimization level and runtime libs - if (ctx.options.build_type == "release"): - ctx.env.CFLAGS += ['/Ox'] -- ctx.env.CFLAGS += ['/MD'] -+ if (ctx.options.crt_linkage == "static"): -+ ctx.env.CFLAGS += ['/MT'] -+ else: -+ ctx.env.CFLAGS += ['/MD'] - else: - assert(ctx.options.build_type == "debug") -- ctx.env.CFLAGS += ['/MDd'] -+ if (ctx.options.crt_linkage == "static"): -+ ctx.env.CFLAGS += ['/MTd'] -+ else: -+ ctx.env.CFLAGS += ['/MDd'] - - ctx.check_cc(lib='m', uselib_store='M', mandatory=False) - diff --git a/ports/aubio/portfile.cmake b/ports/aubio/portfile.cmake index e8a7d4551..1e1993326 100644 --- a/ports/aubio/portfile.cmake +++ b/ports/aubio/portfile.cmake @@ -7,7 +7,7 @@ vcpkg_download_distfile(ARCHIVE ) vcpkg_extract_source_archive(${ARCHIVE}) -file(COPY ${CMAKE_CURRENT_LIST_DIR}/aubio-5.def ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH}) +file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH}) vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} @@ -17,12 +17,12 @@ vcpkg_configure_cmake( vcpkg_install_cmake() # Handle copyright and credentials -file(COPY - ${SOURCE_PATH}/COPYING - ${SOURCE_PATH}/AUTHORS - ${SOURCE_PATH}/ChangeLog - ${SOURCE_PATH}/README.md - DESTINATION +file(COPY + ${SOURCE_PATH}/COPYING + ${SOURCE_PATH}/AUTHORS + ${SOURCE_PATH}/ChangeLog + ${SOURCE_PATH}/README.md + DESTINATION ${CURRENT_PACKAGES_DIR}/share/aubio) vcpkg_copy_pdbs() From 196b48ef5f1344a845e8381676f2798eb1011809 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Wed, 28 Jun 2017 13:56:24 -0700 Subject: [PATCH 45/50] [aubio] Add capability to build tools (note: currently fails due to missing config.h) --- ports/aubio/CMakeLists.txt | 146 +++++++++++++++++++++++-------------- ports/aubio/CONTROL | 2 +- ports/aubio/portfile.cmake | 7 +- 3 files changed, 97 insertions(+), 58 deletions(-) diff --git a/ports/aubio/CMakeLists.txt b/ports/aubio/CMakeLists.txt index 6577e075c..bb24c5b15 100644 --- a/ports/aubio/CMakeLists.txt +++ b/ports/aubio/CMakeLists.txt @@ -1,56 +1,90 @@ -cmake_minimum_required(VERSION 3.8) -project(aubio C) - -add_definitions( - -DHAVE_STDLIB_H=1 - -DHAVE_STDIO_H=1 - -DHAVE_MATH_H=1 - -DHAVE_STRING_H=1 - -DHAVE_LIMITS_H=1 - -DHAVE_STDARG_H=1 - -DHAVE_C99_VARARGS_MACROS=1 - - -DHAVE_SNDFILE=1 - -DHAVE_WAVWRITE=1 - -DHAVE_WAVREAD=1 - -DHAVE_LIBAV=1 - -DHAVE_SWRESAMPLE=1 -) - -set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - -find_path(LIBSNDFILE_H sndfile.h) -find_library(LIBSNDFILE_LIB NAMES libsndfile-1 libsndfile) -find_library(AVCODEC_LIB avcodec) -find_library(AVUTIL_LIB avutil) -find_library(AVDEVICE_LIB avdevice) -find_library(AVFILTER_LIB avfilter) -find_library(AVFORMAT_LIB avformat) -find_library(SWRESAMPLE_LIB swresample) - -include_directories(src ${LIBSNDFILE_H}) -link_libraries(${LIBSNDFILE_LIB} ${AVCODEC_LIB} ${AVUTIL_LIB} ${AVDEVICE_LIB} ${AVFILTER_LIB} ${AVFORMAT_LIB} ${SWRESAMPLE_LIB} ws2_32.lib) - -file(GLOB_RECURSE SOURCES src/*.c) -set_source_files_properties(src/io/sink_wavwrite.c PROPERTIES COMPILE_FLAGS /FIWinsock2.h) -add_library(aubio ${SOURCES}) - -set(CMAKE_DEBUG_POSTFIX d) - -install( - TARGETS aubio - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib -) - -if(NOT DISABLE_INSTALL_HEADERS) - install( - DIRECTORY src/ - DESTINATION include/aubio - FILES_MATCHING - PATTERN "*.h" - PATTERN "*_priv.h" EXCLUDE - PATTERN "config.h" EXCLUDE - ) -endif() +cmake_minimum_required(VERSION 3.8) +project(aubio C) + +add_definitions( + -DHAVE_STDLIB_H=1 + -DHAVE_STDIO_H=1 + -DHAVE_MATH_H=1 + -DHAVE_STRING_H=1 + -DHAVE_LIMITS_H=1 + -DHAVE_STDARG_H=1 + -DHAVE_C99_VARARGS_MACROS=1 + + -DHAVE_SNDFILE=1 + -DHAVE_WAVWRITE=1 + -DHAVE_WAVREAD=1 + -DHAVE_LIBAV=1 + -DHAVE_SWRESAMPLE=1 +) + +set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) +set(CMAKE_DEBUG_POSTFIX d) + +option(BUILD_TOOLS "Build and install tools" ON) +set(TOOLS_INSTALLDIR "bin" CACHE STRING "Target directory for installed tools") + +find_path(LIBSNDFILE_H sndfile.h) +find_library(LIBSNDFILE_LIB NAMES libsndfile-1 libsndfile) +find_library(AVCODEC_LIB avcodec) +find_library(AVUTIL_LIB avutil) +find_library(AVDEVICE_LIB avdevice) +find_library(AVFILTER_LIB avfilter) +find_library(AVFORMAT_LIB avformat) +find_library(SWRESAMPLE_LIB swresample) +find_library(OGG_LIB ogg) +find_library(FLAC_LIB flac) +find_library(VORBIS_LIB vorbis) +find_library(VORBISENC_LIB vorbisenc) + +include_directories(src ${LIBSNDFILE_H}) + +file(GLOB_RECURSE SOURCES src/*.c) + +set_source_files_properties(src/io/sink_wavwrite.c PROPERTIES COMPILE_FLAGS /FIWinsock2.h) +add_library(aubio ${SOURCES}) +target_link_libraries(aubio PUBLIC + ${LIBSNDFILE_LIB} + ${OGG_LIB} + ${FLAC_LIB} + ${VORBIS_LIB} + ${VORBISENC_LIB} + ${AVCODEC_LIB} + ${AVUTIL_LIB} + ${AVDEVICE_LIB} + ${AVFILTER_LIB} + ${AVFORMAT_LIB} + ${SWRESAMPLE_LIB} + ws2_32.lib +) + +if(BUILD_TOOLS) + set(EXAMPLE_EXECS aubiomfcc aubionotes aubioonset aubiopitch aubioquiet aubiotrack) + foreach(EXAMPLE_EXEC ${EXAMPLE_EXECS}) + add_executable(${EXAMPLE_EXEC} examples/${EXAMPLE_EXEC}.c examples/utils.c examples/jackio.c) + target_link_libraries(${EXAMPLE_EXEC} PRIVATE aubio) + target_compile_definitions(${EXAMPLE_EXEC} PRIVATE -DHAVE_WIN_HACKS=1) + endforeach() + + install( + TARGETS ${EXAMPLE_EXECS} + RUNTIME DESTINATION ${TOOLS_INSTALLDIR} + ) +endif() + +install( + TARGETS aubio + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib +) + +if(NOT DISABLE_INSTALL_HEADERS) + install( + DIRECTORY src/ + DESTINATION include/aubio + FILES_MATCHING + PATTERN "*.h" + PATTERN "*_priv.h" EXCLUDE + PATTERN "config.h" EXCLUDE + ) +endif() diff --git a/ports/aubio/CONTROL b/ports/aubio/CONTROL index f7aee6191..3edc3db74 100644 --- a/ports/aubio/CONTROL +++ b/ports/aubio/CONTROL @@ -1,4 +1,4 @@ Source: aubio Version: 0.46~alpha Description: Aubio is a tool designed for the extraction of annotations from audio signals. Its features include segmenting a sound file before each of its attacks, performing pitch detection, tapping the beat and producing midi streams from live audio. -Build-Depends: ffmpeg, libsndfile +Build-Depends: ffmpeg, libsndfile, libogg, libflac, libvorbis diff --git a/ports/aubio/portfile.cmake b/ports/aubio/portfile.cmake index 1e1993326..6f7b5fbc8 100644 --- a/ports/aubio/portfile.cmake +++ b/ports/aubio/portfile.cmake @@ -12,7 +12,12 @@ file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH}) vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} PREFER_NINJA - OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=1 + OPTIONS_RELEASE + #-DTOOLS_INSTALLDIR=tools/aubio + -DBUILD_TOOLS=OFF + OPTIONS_DEBUG + -DDISABLE_INSTALL_HEADERS=1 + -DBUILD_TOOLS=OFF ) vcpkg_install_cmake() From a88a904849e03cc807942f78edf06ba7b464b6cd Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Wed, 28 Jun 2017 14:16:48 -0700 Subject: [PATCH 46/50] [kinectsdk1] Move includes to match how the SDK expects them to be included --- ports/kinectsdk1/CONTROL | 2 +- ports/kinectsdk1/portfile.cmake | 16 +++------------- 2 files changed, 4 insertions(+), 14 deletions(-) diff --git a/ports/kinectsdk1/CONTROL b/ports/kinectsdk1/CONTROL index 21f531425..3d4c83fd2 100644 --- a/ports/kinectsdk1/CONTROL +++ b/ports/kinectsdk1/CONTROL @@ -1,3 +1,3 @@ Source: kinectsdk1 -Version: 1.8 +Version: 1.8-1 Description: Kinect for Windows SDK for Kinect v1 sensor. diff --git a/ports/kinectsdk1/portfile.cmake b/ports/kinectsdk1/portfile.cmake index 61f006492..3df29b3bf 100644 --- a/ports/kinectsdk1/portfile.cmake +++ b/ports/kinectsdk1/portfile.cmake @@ -1,15 +1,3 @@ -# Common Ambient Variables: -# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT} -# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET} -# CURRENT_PORT_DIR = ${VCPKG_ROOT_DIR}\ports\${PORT} -# PORT = current port name (zlib, etc) -# TARGET_TRIPLET = current triplet (x86-windows, x64-windows-static, etc) -# VCPKG_CRT_LINKAGE = C runtime linkage type (static, dynamic) -# VCPKG_LIBRARY_LINKAGE = target library linkage type (static, dynamic) -# VCPKG_ROOT_DIR = -# VCPKG_TARGET_ARCHITECTURE = target architecture (x64, x86, arm) -# - include(vcpkg_common_functions) get_filename_component(KINECTSDK10_DIR "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Kinect;SDKInstallPath]" ABSOLUTE CACHE) @@ -24,13 +12,15 @@ file( "${KINECTSDK10_DIR}/inc/NuiSensor.h" "${KINECTSDK10_DIR}/inc/NuiSkeleton.h" DESTINATION - ${CURRENT_PACKAGES_DIR}/include/kinectsdk1 + ${CURRENT_PACKAGES_DIR}/include ) if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86") set(ARCHITECTURE x86) elseif(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64") set(ARCHITECTURE amd64) +else() + message(FATAL_ERROR "This port does not currently support architecture: ${VCPKG_TARGET_ARCHITECTURE}") endif() file( From 59441adf76db180ff9ba9b0d92443d607d7c4741 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Wed, 28 Jun 2017 14:19:40 -0700 Subject: [PATCH 47/50] [kinectsdk1] Improve not-found error message --- ports/kinectsdk1/portfile.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/kinectsdk1/portfile.cmake b/ports/kinectsdk1/portfile.cmake index 3df29b3bf..aef4cd1c2 100644 --- a/ports/kinectsdk1/portfile.cmake +++ b/ports/kinectsdk1/portfile.cmake @@ -2,7 +2,7 @@ include(vcpkg_common_functions) get_filename_component(KINECTSDK10_DIR "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Kinect;SDKInstallPath]" ABSOLUTE CACHE) if(NOT EXISTS "${KINECTSDK10_DIR}") - message(FATAL_ERROR "Error: Could not find Kinect for Windows SDK v1.x.") + message(FATAL_ERROR "Error: Could not find Kinect for Windows SDK v1.x. It can be downloaded from https://www.microsoft.com/en-us/download/details.aspx?id=40278.") endif() file( From 2c248dd4a6f473e57ade0c529b81e3b8f3b4dd4e Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Wed, 28 Jun 2017 14:26:44 -0700 Subject: [PATCH 48/50] [rtmidi] Slightly simplify cmake replacement --- ports/rtmidi/CMakeLists.txt | 25 ++----------------------- ports/rtmidi/CONTROL | 2 +- 2 files changed, 3 insertions(+), 24 deletions(-) diff --git a/ports/rtmidi/CMakeLists.txt b/ports/rtmidi/CMakeLists.txt index 0603fdcb8..91782fd18 100644 --- a/ports/rtmidi/CMakeLists.txt +++ b/ports/rtmidi/CMakeLists.txt @@ -1,32 +1,11 @@ cmake_minimum_required(VERSION 3.8) project(rtmidi CXX) -set(RTMIDI_SOURCES - ${PROJECT_SOURCE_DIR}/RtMidi.cpp - ${PROJECT_SOURCE_DIR}/rtmidi_c.cpp -) - -set(RTMIDI_HEADERS - ${PROJECT_SOURCE_DIR}/RtMidi.h - ${PROJECT_SOURCE_DIR}/rtmidi_c.h -) - -include_directories(${RTMIDI_HEADERS}) - -if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic) - set(BUILD_SHARED_LIBS ON) -else() - set(BUILD_SHARED_LIBS OFF) -endif() - +add_library(rtmidi RtMidi.cpp rtmidi_c.cpp) if(BUILD_SHARED_LIBS) - add_library(rtmidi SHARED ${RTMIDI_SOURCES}) target_compile_definitions(rtmidi PRIVATE -DRTMIDI_EXPORT) -else() - add_library(rtmidi STATIC ${RTMIDI_SOURCES}) endif() - file(READ "${PROJECT_SOURCE_DIR}/rtmidi_c.h" RTMIDI_EXPORT) if (BUILD_SHARED_LIBS) string(REPLACE "if defined(RTMIDI_EXPORT)" "if 1" RTMIDI_EXPORT "${RTMIDI_EXPORT}") @@ -43,6 +22,6 @@ install( ) if(NOT DISABLE_INSTALL_HEADERS) - install(FILES "${PROJECT_SOURCE_DIR}/RtMidi.h" DESTINATION include) + install(FILES "RtMidi.h" DESTINATION include) install(FILES "${PROJECT_BINARY_DIR}/rtmidi_c.h" DESTINATION include) endif() diff --git a/ports/rtmidi/CONTROL b/ports/rtmidi/CONTROL index 9cf64df9e..9057812a0 100644 --- a/ports/rtmidi/CONTROL +++ b/ports/rtmidi/CONTROL @@ -1,3 +1,3 @@ Source: rtmidi -Version: 2.1.1 +Version: 2.1.1-1 Description: A set of C++ classes that provide a common API for realtime MIDI input/output across Linux (ALSA & JACK), Macintosh OS X (CoreMidi & JACK) and Windows (Multimedia) From 821039eeb702b0f65156fb5510d53b0b9210c506 Mon Sep 17 00:00:00 2001 From: Brad Anderson Date: Wed, 28 Jun 2017 15:09:00 -0600 Subject: [PATCH 49/50] [tinyxml2] Update tinyxml2 to fix static linkage Also specify BUILD_STATIC_LIBS when building static --- ports/tinyxml2/CONTROL | 4 ++-- ports/tinyxml2/portfile.cmake | 12 ++++++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/ports/tinyxml2/CONTROL b/ports/tinyxml2/CONTROL index ee5e20f34..aaa9a7c4f 100644 --- a/ports/tinyxml2/CONTROL +++ b/ports/tinyxml2/CONTROL @@ -1,3 +1,3 @@ Source: tinyxml2 -Version: 5.0.0 -Description: A simple, small, efficient, C++ XML parser \ No newline at end of file +Version: 5.0.1 +Description: A simple, small, efficient, C++ XML parser diff --git a/ports/tinyxml2/portfile.cmake b/ports/tinyxml2/portfile.cmake index 59184178d..0c8b0b84b 100644 --- a/ports/tinyxml2/portfile.cmake +++ b/ports/tinyxml2/portfile.cmake @@ -3,13 +3,21 @@ include(vcpkg_common_functions) vcpkg_from_github( OUT_SOURCE_PATH SOURCE_PATH REPO leethomason/tinyxml2 - REF 5.0.0 - SHA512 ef310a466d0aec9dd0d25063c68f5312cd063366ee57499d8e462e25a556ea510617b66cdec1a368e8867dc082e0297e27fe09f16eb915392235be34206881e4 + REF 5.0.1 + SHA512 a51ec5843774df0482620c549fb6c61d30a6db5025be26ff6d25b3c53533a27a57f00b026bd9fbca78e9e30084b3f5f6fbff9dba315d078419da084b57f518ba HEAD_REF master ) +if(VCPKG_LIBRARY_LINKAGE STREQUAL static) + set(BUILD_STATIC_LIBS 1) +else() + set(BUILD_STATIC_LIBS 0) +endif() + vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} + OPTIONS + -DBUILD_STATIC_LIBS=${BUILD_STATIC_LIBS} ) vcpkg_install_cmake() From 43ac9177ecde47a33b18e4e1c6617e15b3d3abd9 Mon Sep 17 00:00:00 2001 From: Robert Schumacher Date: Wed, 28 Jun 2017 15:12:28 -0700 Subject: [PATCH 50/50] [ctemplate] CMakeLists.txt simplification --- ports/ctemplate/CMakeLists.txt | 11 +++++------ ports/ctemplate/portfile.cmake | 9 +-------- 2 files changed, 6 insertions(+), 14 deletions(-) diff --git a/ports/ctemplate/CMakeLists.txt b/ports/ctemplate/CMakeLists.txt index 22869f7c5..c7cc211f4 100644 --- a/ports/ctemplate/CMakeLists.txt +++ b/ports/ctemplate/CMakeLists.txt @@ -2,6 +2,9 @@ cmake_minimum_required(VERSION 3.5.1) project(libctemplate C CXX) # find_package(PythonInterp) +if(NOT PYTHON_EXECUTABLE) + message(FATAL_ERROR "PYTHON_EXECUTABLE must be set") +endif() if(MSVC) add_compile_options(/W3 /wd4005 /wd4996 /wd4018 -D_CRT_SECURE_NO_WARNINGS) @@ -73,14 +76,10 @@ execute_process( file(WRITE "${COMMON_INCLUDES}/htmlparser/htmlparser_fsm.h" "${HTMLPARSER_CONFIG_H}") file(WRITE "${COMMON_INCLUDES}/htmlparser/jsparser_fsm.h" "${JSPASPER_CONFIG_H}") -option(BUILD_SHARED_LIBRARY "Building shared library" ON) - include_directories(${COMMON_INCLUDES}) -if(BUILD_SHARED_LIBRARY) - add_library(libctemplate SHARED ${SRC_FILES}) -else() - add_library(libctemplate STATIC ${SRC_FILES} ) +add_library(libctemplate ${SRC_FILES}) +if(NOT BUILD_SHARED_LIBS) # Note: CTEMPLATE_DLL_DECL should be empty to build static file target_compile_definitions(libctemplate PRIVATE -DCTEMPLATE_DLL_DECL=) endif() diff --git a/ports/ctemplate/portfile.cmake b/ports/ctemplate/portfile.cmake index cb1e07b74..af1f0532c 100644 --- a/ports/ctemplate/portfile.cmake +++ b/ports/ctemplate/portfile.cmake @@ -19,16 +19,9 @@ vcpkg_apply_patches( ${CMAKE_CURRENT_LIST_DIR}/fix-msvc.patch ) -if(VCPKG_LIBRARY_LINKAGE STREQUAL dynamic) - set (BUILD_SHARED_LIBRARY ON) -else() - set(BUILD_SHARED_LIBRARY OFF) -endif() - - vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} - OPTIONS -DPYTHON_EXECUTABLE=${PYTHON2} -DBUILD_SHARED_LIBRARY=${BUILD_SHARED_LIBRARY} + OPTIONS -DPYTHON_EXECUTABLE=${PYTHON2} OPTIONS_DEBUG -DDISABLE_INSTALL_HEADERS=ON )