proxmark3: install scripts, fix warnings

This commit is contained in:
Rick Farina (Zero_Chaos) 2018-08-12 00:09:17 +00:00
parent b94b906b1c
commit 50c93b0f0b
No known key found for this signature in database
GPG key ID: A5DD1427DD11F94A
2 changed files with 38 additions and 0 deletions

View file

@ -0,0 +1,29 @@
diff -Naur proxmark3-3.0.1/client/Makefile proxmark3-3.0.1-fixed/client/Makefile
--- proxmark3-3.0.1/client/Makefile 2017-06-09 13:50:55.000000000 +0000
+++ proxmark3-3.0.1-fixed/client/Makefile 2018-08-11 23:53:24.594635301 +0000
@@ -4,9 +4,9 @@
# the license.
#-----------------------------------------------------------------------------
-CC = gcc
-CXX = g++
-LD = g++
+CC ?= gcc
+CXX ?= g++
+LD = g++
TAR = tar
TARFLAGS = -C .. --ignore-failed-read -rvf
RM = rm -f
@@ -18,9 +18,9 @@
LDLIBS = -L/opt/local/lib -L/usr/local/lib -lreadline -lpthread -lm
LUALIB = ../liblua/liblua.a
-LDFLAGS = $(COMMON_FLAGS)
-CFLAGS = -std=c99 -D_ISOC99_SOURCE -I. -I../include -I../common -I../zlib -I/opt/local/include -I../liblua -Wall $(COMMON_FLAGS) -g -O3
-CXXFLAGS = -I../include -Wall -O3
+#LDFLAGS := $(LDFLAGS)
+CFLAGS := -std=c99 -D_ISOC99_SOURCE -I. -I../include -I../common -I../zlib -I/opt/local/include -I../liblua $(CFLAGS)
+CXXFLAGS := -I../include $(CXXFLAGS)
LUAPLATFORM = generic
platform = $(shell uname)

View file

@ -19,13 +19,17 @@ DEPEND="virtual/libusb:0
dev-qt/qtcore:5
dev-qt/qtwidgets:5
dev-qt/qtgui:5
sys-libs/readline:=
firmware? ( sys-devel/gcc-arm-none-eabi )"
RDEPEND="${DEPEND}"
src_prepare() {
sed -i -e 's/-ltermcap/-ltinfo/g' client/Makefile || die
sed -i -e 's/-ltermcap/-ltinfo/g' liblua/Makefile || die
sed -i -e 's#lualibs/#../../usr/share/proxmark3/lualibs/#' client/scripting.h || die
sed -i -e 's#scripts/#../../usr/share/proxmark3/scripts/#' client/scripting.h || die
mv driver/77-mm-usb-device-blacklist.rules driver/77-pm3-usb-device-blacklist.rules
eapply "${FILESDIR}/cflags.patch"
eapply_user
}
@ -39,6 +43,11 @@ src_compile(){
src_install(){
dobin client/{flasher,proxmark3}
#install scripts too
insinto /usr/share/proxmark3/lualibs
doins client/lualibs/*
insinto /usr/share/proxmark3/scripts
doins client/scripts/*
if use firmware; then
insinto /usr/share/proxmark3
doins armsrc/obj/*.elf