]> cvs.zerfleddert.de Git - proxmark3-svn/commitdiff
create target for binary file archive (linux version)
authoradam@algroup.co.uk <adam@algroup.co.uk@ef4ab9da-24cd-11de-8aaa-f3a34680c41f>
Sun, 9 May 2010 12:17:42 +0000 (12:17 +0000)
committeradam@algroup.co.uk <adam@algroup.co.uk@ef4ab9da-24cd-11de-8aaa-f3a34680c41f>
Sun, 9 May 2010 12:17:42 +0000 (12:17 +0000)
Makefile
armsrc/Makefile
bootrom/Makefile
client/Makefile
common/Makefile.common

index 3b01b8864345f150677d28da08e6c2566d847067..4b1016c4429a261a784e2869f7f26d80f73547f6 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,5 +1,7 @@
 include common/Makefile.common
 
+GZIP=gzip
+
 all clean: %: bootrom/% armsrc/% client/%
 
 bootrom/%: FORCE
@@ -41,5 +43,12 @@ flash-both: armsrc/obj/osimage.elf armsrc/obj/fpgaimage.elf $(FLASH_TOOL)
 flash-all: bootrom/obj/bootrom.elf armsrc/obj/osimage.elf armsrc/obj/fpgaimage.elf $(FLASH_TOOL)
        $(FLASH_TOOL) -b $(subst /,$(PATHSEP),$(filter-out $(FLASH_TOOL),$^))
 
+newtarbin:
+       $(DELETE) proxmark3-$(platform)-bin.tar proxmark3-$(platform)-bin.tar.gz
+       @touch proxmark3-$(platform)-bin.tar
+
+tarbin: newtarbin client/tarbin armsrc/tarbin bootrom/tarbin
+       $(GZIP) proxmark3-$(platform)-bin.tar
+
 # Dummy target to test for GNU make availability
 _test:
index 1c0088e25d40f2b3d8cd7788423aa1b35936c9b0..bf13008ac482c1fe52a8a5d70642cf571cbb987e 100644 (file)
@@ -44,7 +44,9 @@ APP_CFLAGS += -I.
 # Do not move this inclusion before the definition of {THUMB,ASM,ARM}SRC
 include ../common/Makefile.common
 
-all: $(OBJDIR)/osimage.s19 $(OBJDIR)/fpgaimage.s19
+OBJS = $(OBJDIR)/osimage.s19 $(OBJDIR)/fpgaimage.s19
+
+all: $(OBJS)
 
 $(OBJDIR)/fpga.o: fpga.bit
        $(OBJCOPY) -O elf32-littlearm -I binary -B arm --redefine-sym _binary____fpga_fpga_bit_start=_binary_fpga_bit_start --redefine-sym _binary____fpga_fpga_bit_end=_binary_fpga_bit_end --prefix-sections=fpga_bit  $^ $@
@@ -58,6 +60,10 @@ $(OBJDIR)/fpgaimage.elf: $(OBJDIR)/fullimage.elf
 $(OBJDIR)/osimage.elf: $(OBJDIR)/fullimage.elf
        $(OBJCOPY) -F elf32-littlearm --remove-section .fpgaimage $^ $@
 
+tarbin: $(OBJS)
+       $(TAR) $(TARFLAGS) ../proxmark3-$(platform)-bin.tar $(OBJS:%=armsrc/%) $(OBJS:%.s19=armsrc/%.elf)
+
+
 clean:
        $(DELETE) $(OBJDIR)$(PATHSEP)*.o
        $(DELETE) $(OBJDIR)$(PATHSEP)*.elf
index 0f661a8f3984727ce5d2a597f27db1cff9115007..8029b6fc1a1df6c02ca8eec6218086f5d2f03160 100644 (file)
@@ -24,7 +24,12 @@ APP_CFLAGS = -I.
 # Do not move this inclusion before the definition of {THUMB,ASM,ARM}SRC
 include ../common/Makefile.common
 
-all: $(OBJDIR)/bootrom.s19
+OBJS = $(OBJDIR)/bootrom.s19
+
+all: $(OBJS)
+
+tarbin: $(OBJS)
+       $(TAR) $(TARFLAGS) ../proxmark3-$(platform)-bin.tar $(OBJS:%=bootrom/%) $(OBJS:%.s19=bootrom/%.elf)
 
 $(OBJDIR)/bootrom.elf: $(VERSIONOBJ) $(ASMOBJ) $(ARMOBJ) $(THUMBOBJ)
        $(CC) $(LDFLAGS) -Wl,-T,ldscript-flash,-Map,$(patsubst %.elf,%.map,$@) -o $@ $^ $(LIBS)
index 66986dafe70883870547fee4c60d91da812567a4..368e2487f118fabddaa89bae73ffb5de4d249f31 100644 (file)
@@ -3,6 +3,8 @@
 # at your option, any later version. See the LICENSE.txt file for the text of
 # the license.
 #-----------------------------------------------------------------------------
+include ../common/Makefile.common
+
 CC=gcc
 CXX=g++
 #COMMON_FLAGS = -m32
@@ -14,8 +16,6 @@ LDLIBS = -L/opt/local/lib -L/usr/local/lib -lusb -lreadline -lpthread
 LDFLAGS = $(COMMON_FLAGS)
 CFLAGS = -std=gnu99 -I. -I../include -I../common -I/opt/local/include -Wall -Wno-unused-function $(COMMON_FLAGS) -g -O3
 
-platform = $(shell uname)
-
 ifneq (,$(findstring MINGW,$(platform)))
 CXXFLAGS = -I$(QTDIR)/include -I$(QTDIR)/include/QtCore -I$(QTDIR)/include/QtGui
 QTLDLIBS = -L$(QTDIR)/lib -lQtCore4 -lQtGui4
@@ -95,6 +95,9 @@ proxguiqt.moc.cpp: proxguiqt.h
 clean:
        $(RM) $(CLEAN)
 
+tarbin: $(BINS)
+       $(TAR) $(TARFLAGS) ../proxmark3-$(platform)-bin.tar $(BINS:%=client/%)
+
 # must be run as root
 install_kext: Info.plist
        mkdir -p /System/Library/Extensions/Proxmark3.kext/Contents
index 077fc2822df8f5862142bf341a7b79f4db200520..0e3bdd1ebfc7ce6289456684f98558bcb87d2b5d 100644 (file)
@@ -15,6 +15,9 @@
 
 # Make sure that all is the default target
 # (The including Makefile still needs to define what 'all' is)
+
+platform = $(shell uname)
+
 all:
 
 CROSS  ?= arm-eabi-
@@ -27,6 +30,9 @@ OBJDIR        = obj
 
 INCLUDE = -I../include -I../common
 
+TAR=tar
+TARFLAGS = -C .. -rvf
+
 # Windows' echo echos its input verbatim, on Posix there is some
 #  amount of shell command line parsing going on. echo "" on 
 #  Windows yields literal "", on Linux yields an empty line
Impressum, Datenschutz