2011-10-29 14:22:17 +00:00
|
|
|
DEFINES=-DCRYPTO_LIBUSB
|
|
|
|
CC=gcc
|
|
|
|
LD=gcc
|
|
|
|
CFLAGS=-g -std=c99 -W -Wall `pkg-config --cflags libusb-1.0` $(DEFINES)
|
|
|
|
LDFLAGS=`pkg-config --libs libusb-1.0`
|
|
|
|
|
2011-04-17 01:43:48 +00:00
|
|
|
all: elftosb sbtoelf
|
2010-11-28 10:53:01 +00:00
|
|
|
|
2011-10-29 14:22:17 +00:00
|
|
|
%.o: %.c
|
|
|
|
$(CC) $(CFLAGS) -c -o $@ $<
|
|
|
|
|
|
|
|
sbtoelf: sbtoelf.o crc.o crypto.o aes128.o sha1.o elf.o misc.o
|
|
|
|
$(LD) $(LDFLAGS) -o $@ $^
|
2010-11-28 10:53:01 +00:00
|
|
|
|
2011-10-29 14:22:17 +00:00
|
|
|
elftosb: elftosb.o crc.o crypto.o aes128.o sha1.o elf.o dbparser.o misc.o
|
|
|
|
$(LD) $(LDFLAGS) -o $@ $^
|
2010-11-28 10:53:01 +00:00
|
|
|
|
|
|
|
clean:
|
2011-10-29 14:22:17 +00:00
|
|
|
rm -fr *.o
|
|
|
|
|
|
|
|
veryclean:
|
|
|
|
rm -rf sbtoelf elftosb
|