diff options
author | vejnar | 2023-05-16 21:01:49 -0400 |
---|---|---|
committer | vejnar | 2023-05-16 21:01:49 -0400 |
commit | e56ec6d8ff511e641a49924926c1595034345376 (patch) | |
tree | 2c1a77dd711039fd18b60cad3f9ec8712d85447e | |
download | aur-bwa-mem2.tar.gz |
Initial upload: bwa-mem2 2.2.1-1
Add bwa-mem2
-rw-r--r-- | .SRCINFO | 14 | ||||
-rw-r--r-- | PKGBUILD | 47 | ||||
-rw-r--r-- | gcc_rdtsc.patch | 13 |
3 files changed, 74 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..a3482dc81096 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,14 @@ +pkgbase = bwa-mem2 + pkgdesc = The next version of Burrows-Wheeler Aligner MEM algorithm + pkgver = 2.2.1 + pkgrel = 1 + url = https://github.com/bwa-mem2/bwa-mem2 + arch = x86_64 + license = MIT + depends = zlib + source = bwa-mem2-2.2.1.tar.gz::https://github.com/bwa-mem2/bwa-mem2/releases/download/v2.2.1/Source_code_including_submodules.tar.gz + source = gcc_rdtsc.patch + sha256sums = 9b001bdc7666ee3f14f3698b21673714d429af50438b894313b05bc4688b1f6d + sha256sums = 50556ad538edb98bbdcaae4338dc42873e6aae27ab7ab4a090cd0442818072f9 + +pkgname = bwa-mem2 diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..c01d7004fc29 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,47 @@ +# Maintainer: Charles Vejnar <first name [dot] last name [at] gmail [dot] com> +# Contributor: Maƫl Kerbiriou <m431.kerbiriou@gmail.com> + +pkgname=bwa-mem2 +pkgver=2.2.1 +pkgrel=1 +pkgdesc="The next version of Burrows-Wheeler Aligner MEM algorithm" +arch=("x86_64") +url="https://github.com/bwa-mem2/bwa-mem2" +license=("MIT") +depends=('zlib') +source=("$pkgname-$pkgver.tar.gz::https://github.com/bwa-mem2/bwa-mem2/releases/download/v${pkgver}/Source_code_including_submodules.tar.gz" + "gcc_rdtsc.patch") +sha256sums=('9b001bdc7666ee3f14f3698b21673714d429af50438b894313b05bc4688b1f6d' + '50556ad538edb98bbdcaae4338dc42873e6aae27ab7ab4a090cd0442818072f9') + +# For compiling for native instruction set only, set this to false: +MULTI=${MULTI:-true} + +prepare() { + cd "$srcdir/$pkgname-${pkgver}" + + patch -p1 -i "${srcdir}/gcc_rdtsc.patch" +} + +build() { + cd "$srcdir/$pkgname-${pkgver}" + + if [ "$MULTI" = true ] ; then + make multi + else + make arch=native + fi +} + +package() { + cd "$srcdir/$pkgname-${pkgver}" + + install -Dm755 bwa-mem2 "$pkgdir/usr/bin/bwa-mem2" + install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE" + + if [ "$MULTI" = true ] ; then + install -Dm755 bwa-mem2.avx2 "$pkgdir/usr/bin/bwa-mem2.avx2" + install -Dm755 bwa-mem2.avx512bw "$pkgdir/usr/bin/bwa-mem2.avx512bw" + install -Dm755 bwa-mem2.sse41 "$pkgdir/usr/bin/bwa-mem2.sse41" + fi +} diff --git a/gcc_rdtsc.patch b/gcc_rdtsc.patch new file mode 100644 index 000000000000..411da804d008 --- /dev/null +++ b/gcc_rdtsc.patch @@ -0,0 +1,13 @@ +diff --git a/src/utils.h b/src/utils.h +index 54a062a..e3037a3 100644 +--- a/src/utils.h ++++ b/src/utils.h +@@ -48,7 +48,7 @@ + + #define xassert(cond, msg) if ((cond) == 0) _err_fatal_simple_core(__func__, msg) + +-#if defined(__GNUC__) && !defined(__clang__) ++#if defined(__GNUC__) && __GNUC__ < 11 && !defined(__clang__) + #if defined(__i386__) + static inline unsigned long long __rdtsc(void) + { |