aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsigman <sigman@ioupg.com>2017-06-07 22:08:08 +0300
committersigman <sigman@ioupg.com>2017-06-07 22:10:27 +0300
commit1831ce4bcc6f0ca18c3425563bc2de8857f30e41 (patch)
treec66361f99ce6d47c2c8c13deb39ade1bf143d2f5
parent9a698d7088beb3fa32b1b9d0321781c0ba07e18e (diff)
downloadvcpkg-1831ce4bcc6f0ca18c3425563bc2de8857f30e41.tar.gz
vcpkg-1831ce4bcc6f0ca18c3425563bc2de8857f30e41.zip
Magnum OpengGL 3d library port
Added ports to support Magnum C++ OpenGL engine http://mosra.cz/blog/magnum.php and its direct dependencies
-rw-r--r--ports/corrade/CONTROL3
-rw-r--r--ports/corrade/portfile.cmake45
-rw-r--r--ports/magnum/CONTROL4
-rw-r--r--ports/magnum/portfile.cmake33
4 files changed, 85 insertions, 0 deletions
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