Skip to content

Commit

Permalink
Merge branch 'master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
ryneches authored Dec 23, 2024
2 parents ec03bd6 + 52d6804 commit e17ab58
Show file tree
Hide file tree
Showing 6 changed files with 114 additions and 23 deletions.
17 changes: 9 additions & 8 deletions recipes/rdeval/Makefile.patch
Original file line number Diff line number Diff line change
@@ -1,24 +1,25 @@
diff --git a/Makefile b/Makefile
index 7ec8f12..d81d842 100644
--- a/Makefile
+++ b/Makefile
@@ -12,7 +12,12 @@
@@ -12,7 +12,11 @@ SOURCE = src
INCLUDE = include
BINDIR := $(BUILD)/.o

-LDFLAGS := -pthread
-LDFLAGS += -pthread
+ifeq ($(origin LDFLAGS), undefined)
+ LDFLAGS := -pthread
+ LDFLAGS := -pthread
+else
+ LDFLAGS := $(LDFLAGS) -pthread
+ LDFLAGS := $(LDFLAGS) -pthread
+endif
+
LIBS = -lz
LIBS = -lz -lcrypto -lhts

OBJS := main input reads
@@ -27,7 +32,7 @@
@@ -27,7 +31,7 @@ head: $(BINS) gfalibs | $(BUILD)
all: head validate regenerate

$(BINDIR)%: $(SOURCE)/%.cpp $(INCLUDE)/%.h | $(BINDIR)
- $(CXX) $(CXXFLAGS) $(LDFLAGS) -c $(SOURCE)/$(notdir $@).cpp -o $@
- $(CXX) $(CXXFLAGS) -c $(SOURCE)/$(notdir $@).cpp -o $@
+ $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -c $(SOURCE)/$(notdir $@).cpp -o $@

.PHONY: gfalibs
Expand Down
10 changes: 5 additions & 5 deletions recipes/rdeval/build.sh
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
#!/usr/bin/env bash
#!/usr/bin/bash

set -o errexit
set -o nounset

if [ -e "$PREFIX/include" ]; then
export CPPFLAGS="${CPPFLAGS:+$CPPFLAGS }-I$PREFIX/include"
export CPPFLAGS="${CPPFLAGS:+$CPPFLAGS }-I${PREFIX}/include"
fi

if [ -e "$PREFIX/lib" ]; then
export LDFLAGS="${LDFLAGS:+$LDFLAGS }-L$PREFIX/lib"
export LDFLAGS="${LDFLAGS:+$LDFLAGS }-L${PREFIX}/lib"
fi

echo "CPPFLAGS=\"$CPPFLAGS\""
echo "LDFLAGS=\"$LDFLAGS\""

cd "$SRC_DIR"

make
make CXX="${CXX}" CPPFLAGS="${CPPFLAGS}" -j"${CPU_COUNT}"

install -d "$PREFIX/bin"
install -v -m 0755 build/bin/rdeval "$PREFIX/bin/"
install -v -m 0755 build/bin/rdeval "$PREFIX/bin"
15 changes: 8 additions & 7 deletions recipes/rdeval/gfalibs-Makefile.patch
Original file line number Diff line number Diff line change
@@ -1,24 +1,25 @@
diff --git a/gfalibs/Makefile b/gfalibs/Makefile
index 3c2f269..c71a817 100644
--- a/gfalibs/Makefile
+++ b/gfalibs/Makefile
@@ -1,4 +1,4 @@
-CXX = g++
+CXX ?= g++
INCLUDE_DIR = -I./include
-CXX ?= g++
+CXX ?= $(CXX)
INCLUDE_DIR += -I./include
WARNINGS = -Wall -Wextra

@@ -8,15 +8,13 @@
@@ -8,14 +8,13 @@ TARGET = gfalibs
BUILD = build/bin
SOURCE = src
INCLUDE = include
-LDFLAGS :=
-LDFLAGS =

SOURCES = $(addsuffix .o, input-filters input-gfa input-agp gfa gfa-lines log stream-obj uid-generator struct output memory)

all: $(SOURCES)
- @

%.o: $(SOURCE)/%.cpp $(INCLUDE)/%.h
- $(CXX) $(CXXFLAGS) $(LDFLAGS) -c $(SOURCE)/$(basename $@).cpp -o $@
- $(CXX) $(CXXFLAGS) -c $(SOURCE)/$(basename $@).cpp -o $@
+ $(CXX) $(CPPFLAGS) $(CXXFLAGS) -c $(SOURCE)/$(basename $@).cpp -o $@

clean:
Expand Down
11 changes: 8 additions & 3 deletions recipes/rdeval/meta.yaml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
{% set name = "rdeval" %}
{% set version = "0.0.2" %}
{% set version = "0.0.3" %}

package:
name: {{ name|lower }}
version: {{ version }}

source:
url: https://github.com/vgl-hub/{{ name }}/releases/download/v{{ version }}/{{ name }}.v{{ version }}-with_submodules.zip
sha256: 56c2f4d7d2c22b27d1b380dc41b81cc77a2d97c792a69b9360bed9e0027bac4d
sha256: bd8fd59c98aed5fdbb8930207c3ecd9351f6345c26495e762bcc3c274fdba701
patches:
- Makefile.patch
- gfalibs-Makefile.patch

build:
number: 1
number: 0
run_exports:
- {{ pin_subpackage(name|lower, max_pin="x.x") }}

Expand All @@ -23,6 +23,11 @@ requirements:
- make
host:
- zlib
- htslib
- openssl
run:
- htslib
- openssl

test:
commands:
Expand Down
63 changes: 63 additions & 0 deletions recipes/stripepy-hic/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{% set name = "stripepy-hic" %}
{% set version = "0.0.2" %}
{% set sha256 = "4e0e14f365334095b9af04874b01bae25fb385560add5f6f0bc91b35f757e556" %}

package:
name: {{ name|lower }}
version: {{ version }}

source:
url: https://pypi.org/packages/source/{{ name[0] }}/{{ name|replace("-", "_") }}/{{ name|replace("-", "_") }}-{{ version }}.tar.gz
sha256: {{ sha256 }}

build:
number: 0
noarch: python
entry_points:
- stripepy = stripepy:main
script: "{{ PYTHON }} -m pip install . --no-deps --no-build-isolation --no-cache-dir -v"
run_exports:
- {{ pin_subpackage('stripepy-hic', max_pin="x.x") }}

requirements:
host:
- python >=3.9
- pip
- hatchling
- hatch-vcs
run:
- h5py >=3
- hictkpy >=1
- matplotlib-base >=3.8
- numpy
- pandas >=2
- scikit-learn
- scipy
- seaborn-base >=0.13

about:
home: https://github.com/paulsengroup/StripePy
license: MIT
license_file: LICENCE
summary: "StripePy recognizes architectural stripes in 3C and Hi-C contact maps using geometric reasoning"
dev_url: https://github.com/paulsengroup/StripePy
doc_url: https://github.com/paulsengroup/StripePy/blob/main/README.md

test:
requires:
- curl
- perl-digest-md5
- pytest>=8
source_files:
- test/*
imports:
- stripepy

extra:
recipe-maintainers:
- robomics
- rea1991
- jonnings
identifiers:
- biotools:stripepy-hic
- doi:10.5281/zenodo.14394041
21 changes: 21 additions & 0 deletions recipes/stripepy-hic/run_test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#!/usr/bin/env bash

# Download test datasets
mkdir -p test/data

curl -L 'https://zenodo.org/records/14517632/files/4DNFI9GMP2J8.stripepy.mcool?download=1' -o test/data/4DNFI9GMP2J8.mcool
curl -L 'https://zenodo.org/records/14517632/files/results_4DNFI9GMP2J8_v1.hdf5?download=1' -o test/data/results_4DNFI9GMP2J8_v1.hdf5

# Checksum datasets
echo 'a17d08460c03cf6c926e2ca5743e4888 test/data/4DNFI9GMP2J8.mcool' > checksums.md5
echo '632b2a7a6e5c1a24dc3635710ed68a80 test/data/results_4DNFI9GMP2J8_v1.hdf5' >> checksums.md5

md5sum -c checksums.md5

# Test CLI
stripepy --help
stripepy --version

# Run automated test suites
"$PYTHON" -m pytest test/ -m unit -v --disable-pytest-warnings
"$PYTHON" -m pytest test/ -m end2end -v -k 'not TestStripePyPlot' --disable-pytest-warnings

0 comments on commit e17ab58

Please sign in to comment.