diff options
| author | martin-s <webmaster@macside.net> | 2018-02-27 23:06:12 +0100 |
|---|---|---|
| committer | martin-s <webmaster@macside.net> | 2018-02-27 23:06:12 +0100 |
| commit | 0a93f4ec120f03df6368168561b61b6252bd1199 (patch) | |
| tree | 527902d3ee8949bd297a182dffc4131be704ef1c | |
| parent | ba3f552b67a76bc62ef4aecdee778ac47abf330c (diff) | |
| download | vcpkg-0a93f4ec120f03df6368168561b61b6252bd1199.tar.gz vcpkg-0a93f4ec120f03df6368168561b61b6252bd1199.zip | |
- Added port nvidia-texture-tools.
| -rw-r--r-- | ports/nvtt/CONTROL | 3 | ||||
| -rw-r--r-- | ports/nvtt/portfile.cmake | 44 |
2 files changed, 47 insertions, 0 deletions
diff --git a/ports/nvtt/CONTROL b/ports/nvtt/CONTROL new file mode 100644 index 000000000..31ff5ecf4 --- /dev/null +++ b/ports/nvtt/CONTROL @@ -0,0 +1,3 @@ +Source: nvtt
+Version: 2.1.0
+Description: Texture processing tools with support for Direct3D 10 and 11 formats.
\ No newline at end of file diff --git a/ports/nvtt/portfile.cmake b/ports/nvtt/portfile.cmake new file mode 100644 index 000000000..237a71b65 --- /dev/null +++ b/ports/nvtt/portfile.cmake @@ -0,0 +1,44 @@ +# Common Ambient Variables:
+# VCPKG_ROOT_DIR = <C:\path\to\current\vcpkg>
+# TARGET_TRIPLET is the current triplet (x86-windows, etc)
+# PORT is the current port name (zlib, etc)
+# CURRENT_BUILDTREES_DIR = ${VCPKG_ROOT_DIR}\buildtrees\${PORT}
+# CURRENT_PACKAGES_DIR = ${VCPKG_ROOT_DIR}\packages\${PORT}_${TARGET_TRIPLET}
+#
+if (VCPKG_LIBRARY_LINKAGE STREQUAL dynamic)
+ message(STATUS "Warning: Dynamic building not supported yet. Building static.")
+ set(VCPKG_LIBRARY_LINKAGE static)
+endif()
+
+include(vcpkg_common_functions)
+
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO castano/nvidia-texture-tools
+ REF 2.1.0
+ SHA512 6c5c9588af57023fc384de080cbe5c5ccd8707d04a9533384c606efd09730d780cb21bcf2d3576102a3facd2f281cacb2625958d74575e71550fd98da92e38b6
+ HEAD_REF master
+)
+
+vcpkg_configure_cmake(
+ SOURCE_PATH ${SOURCE_PATH}
+ PREFER_NINJA
+ OPTIONS
+ -DNVTT_SHARED=0
+)
+
+vcpkg_install_cmake()
+
+if(VCPKG_LIBRARY_LINKAGE STREQUAL static)
+ file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin)
+endif()
+
+vcpkg_copy_pdbs()
+
+file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
+file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
+
+# Handle copyright
+file(REMOVE ${CURRENT_PACKAGES_DIR}/share/doc/nvtt/LICENSE)
+file(COPY ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/nvtt)
+file(RENAME ${CURRENT_PACKAGES_DIR}/share/nvtt/LICENSE ${CURRENT_PACKAGES_DIR}/share/nvtt/copyright)
|
