aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVinny <vpaladino778@gmail.com>2019-10-30 15:39:13 -0400
committerdan-shaw <51385773+dan-shaw@users.noreply.github.com>2019-10-30 12:39:13 -0700
commit00a29c6879db2981093b73fa7006c9d07fb2f861 (patch)
tree6bb92a1275cd20a24b8aa8b5f549b08d8b7a624e
parent694ecbd7348ff181e63a202916f7eea50c555a63 (diff)
downloadvcpkg-00a29c6879db2981093b73fa7006c9d07fb2f861.tar.gz
vcpkg-00a29c6879db2981093b73fa7006c9d07fb2f861.zip
Added OIS port (#8507)
* Added OIS port * Portfile deletes bin/ and debug/bin/ when library is static * Replaced configure_file() call with file(INSTALL) call * Added fail on ARM or UWP * Moved early failure to top of file
-rw-r--r--ports/ois/CONTROL4
-rw-r--r--ports/ois/portfile.cmake31
2 files changed, 35 insertions, 0 deletions
diff --git a/ports/ois/CONTROL b/ports/ois/CONTROL
new file mode 100644
index 000000000..2759167a7
--- /dev/null
+++ b/ports/ois/CONTROL
@@ -0,0 +1,4 @@
+Source: ois
+Version: 1.5
+Description: Cross Platform Object Oriented Input Lib System. Meant to be very robust and compatiable with many systems and operating systems.
+Homepage: https://wgois.github.io/OIS/ \ No newline at end of file
diff --git a/ports/ois/portfile.cmake b/ports/ois/portfile.cmake
new file mode 100644
index 000000000..526cdb6b8
--- /dev/null
+++ b/ports/ois/portfile.cmake
@@ -0,0 +1,31 @@
+# Automatically fail port install for UWP and ARM. Unsure if it is
+# supported by library. See here: https://github.com/wgois/OIS/issues/57
+vcpkg_fail_port_install(ON_ARCH "arm" "arm64" ON_TARGET "uwp")
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO wgois/OIS
+ REF v1.5
+ SHA512 5ab1dda7c25c1959ccbbb758ea3fda36bd62ad65f46e2c6b418317a5eb39e0bace52a44ae079dfb69fc58c90df54f8e50d589daae1100ec615325363c9d77513
+ HEAD_REF master
+)
+
+vcpkg_configure_cmake(
+ SOURCE_PATH ${SOURCE_PATH}
+ PREFER_NINJA
+)
+
+vcpkg_install_cmake()
+
+if(VCPKG_LIBRARY_LINKAGE STREQUAL static)
+ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin)
+endif()
+
+# Include files should not be duplicated into the /debug/include directory
+file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
+
+# Handle copyright
+file(INSTALL ${SOURCE_PATH}/LICENSE.md DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
+
+# CMake integration test
+# vcpkg_test_cmake(PACKAGE_NAME ${PORT})