From dea88ed1b612c6aed9b50c3e28f0a6c9a2d04458 Mon Sep 17 00:00:00 2001 From: mencian Date: Tue, 26 Mar 2024 01:00:34 -0500 Subject: [PATCH 1/3] tabixpp: enable linux-aarch64 build --- recipes/tabixpp/arm_hwcap.patch | 15 +++++++++++++++ recipes/tabixpp/meta.yaml | 9 ++++++--- recipes/tabixpp/shared_lib.patch | 5 +++-- 3 files changed, 24 insertions(+), 5 deletions(-) create mode 100644 recipes/tabixpp/arm_hwcap.patch diff --git a/recipes/tabixpp/arm_hwcap.patch b/recipes/tabixpp/arm_hwcap.patch new file mode 100644 index 0000000000000..873d6ae4b9850 --- /dev/null +++ b/recipes/tabixpp/arm_hwcap.patch @@ -0,0 +1,15 @@ +Conda-forge's build environment on ARM uses sysroot_linux-aarch64 2.17, which +is based on glibc 2.17 so does not define HWCAP_* values on ARM. +Work around this by including the kernel header to get the desired values. + +--- a/htslib/htscodecs/htscodecs/rANS_static4x16pr.c 2023-10-10 02:54:16 ++++ b/htslib/htscodecs/htscodecs/rANS_static4x16pr.c 2024-03-06 00:01:14 +@@ -1030,6 +1030,8 @@ + + #if defined(__linux__) || defined(__FreeBSD__) + #include ++// Ensure ARM HWCAP_* values are defined even on old glibc ++#include + #elif defined(_WIN32) + #include + #endif diff --git a/recipes/tabixpp/meta.yaml b/recipes/tabixpp/meta.yaml index db6ce10c381fa..ad291806e5cba 100644 --- a/recipes/tabixpp/meta.yaml +++ b/recipes/tabixpp/meta.yaml @@ -12,12 +12,13 @@ source: patches: - shared_lib.patch - pkg-config.patch # [osx] -- url: https://github.com/samtools/htslib/releases/download/1.17/htslib-1.17.tar.bz2 - sha256: 763779288c40f07646ec7ad98b96c378c739171d162ad98398868783b721839f + - arm_hwcap.patch # [aarch64] +- url: https://github.com/samtools/htslib/releases/download/1.19.1/htslib-1.19.1.tar.bz2 + sha256: 222d74d3574fb67b158c6988c980eeaaba8a0656f5e4ffb76b5fa57f035933ec folder: htslib build: - number: 1 + number: 2 run_exports: # Observed ABI version increase from 1.1.0 to 1.1.2. # Hence, we pin to the patch version even. @@ -53,3 +54,5 @@ extra: - biotools:tabixpp recipe-maintainers: - jpuritz + additional-platforms: + - linux-aarch64 diff --git a/recipes/tabixpp/shared_lib.patch b/recipes/tabixpp/shared_lib.patch index 819773b164a42..da684d327f915 100644 --- a/recipes/tabixpp/shared_lib.patch +++ b/recipes/tabixpp/shared_lib.patch @@ -38,9 +38,10 @@ index f2ba44e..7718d76 100644 DFLAGS = -D_FILE_OFFSET_BITS=64 -D_USE_KNETFILE BIN = tabix++ -LIB = libtabix.a -+LIB = libtabixpp.a - SOVERSION = 1 +-SOVERSION = 1 -SLIB = libtabix.so.$(SOVERSION) ++LIB = libtabixpp.a ++SOVERSION = 0 +SLIB = libtabixpp.so.$(SOVERSION) OBJS = tabix.o SUBDIRS = . From 00fcaab751f3cbd716af2205496a57b7208c842f Mon Sep 17 00:00:00 2001 From: mencian Date: Tue, 26 Mar 2024 01:08:55 -0500 Subject: [PATCH 2/3] try without patch --- recipes/tabixpp/meta.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/tabixpp/meta.yaml b/recipes/tabixpp/meta.yaml index ad291806e5cba..d246907503cbb 100644 --- a/recipes/tabixpp/meta.yaml +++ b/recipes/tabixpp/meta.yaml @@ -12,7 +12,7 @@ source: patches: - shared_lib.patch - pkg-config.patch # [osx] - - arm_hwcap.patch # [aarch64] + #- arm_hwcap.patch # [aarch64] - url: https://github.com/samtools/htslib/releases/download/1.19.1/htslib-1.19.1.tar.bz2 sha256: 222d74d3574fb67b158c6988c980eeaaba8a0656f5e4ffb76b5fa57f035933ec folder: htslib From d169d11fefd8efb2468f0668106f13d17f318cfd Mon Sep 17 00:00:00 2001 From: mencian Date: Tue, 26 Mar 2024 01:17:57 -0500 Subject: [PATCH 3/3] try without patch 2 --- recipes/tabixpp/arm_hwcap.patch | 15 --------------- recipes/tabixpp/meta.yaml | 1 - 2 files changed, 16 deletions(-) delete mode 100644 recipes/tabixpp/arm_hwcap.patch diff --git a/recipes/tabixpp/arm_hwcap.patch b/recipes/tabixpp/arm_hwcap.patch deleted file mode 100644 index 873d6ae4b9850..0000000000000 --- a/recipes/tabixpp/arm_hwcap.patch +++ /dev/null @@ -1,15 +0,0 @@ -Conda-forge's build environment on ARM uses sysroot_linux-aarch64 2.17, which -is based on glibc 2.17 so does not define HWCAP_* values on ARM. -Work around this by including the kernel header to get the desired values. - ---- a/htslib/htscodecs/htscodecs/rANS_static4x16pr.c 2023-10-10 02:54:16 -+++ b/htslib/htscodecs/htscodecs/rANS_static4x16pr.c 2024-03-06 00:01:14 -@@ -1030,6 +1030,8 @@ - - #if defined(__linux__) || defined(__FreeBSD__) - #include -+// Ensure ARM HWCAP_* values are defined even on old glibc -+#include - #elif defined(_WIN32) - #include - #endif diff --git a/recipes/tabixpp/meta.yaml b/recipes/tabixpp/meta.yaml index d246907503cbb..b8f8488b7f72c 100644 --- a/recipes/tabixpp/meta.yaml +++ b/recipes/tabixpp/meta.yaml @@ -12,7 +12,6 @@ source: patches: - shared_lib.patch - pkg-config.patch # [osx] - #- arm_hwcap.patch # [aarch64] - url: https://github.com/samtools/htslib/releases/download/1.19.1/htslib-1.19.1.tar.bz2 sha256: 222d74d3574fb67b158c6988c980eeaaba8a0656f5e4ffb76b5fa57f035933ec folder: htslib