diff options
author | hexcoder <hexcoder-@users.noreply.github.com> | 2020-05-14 20:30:00 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-14 20:30:00 +0200 |
commit | a3392007cd7cac492e746e0e7d989355d9ae21dd (patch) | |
tree | 03583a77685fd7bbd3bfca98d8d4bacb8cd59863 | |
parent | 4ac06a4eef8462057f2358e3dddd108d4fbaf2dd (diff) | |
download | afl++-a3392007cd7cac492e746e0e7d989355d9ae21dd.tar.gz |
next try
-rwxr-xr-x | unicorn_mode/build_unicorn_support.sh | 24 |
1 files changed, 8 insertions, 16 deletions
diff --git a/unicorn_mode/build_unicorn_support.sh b/unicorn_mode/build_unicorn_support.sh index b244c29f..a5b2b274 100755 --- a/unicorn_mode/build_unicorn_support.sh +++ b/unicorn_mode/build_unicorn_support.sh @@ -106,28 +106,20 @@ for i in $PYTHONBIN automake autoconf git $MAKECMD $TARCMD; do fi done -set -x -ls -lRa /opt/pyenv -ls -lRa ~/.local + # some python version should be available now PYTHONS="`command -v python3` `command -v python` `command -v python2`" EASY_INSTALL_FOUND=0 for PYTHON in $PYTHONS ; do - # work around for installs with executable easy_install - MYPYTHONPATH=`${PYTHON} -v </dev/null 2>&1 >/dev/null | sed -n -e '/^# \/.*\/os.py/{ s/.*matches //; s/os.py$//; p;}'` - for PATHCANDIDATE in \ - "dist-packages/" \ - "site-packages/" - do - if [ -e "${MYPYTHONPATH}/${PATHCANDIDATE}/easy_install.py" ] ; then + # slow, but should work + if $PYTHON -c "help('modules');" 2>/dev/null | grep -q easy_install ; then - EASY_INSTALL_FOUND=1 - PYTHONBIN=$PYTHON - break + EASY_INSTALL_FOUND=1 + PYTHONBIN=$PYTHON + break - fi - done + fi done if [ "0" = $EASY_INSTALL_FOUND ]; then @@ -136,7 +128,7 @@ if [ "0" = $EASY_INSTALL_FOUND ]; then PREREQ_NOTFOUND=1 fi -set +x + if echo "$CC" | grep -qF /afl-; then echo "[-] Error: do not use afl-gcc or afl-clang to compile this tool." |