-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Update MuSE to latest version 2.1.2 #47957
Changes from 59 commits
11090fb
6d2a823
9b4cc4e
6189439
9b2c8c5
ab2ea3c
dd152fc
7c22a5a
24c8d84
005da74
43e5765
faed9ee
90c8fe7
f2c34e2
1fff731
b198426
270d380
d8275f2
2642da4
6528cdb
4058487
76e412b
45b67d1
d760694
5ec8d6a
3341442
8809c31
83a67ba
814f2fa
d64ce4d
346ec67
3429aba
395ae1e
4288a47
616b803
1cca06d
ff5873d
2fe616f
0f0d10d
42a117f
e72f4b0
08043ca
20e095d
fd536d8
9623596
f1fca89
dc3128c
14b77cb
13835f6
60b0bcd
bb774d8
e73c5fd
f511250
4539c4f
bdead6d
f4e359f
1cb5cfb
894b3f5
e7a4f93
54bfcb9
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
diff --git a/Makefile b/Makefile | ||
index 5edd6e1..78d946c 100755 | ||
--- a/Makefile | ||
+++ b/Makefile | ||
@@ -1,6 +1,6 @@ | ||
-CPP := g++ | ||
-CC := gcc | ||
-LINK := g++ | ||
+CPP := ${CXX} | ||
+CC := ${CC} | ||
+LINK := ${CXX} | ||
mkfile_dir := $(dir $(abspath $(lastword $(MAKEFILE_LIST)))) | ||
|
||
CSOURCES= $(wildcard src/*.c) | ||
@@ -11,12 +11,12 @@ COMMONOBJS= lib/libhts.a lib/libboost_iostreams.a lib/libtcmalloc_minimal.a | ||
Warnings=-Wreturn-type -Warray-bounds -Wmaybe-uninitialized -Waddress | ||
WarningsAsErrors=$(Warnings) -Werror=return-type -Werror=array-bounds -Werror=address | ||
CFLAGS= $(WarningsAsErrors) -Wno-unused-function | ||
-CPPFLAGS= $(WarningsAsErrors) -Wno-unused-function -std=c++11 | ||
+CPPFLAGS= $(WarningsAsErrors) -Wno-unused-function -std=c++14 | ||
|
||
RELEASE_FLAGS= -O3 -g | ||
|
||
# Includes | ||
-INCLUDES = -Iinc/ | ||
+INCLUDES += -Iinc/ -Iinc/htslib -I$(PREFIX)/include | ||
# | ||
# Common flags | ||
COMMONFLAGS += $(INCLUDES) | ||
@@ -24,7 +24,7 @@ COMMONFLAGS += $(INCLUDES) | ||
CXXFLAGS += $(COMMONFLAGS) | ||
CFLAGS += $(COMMONFLAGS) | ||
CPPFLAGS += $(COMMONFLAGS) | ||
-COMMONLIBS= -Llib/ -lz -lm -lpthread -lbz2 -lcurl -lcrypto -llzma -fopenmp | ||
+COMMONLIBS += -Llib/ -lz -lm -lpthread -lbz2 -lcurl -lcrypto -llzma -lhts -ldl -fopenmp -L${PREFIX}/lib | ||
|
||
#LIBS += $(COMMONLIBS) -ltcmalloc | ||
LIBS += $(COMMONLIBS) | ||
@@ -38,10 +38,10 @@ all: $(TARGET) | ||
.SUFFIXES: .c .cpp .o | ||
|
||
%.c.o: %.c | ||
- $(CC) $(CFLAGS) $(RELEASE_FLAGS) -c $< -o $@ | ||
+ $(CC) $(CFLAGS) $(RELEASE_FLAGS) $(INCLUDES) $(LIBS) -c $< -o $@ | ||
|
||
%.cpp.o: %.cpp | ||
- $(CPP) $(CPPFLAGS) $(RELEASE_FLAGS) $(OPENMP) -c $< -o $@ | ||
+ $(CPP) $(CPPFLAGS) $(RELEASE_FLAGS) $(OPENMP) $(INCLUDES) $(LIBS) -c $< -o $@ | ||
|
||
$(TARGET): $(OBJS) Makefile | ||
$(LINKLINE) |
This file was deleted.
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -1,6 +1,29 @@ | ||||||||||||||||||||||||
#!/usr/bin/env bash | ||||||||||||||||||||||||
#!/bin/bash | ||||||||||||||||||||||||
set -euo pipefail | ||||||||||||||||||||||||
|
||||||||||||||||||||||||
make CPP="${CXX}" CPPFLAGS="${CXXFLAGS}" | ||||||||||||||||||||||||
export LIBPATH="-L${PREFIX}/lib" | ||||||||||||||||||||||||
export LDFLAGS="${LDFLAGS} -L${PREFIX}/lib" | ||||||||||||||||||||||||
export CFLAGS="${CFLAGS} -O3" | ||||||||||||||||||||||||
|
||||||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Remove explicit -O3 flag from CFLAGS Conda-build already sets appropriate optimization flags in CFLAGS. Adding -O3 explicitly might override better compiler-specific optimizations. -export CFLAGS="${CFLAGS} -O3" 📝 Committable suggestion
Suggested change
Comment on lines
+4
to
+6
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Optimize environment variable setup
Apply this diff: -export LIBPATH="-L${PREFIX}/lib"
-export LDFLAGS="${LDFLAGS} -L${PREFIX}/lib"
-export CFLAGS="${CFLAGS} -O3"
+export LDFLAGS="${LDFLAGS} -L${PREFIX}/lib" 📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||
mkdir -p "${PREFIX}/bin" | ||||||||||||||||||||||||
cp MuSE "${PREFIX}/bin/" | ||||||||||||||||||||||||
rm -rf boost_1_70_0/ | ||||||||||||||||||||||||
|
||||||||||||||||||||||||
if [[ `uname` == "Darwin" ]]; then | ||||||||||||||||||||||||
ln -sf ${CC} ${PREFIX}/bin/clang | ||||||||||||||||||||||||
ln -sf ${CXX} ${PREFIX}/bin/clang++ | ||||||||||||||||||||||||
else | ||||||||||||||||||||||||
ln -sf ${CC} ${PREFIX}/bin/gcc | ||||||||||||||||||||||||
ln -sf ${CXX} ${PREFIX}/bin/g++ | ||||||||||||||||||||||||
fi | ||||||||||||||||||||||||
|
||||||||||||||||||||||||
Comment on lines
+10
to
+16
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove compiler symlinks - Critical Security Risk Creating compiler symlinks in
Instead of creating symlinks, modify -if [[ `uname` == "Darwin" ]]; then
- ln -sf ${CC} ${PREFIX}/bin/clang
- ln -sf ${CXX} ${PREFIX}/bin/clang++
-else
- ln -sf ${CC} ${PREFIX}/bin/gcc
- ln -sf ${CXX} ${PREFIX}/bin/g++
-fi
|
||||||||||||||||||||||||
./install_muse.sh | ||||||||||||||||||||||||
|
||||||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Add error handling for install script execution The installation script execution needs better error handling and verification. Apply this improvement: -./install_muse.sh
+if [ ! -f "install_muse.sh" ]; then
+ echo "Error: install_muse.sh not found"
+ exit 1
+fi
+
+if [ ! -x "install_muse.sh" ]; then
+ chmod +x install_muse.sh
+fi
+
+./install_muse.sh || exit 1 📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||
if [[ `uname` == "Darwin" ]]; then | ||||||||||||||||||||||||
rm -rf ${PREFIX}/bin/clang | ||||||||||||||||||||||||
rm -rf ${PREFIX}/bin/clang++ | ||||||||||||||||||||||||
else | ||||||||||||||||||||||||
rm -rf ${PREFIX}/bin/gcc | ||||||||||||||||||||||||
rm -rf ${PREFIX}/bin/g++ | ||||||||||||||||||||||||
fi | ||||||||||||||||||||||||
|
||||||||||||||||||||||||
Comment on lines
+20
to
+26
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove symlinks cleanup block This cleanup block should be removed along with the symlinks creation block above. Remove this entire block as it's related to the dangerous practice of creating compiler symlinks: -if [[ `uname` == "Darwin" ]]; then
- rm -rf ${PREFIX}/bin/clang
- rm -rf ${PREFIX}/bin/clang++
-else
- rm -rf ${PREFIX}/bin/gcc
- rm -rf ${PREFIX}/bin/g++
-fi 📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||
install -d "${PREFIX}/bin" | ||||||||||||||||||||||||
install -v -m 0755 MuSE "${PREFIX}/bin" |
Original file line number | Diff line number | Diff line change | ||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,84 @@ | ||||||||||||||||||||
diff --git a/install_muse.sh b/install_muse.sh | ||||||||||||||||||||
index 7bc2153..f8ab6e3 100755 | ||||||||||||||||||||
--- a/install_muse.sh | ||||||||||||||||||||
+++ b/install_muse.sh | ||||||||||||||||||||
@@ -4,13 +4,21 @@ make clean | ||||||||||||||||||||
|
||||||||||||||||||||
mkdir -p lib | ||||||||||||||||||||
|
||||||||||||||||||||
+if [[ `uname` == "Darwin" ]]; then | ||||||||||||||||||||
+ export TOOL=clang | ||||||||||||||||||||
+else | ||||||||||||||||||||
+ export TOOL=gcc | ||||||||||||||||||||
+fi | ||||||||||||||||||||
+ | ||||||||||||||||||||
# compile boost library | ||||||||||||||||||||
-cd boost_1_70_0/ | ||||||||||||||||||||
-./bootstrap.sh | ||||||||||||||||||||
+cd boost-1.86.0/ | ||||||||||||||||||||
+./bootstrap.sh --with-toolset="${TOOL}" --prefix="${PREFIX}" | ||||||||||||||||||||
./b2 --clean | ||||||||||||||||||||
-./b2 | ||||||||||||||||||||
+./b2 toolset="${TOOL}" --layout=system link=static \ | ||||||||||||||||||||
+ threading=multi strip=on include="${PREFIX}/include" \ | ||||||||||||||||||||
+ variant=release address-model=64 install | ||||||||||||||||||||
|
||||||||||||||||||||
-cp stage/lib/libboost_iostreams.a ../lib/ | ||||||||||||||||||||
+cp -f ${PREFIX}/lib/libboost_iostreams.a ../lib/ | ||||||||||||||||||||
cd .. | ||||||||||||||||||||
|
||||||||||||||||||||
# compile libtcmalloc | ||||||||||||||||||||
@@ -22,12 +30,12 @@ fi | ||||||||||||||||||||
|
||||||||||||||||||||
git clone https://github.com/gperftools/gperftools.git | ||||||||||||||||||||
cd gperftools | ||||||||||||||||||||
-git checkout gperftools-2.9.1 | ||||||||||||||||||||
+git checkout gperftools-2.16 | ||||||||||||||||||||
./autogen.sh | ||||||||||||||||||||
-./configure --libdir="$PWD" | ||||||||||||||||||||
-make -j4 | ||||||||||||||||||||
+./configure --libdir="${PWD}" --prefix="${PREFIX}" | ||||||||||||||||||||
+make -j${CPU_COUNT} | ||||||||||||||||||||
make install | ||||||||||||||||||||
-cp libtcmalloc_minimal.a ../lib/ | ||||||||||||||||||||
+cp -f libtcmalloc_minimal.a ../lib/ | ||||||||||||||||||||
cd .. | ||||||||||||||||||||
|
||||||||||||||||||||
# combine htslib | ||||||||||||||||||||
@@ -42,27 +50,15 @@ cd htslib | ||||||||||||||||||||
git checkout 1.9 | ||||||||||||||||||||
#git submodule update --init --recursive | ||||||||||||||||||||
autoreconf -i | ||||||||||||||||||||
-./configure | ||||||||||||||||||||
-make -j4 | ||||||||||||||||||||
-cp libhts.a ../lib/ | ||||||||||||||||||||
+./configure --enable-libcurl --enable-plugins \ | ||||||||||||||||||||
+ LDFLAGS="-L${PREFIX}/lib -Wl,-R${PREFIX}/lib" \ | ||||||||||||||||||||
+ CPPFLAGS="-I${PREFIX}/include" | ||||||||||||||||||||
+make -j${CPU_COUNT} | ||||||||||||||||||||
+cp -f libhts.a ../lib/ | ||||||||||||||||||||
|
||||||||||||||||||||
cd .. | ||||||||||||||||||||
|
||||||||||||||||||||
-make | ||||||||||||||||||||
- | ||||||||||||||||||||
-#clean htslib and gperftools and boost libraries | ||||||||||||||||||||
-rm -r boost_1_70_0/stage | ||||||||||||||||||||
- | ||||||||||||||||||||
-chmod -R 755 gperftools | ||||||||||||||||||||
-rm -r gperftools | ||||||||||||||||||||
- | ||||||||||||||||||||
-chmod -R 755 htslib | ||||||||||||||||||||
-rm -r htslib | ||||||||||||||||||||
- | ||||||||||||||||||||
- | ||||||||||||||||||||
- | ||||||||||||||||||||
- | ||||||||||||||||||||
- | ||||||||||||||||||||
- | ||||||||||||||||||||
- | ||||||||||||||||||||
- | ||||||||||||||||||||
+CFLAGS="${CFLAGS} -O3 ${LDFLAGS}" \ | ||||||||||||||||||||
+ CC="${CC}" CXX="${CXX}" CXXFLAGS="${CXXFLAGS} -O3 -I${PREFIX}/include" \ | ||||||||||||||||||||
+ LDFLAGS="${LDFLAGS} -L${PREFIX}/lib" \ | ||||||||||||||||||||
+ make -j"${CPU_COUNT}" | ||||||||||||||||||||
Comment on lines
+81
to
+84
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Improve compiler flags handling The current approach of setting compiler flags could be improved:
-CFLAGS="${CFLAGS} -O3 ${LDFLAGS}" \
- CC="${CC}" CXX="${CXX}" CXXFLAGS="${CXXFLAGS} -O3 -I${PREFIX}/include" \
- LDFLAGS="${LDFLAGS} -L${PREFIX}/lib" \
- make -j"${CPU_COUNT}"
+CPPFLAGS="-I${PREFIX}/include" \
+ CFLAGS="${CFLAGS}" \
+ CXXFLAGS="${CXXFLAGS}" \
+ LDFLAGS="${LDFLAGS} -L${PREFIX}/lib" \
+ make -j"${CPU_COUNT}" 📝 Committable suggestion
Suggested change
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,60 @@ | ||
{% set name = "MuSE" %} | ||
{% set version = "2.1.2" %} | ||
{% set sha256 = "48df7ec3f64244400243163b48eb658105854b7b0d6287af98242dd89f396f59" %} | ||
|
||
package: | ||
name: muse | ||
version: 1.0.rc | ||
name: {{ name|lower }} | ||
version: {{ version }} | ||
|
||
source: | ||
md5: c63fdb48c041f6f9545879f1a7e4da58 | ||
url: https://github.com/danielfan/MuSE/archive/v1.0-rc.tar.gz | ||
- url: https://github.com/wwylab/MuSE/archive/refs/tags/v{{ version }}.tar.gz | ||
sha256: {{ sha256 }} | ||
patches: | ||
- 0001-add-LDFLAGS.patch | ||
- 0001-Makefile.patch | ||
- fix-install_muse.sh.patch | ||
- url: https://github.com/boostorg/boost/releases/download/boost-1.86.0/boost-1.86.0-b2-nodocs.tar.gz | ||
sha256: 2128a4c96862b5c0970c1e34d76b1d57e4a1016b80df85ad39667f30b1deba26 | ||
folder: boost-1.86.0 | ||
Comment on lines
+15
to
+17
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion Consider using conda-forge's boost package. Including Boost source directly in the recipe is unusual. Conda-forge provides pre-built Boost packages that are better maintained and tested. Consider using - - url: https://github.com/boostorg/boost/releases/download/boost-1.86.0/boost-1.86.0-b2-nodocs.tar.gz
- sha256: 2128a4c96862b5c0970c1e34d76b1d57e4a1016b80df85ad39667f30b1deba26
- folder: boost-1.86.0 Then add to host requirements: host:
- boost-cpp |
||
|
||
build: | ||
number: 8 | ||
number: 0 | ||
run_exports: | ||
- {{ pin_subpackage('muse', max_pin="x") }} | ||
|
||
requirements: | ||
build: | ||
- make | ||
- {{ compiler('cxx') }} | ||
- {{ compiler('c') }} | ||
- make | ||
- autoconf | ||
- automake | ||
- libtool | ||
host: | ||
- llvm-openmp # [osx] | ||
- libgomp # [linux] | ||
- libcurl | ||
- icu | ||
- bzip2 | ||
- xz | ||
- zlib | ||
run: | ||
- zlib | ||
- llvm-openmp # [osx] | ||
- libgomp # [linux] | ||
|
||
test: | ||
commands: | ||
- MuSE 2>&1 | grep Version > /dev/null | ||
- "MuSE 2>&1 | grep Version > /dev/null" | ||
famosab marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
about: | ||
home: "http://bioinformatics.mdanderson.org/main/MuSE" | ||
license: "https://github.com/danielfan/MuSE/blob/master/LICENSE" | ||
summary: Somatic point mutation caller | ||
home: "https://github.com/wwylab/MuSE" | ||
license: "GPL-2.0-or-later" | ||
license_family: GPL | ||
license_file: "LICENSE" | ||
summary: "An accurate and ultra-fast somatic point mutation calling tool for whole-genome sequencing (WGS) and whole-exome sequencing (WES) data from heterogeneous tumor samples." | ||
doc_url: "https://bioinformatics.mdanderson.org/public-software/muse" | ||
dev_url: "https://github.com/wwylab/MuSE" | ||
|
||
extra: | ||
identifiers: | ||
- doi:10.1101/gr.278456.123 | ||
- doi:10.1186/s13059-016-1029-6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codebase verification
C++14 compatibility issues detected with dependencies.
recipes/muse/meta.yaml
specifieslibdeflate
which may require C++11.🔗 Analysis chain
Verify C++14 compatibility with dependencies.
The upgrade from C++11 to C++14 standard might affect compatibility. Please ensure:
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 1825