-
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
Add fc-virus recipe #51809
Add fc-virus recipe #51809
Changes from 93 commits
db3ebff
c20772a
ad5d462
d9334e8
866bd6d
7d96345
3b56d0a
f67d05d
61ec829
b352495
5d49397
0d75e3c
06eaf2c
8d16ee8
03bdc68
f59f4d6
4f22236
f0221ce
0702de8
6bfc2de
5a3ae05
4988cb6
1f36454
ba5d11c
a1fbb60
77591fd
42458eb
c2a00b2
a6d9c66
ae33bdf
a22c1af
e3b9980
ca92f27
0120428
b3e9d8c
ea1e01b
31e40f2
358b44b
c909cf3
a1989ad
6ff3724
3a5eb28
59b2cdb
ed5e09d
91a74db
a318fd1
db2059a
ba636e5
b11df75
f92b076
1f4eaa3
a60ea99
04eb82e
8d18bfd
ff8e46a
91d9f88
65ce000
f7f92a5
a38e6f8
b661b76
84eb3fb
00c72f9
a9daef5
59d3665
2e8cc38
2fcf51b
a275ac6
b522818
b9e02ce
d9213cb
a4350ac
46dd88d
8a6c033
21de2d8
232bc3b
aee3e16
7939059
21985ed
cc7293d
0ee8123
9dbc37e
ec35aad
682295a
fee1416
18bd208
3554a1e
46747b9
017db5e
36ddabb
c3d253a
98be845
2e649ba
4ac072e
39cc7cc
e56f76e
7591000
ed5726a
4fe08da
92e300d
e76937f
b27aaea
8751de1
fc41516
728593e
f2d34b3
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,21 @@ | ||
MIT License | ||
|
||
Copyright (c) [2022] [Runpeng Luo] | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in all | ||
copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
SOFTWARE. |
Original file line number | Diff line number | Diff line change | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,8 @@ | ||||||||||||||||||
|
||||||||||||||||||
#!/bin/bash | ||||||||||||||||||
set -xe | ||||||||||||||||||
make CXX="${CXX}" INCLUDES="-I$PREFIX/include" CFLAGS+="-g -Wall -O2 -L$PREFIX/lib" | ||||||||||||||||||
#chmod +x ./bin/fc-virus | ||||||||||||||||||
chmod 777 ./bin/fc-virus | ||||||||||||||||||
Comment on lines
+4
to
+5
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. Security: Fix overly permissive file permissions Using chmod 777 grants read/write/execute permissions to all users, which is a security risk. The executable only needs to be executable by users (755). -#chmod +x ./bin/fc-virus
-chmod 777 ./bin/fc-virus
+chmod 755 ./bin/fc-virus 📝 Committable suggestion
Suggested change
|
||||||||||||||||||
mkdir -p ${PREFIX}/bin | ||||||||||||||||||
cp -f ./bin/fc-virus ${PREFIX}/bin | ||||||||||||||||||
Comment on lines
+6
to
+7
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 installation steps The installation commands should:
-mkdir -p ${PREFIX}/bin
-cp -f ./bin/fc-virus ${PREFIX}/bin
+if [ ! -f ./bin/fc-virus ]; then
+ echo "Error: fc-virus binary not found" >&2
+ exit 1
+fi
+mkdir -p "${PREFIX}/bin" || exit 1
+install -v -m 755 ./bin/fc-virus "${PREFIX}/bin/" || exit 1 📝 Committable suggestion
Suggested change
|
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,39 @@ | ||||||||||||||||||||||||||||||||
{% set name = "fc-virus" %} | ||||||||||||||||||||||||||||||||
{% set version = "1.0.1" %} | ||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
package: | ||||||||||||||||||||||||||||||||
name: "fc" | ||||||||||||||||||||||||||||||||
version: {{ version }} | ||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
source: | ||||||||||||||||||||||||||||||||
url: "https://github.com/qdu-bioinfo/{{ name }}/archive/refs/tags/v{{ version }}.tar.gz" | ||||||||||||||||||||||||||||||||
sha256: "6545124184e7ac743ff8149e97a0972230dad4f458248d2cad088e329e91b836" | ||||||||||||||||||||||||||||||||
build: | ||||||||||||||||||||||||||||||||
number: 0 | ||||||||||||||||||||||||||||||||
skip: true | ||||||||||||||||||||||||||||||||
run_exports: | ||||||||||||||||||||||||||||||||
- {{ pin_subpackage("fc", max_pin="x") }} | ||||||||||||||||||||||||||||||||
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 redundant skip directive The build:
number: 0
- skip: true
run_exports:
- {{ pin_subpackage("fc", max_pin="x") }} 📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
requirements: | ||||||||||||||||||||||||||||||||
build: | ||||||||||||||||||||||||||||||||
- make | ||||||||||||||||||||||||||||||||
- {{ compiler('c') }} | ||||||||||||||||||||||||||||||||
host: | ||||||||||||||||||||||||||||||||
- zlib | ||||||||||||||||||||||||||||||||
- boost | ||||||||||||||||||||||||||||||||
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. Add C++ compiler requirement Since the package depends on boost, which is a C++ library, you should add the C++ compiler to the build requirements. build:
- make
- {{ compiler('c') }}
+ - {{ compiler('cxx') }} 📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
test: | ||||||||||||||||||||||||||||||||
commands: | ||||||||||||||||||||||||||||||||
- ./bin/fc-virus --help | ||||||||||||||||||||||||||||||||
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. Fix test command path. The current test command uses a relative path Apply this fix: test:
commands:
- - ./bin/fc-virus --help
+ - fc-virus --help 📝 Committable suggestion
Suggested change
|
||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
about: | ||||||||||||||||||||||||||||||||
home: "https://github.com/qdu-bioinfo/fc-virus" | ||||||||||||||||||||||||||||||||
license: MIT | ||||||||||||||||||||||||||||||||
license_family: MIT | ||||||||||||||||||||||||||||||||
license_file: LICENSE | ||||||||||||||||||||||||||||||||
summary: "Accurate Assembly of Full-length Consensus for Viral Quasispecies" | ||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
skip: | ||||||||||||||||||||||||||||||||
- osx-64 | ||||||||||||||||||||||||||||||||
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. Move skip configuration to build section The skip configuration should be under the build section, not at the root level. build:
number: 0
run_exports:
- {{ pin_subpackage("fc", max_pin="x") }}
+ skip:
+ - osx-64
-skip:
- - osx-64 📝 Committable suggestion
Suggested change
|
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.
Fix shebang line position
The shebang must be on the first line of the script. Remove the blank line 1.
📝 Committable suggestion
🧰 Tools
🪛 Shellcheck
[error] 2-2: The shebang must be on the first line. Delete blanks and move comments.
(SC1128)