aboutsummaryrefslogtreecommitdiff
path: root/vcpkg/ports/htscodecs/portfile.cmake
diff options
context:
space:
mode:
authorEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
committerEthan Morgan <ethan@gweithio.com>2026-02-14 16:44:06 +0000
commit54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch)
treed915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/htscodecs/portfile.cmake
move to own git serverHEADmaster
Diffstat (limited to 'vcpkg/ports/htscodecs/portfile.cmake')
-rw-r--r--vcpkg/ports/htscodecs/portfile.cmake36
1 files changed, 36 insertions, 0 deletions
diff --git a/vcpkg/ports/htscodecs/portfile.cmake b/vcpkg/ports/htscodecs/portfile.cmake
new file mode 100644
index 0000000..f18b438
--- /dev/null
+++ b/vcpkg/ports/htscodecs/portfile.cmake
@@ -0,0 +1,36 @@
+vcpkg_from_github(
+ OUT_SOURCE_PATH SOURCE_PATH
+ REPO samtools/htscodecs
+ REF "v${VERSION}"
+ SHA512 5e3e1f916cb14fe7e1292f3a07e9d9704b11be38014db5884b334235c25dbe61dffecf3f12c448a7a13f65c6d19dbc7cc5c77ba0861b31a0375d71030dd02480
+ HEAD_REF master
+ PATCHES
+ 0001-no-tests.patch # https://github.com/samtools/htscodecs/pull/120
+)
+
+set(FEATURE_OPTIONS "")
+
+macro(enable_feature feature switch)
+ if("${feature}" IN_LIST FEATURES)
+ list(APPEND FEATURE_OPTIONS "--enable-${switch}")
+ else()
+ list(APPEND FEATURE_OPTIONS "--disable-${switch}")
+ endif()
+endmacro()
+
+enable_feature("bzip2" "bz2")
+
+vcpkg_configure_make(
+ AUTOCONFIG
+ SOURCE_PATH "${SOURCE_PATH}"
+ OPTIONS
+ ${FEATURE_OPTIONS}
+)
+
+vcpkg_install_make()
+
+file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
+
+vcpkg_fixup_pkgconfig()
+
+vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE.md")