Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a recipe for PopIns2 #52782

Merged
merged 2 commits into from
Dec 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions recipes/popins2/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/env bash

set -xe

# no need to build SeqAn's documentation/demos
rm -rf external/seqan-library-2.2.0/share/doc/seqan/

mkdir build

CXX="${CXX} -std=c++14" make -j"${CPU_COUNT}"

mkdir -p ${PREFIX}/bin
install -m 755 popins2 ${PREFIX}/bin
51 changes: 51 additions & 0 deletions recipes/popins2/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{% set name = "popins2" %}
{% set version = "0.13.0" %}

package:
name: {{ name }}
version: {{ version }}

build:
skip: True # [osx]
number: 0
run_exports:
- {{ pin_subpackage(name, max_pin='x.x') }}

source:
git_url: https://github.com/kehrlab/PopIns2
git_rev: v{{ version }}
patches:
- popins2.patch

requirements:
build:
- make
- {{ compiler('cxx') }}
host:
- bifrost
- bwa
- htslib
- samtools
- sickle-trim
- zlib
run:
- bifrost

test:
commands:
- popins2 --help 2>&1 | grep {{ version }}

about:
home: https://github.com/kehrlab/PopIns2
license: GPL-2.0-only
license_family: GPL
license_file: LICENSE
summary: Population-scale detection of non-reference sequence variants using colored de Bruijn Graphs
doc_url: https://github.com/kehrlab/PopIns2

extra:
additional-platforms:
- linux-aarch64
skip-lints:
- missing_hash
- uses_vcs_url
34 changes: 34 additions & 0 deletions recipes/popins2/popins2.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
diff --git i/Makefile w/Makefile
index de28bc8..613fa79 100644
--- i/Makefile
+++ w/Makefile
@@ -6,7 +6,7 @@ SRCS := $(shell find $(SRC_DIR) -type f -name *.cpp)
OBJS := $(patsubst $(SRC_DIR)/%,$(BUILD_DIR)/%,$(SRCS:.cpp=.o))

# Compiler
-CXX = g++ -std=c++14
+CXX ?= g++ -std=c++14
CC = $(CXX)

# SeqAn
@@ -29,7 +29,7 @@ CXXFLAGS += -march=native -DMAX_KMER_SIZE=64
CXXFLAGS += -I$(SEQAN_LIB)

# Linker flags
-LDLIBS = -lbifrost -pthread -lz -rdynamic -DMAX_KMER_SIZE=64
+LDLIBS = -L"${PREFIX}/lib" -lbifrost -pthread -lz -rdynamic -DMAX_KMER_SIZE=64
# MacOS users might have to comment out the next line
LDLIBS += -lrt

diff --git i/src/Traceback.h w/src/Traceback.h
index 745db68..6323e80 100644
--- i/src/Traceback.h
+++ w/src/Traceback.h
@@ -6,6 +6,7 @@
#ifndef TRACEBACK_
#define TRACEBACK_

+#include <cstdint>
#include <iostream>
#include <fstream>

Loading