Skip to content

Commit

Permalink
py scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
doegox committed Nov 13, 2020
1 parent 39a20b6 commit 923d294
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 13 deletions.
1 change: 1 addition & 0 deletions client/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -684,6 +684,7 @@ endif
ifneq (,$(INSTALLSHARE))
$(Q)$(MKDIR) $(DESTDIR)$(PREFIX)$(PATHSEP)$(INSTALLSHARERELPATH)
$(Q)$(CP) $(INSTALLSHARE) $(DESTDIR)$(PREFIX)$(PATHSEP)$(INSTALLSHARERELPATH)
$(Q)$(CP) src/pm3.py $(DESTDIR)$(PREFIX)$(PATHSEP)$(INSTALLSHARERELPATH)/pyscripts
endif
@true

Expand Down
6 changes: 1 addition & 5 deletions client/experimental_client_with_swig/02b_run_test_py.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
#!/bin/bash

#/usr/local/lib/python3/dist-packages/pm3.py
#/usr/lib/python3/dist-packages/pm3.py

# need access to pm3.py
PYTHONPATH=../src ../../pm3 -c "script run testembedded.py"
../../pm3 -c "script run testembedded.py"
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
#!/bin/bash

#/usr/local/lib/python3/dist-packages/pm3.py
#/usr/lib/python3/dist-packages/pm3.py

# need access to pm3.py
PYTHONPATH=../src ../../pm3 -c "script run testembedded_grab.py" -i
../../pm3 -c "script run testembedded_grab.py" -i
13 changes: 10 additions & 3 deletions pm3
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ FINDBTRFCOMM=true
FINDBTDIRECT=true

PM3PATH=$(dirname "$0")
EVALENV=""
FULLIMAGE="fullimage.elf"
BOOTIMAGE="bootrom.elf"
# try pm3 dirs in current repo workdir
Expand All @@ -23,17 +24,23 @@ if [ -d "$PM3PATH/client/" ]; then
echo >&2 "[!!] In devel workdir but no executable found, did you compile it?"
exit 1
fi
# Devel mode: point to workdir pm3.py module
EVALENV+=" PYTHONPATH=$PM3PATH/client/src"
# try install dir
elif [ -x "$PM3PATH/proxmark3" ]; then
CLIENT="$PM3PATH/proxmark3"
EVALENV+=" PYTHONPATH=$PM3PATH/../share/proxmark3/pyscripts/"
# or /usr/[local/]lib/python3/dist-packages/pm3.py ?
else
# hope it's installed somehow, still not sure where fw images are...
# hope it's installed somehow, still not sure where fw images and pm3.py are...
CLIENT="proxmark3"
fi
EVALENV=""
# LeakSanitizer suppressions
if [ -e .lsan_suppressions ]; then
EVALENV="export LSAN_OPTIONS=suppressions=.lsan_suppressions"
EVALENV+=" LSAN_OPTIONS=suppressions=.lsan_suppressions"
fi
if [ "$EVALENV" != "" ]; then
EVALENV="export $EVALENV"
fi
PM3LIST=()
SHOWLIST=false
Expand Down

0 comments on commit 923d294

Please sign in to comment.