diff options
| author | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
|---|---|---|
| committer | Ethan Morgan <ethan@gweithio.com> | 2026-02-14 16:44:06 +0000 |
| commit | 54409423f767d8b1cf30cb7d0efca6b4ca138823 (patch) | |
| tree | d915ac7828703ce4b963efdd9728a1777ba18c1e /vcpkg/ports/htscodecs | |
Diffstat (limited to 'vcpkg/ports/htscodecs')
| -rw-r--r-- | vcpkg/ports/htscodecs/0001-no-tests.patch | 13 | ||||
| -rw-r--r-- | vcpkg/ports/htscodecs/portfile.cmake | 36 | ||||
| -rw-r--r-- | vcpkg/ports/htscodecs/vcpkg.json | 16 |
3 files changed, 65 insertions, 0 deletions
diff --git a/vcpkg/ports/htscodecs/0001-no-tests.patch b/vcpkg/ports/htscodecs/0001-no-tests.patch new file mode 100644 index 0000000..e18dd50 --- /dev/null +++ b/vcpkg/ports/htscodecs/0001-no-tests.patch @@ -0,0 +1,13 @@ +diff --git a/tests/Makefile.am b/tests/Makefile.am +index 873ad3e..0ab3638 100644 +--- a/tests/Makefile.am ++++ b/tests/Makefile.am +@@ -31,7 +31,7 @@ + # + + # Standalone test programs +-noinst_PROGRAMS = rans4x16pr tokenise_name3 arith_dynamic rans4x8 rans4x16pr fqzcomp_qual varint entropy ++check_PROGRAMS = rans4x16pr tokenise_name3 arith_dynamic rans4x8 rans4x16pr fqzcomp_qual varint entropy + + LDADD = $(top_builddir)/htscodecs/libhtscodecs.la + AM_CPPFLAGS = -I$(top_srcdir) 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")
diff --git a/vcpkg/ports/htscodecs/vcpkg.json b/vcpkg/ports/htscodecs/vcpkg.json new file mode 100644 index 0000000..ea583f6 --- /dev/null +++ b/vcpkg/ports/htscodecs/vcpkg.json @@ -0,0 +1,16 @@ +{ + "name": "htscodecs", + "version": "1.6.1", + "description": "Custom compression for CRAM and others.", + "homepage": "https://github.com/samtools/htscodecs", + "license": "MIT", + "supports": "!windows", + "features": { + "bzip2": { + "description": "Enable support for BZ2 within Arith streams", + "dependencies": [ + "bzip2" + ] + } + } +} |