Skip to content

Commit cf98b47

Browse files
Fix yara_installer script.
1 parent 3453685 commit cf98b47

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

extra/yara_installer.sh

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,10 @@ if [ ! -d /tmp/yara-python ]; then
88
git clone --recursive https://github.com/VirusTotal/yara-python /tmp/yara-python
99
fi
1010

11-
cd /tmp/yara-python
11+
/etc/poetry/bin/poetry --directory /opt/CAPEv2 run bash -c "cd /tmp/yara-python && python setup.py build --enable-cuckoo --enable-magic --enable-profiling"
12+
/etc/poetry/bin/poetry --directory /opt/CAPEv2 run pip install /tmp/yara-python
1213

13-
/etc/poetry/bin/poetry --directory /opt/CAPEv2 run python setup.py build --enable-cuckoo --enable-magic --enable-profiling
14-
/etc/poetry/bin/poetry --directory /opt/CAPEv2 run pip install .
15-
16-
cd ..
14+
cd /tmp
1715

1816
if [ -d yara-python ]; then
1917
rm -rf yara-python

installer/cape2.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -797,7 +797,7 @@ function install_yara() {
797797
ldconfig
798798

799799
# Run yara installer script
800-
sudo -u ${USER} /etc/poetry/bin/poetry --directory /opt/CAPEv2 run /opt/CAPEv2/extra/yara_installer.sh
800+
sudo -u ${USER} /etc/poetry/bin/poetry --directory /opt/CAPEv2 run extra/yara_installer.sh
801801

802802
if [ -d yara-python ]; then
803803
sudo rm -rf yara-python
@@ -944,7 +944,7 @@ function install_capa() {
944944
cd capa || return
945945
git pull
946946
git submodule update --init rules
947-
/etc/poetry/bin/poetry --directory /opt/CAPEv2/ run pip install .
947+
/etc/poetry/bin/poetry --directory /opt/CAPEv2/ run pip install /tmp/capa
948948
cd /opt/CAPEv2
949949
if [ -d /tmp/capa ]; then
950950
sudo rm -rf /tmp/capa

0 commit comments

Comments
 (0)