diff options
Diffstat (limited to 'utils/sbtools/Makefile')
-rw-r--r-- | utils/sbtools/Makefile | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/utils/sbtools/Makefile b/utils/sbtools/Makefile index dc9c0966a7..15d3adb8a1 100644 --- a/utils/sbtools/Makefile +++ b/utils/sbtools/Makefile | |||
@@ -1,10 +1,22 @@ | |||
1 | DEFINES=-DCRYPTO_LIBUSB | ||
2 | CC=gcc | ||
3 | LD=gcc | ||
4 | CFLAGS=-g -std=c99 -W -Wall `pkg-config --cflags libusb-1.0` $(DEFINES) | ||
5 | LDFLAGS=`pkg-config --libs libusb-1.0` | ||
6 | |||
1 | all: elftosb sbtoelf | 7 | all: elftosb sbtoelf |
2 | 8 | ||
3 | sbtoelf: sbtoelf.c crc.c crypto.h aes128.c sha1.c elf.c sb.h | 9 | %.o: %.c |
4 | gcc -g -std=c99 -o $@ -W -Wall $^ | 10 | $(CC) $(CFLAGS) -c -o $@ $< |
11 | |||
12 | sbtoelf: sbtoelf.o crc.o crypto.o aes128.o sha1.o elf.o misc.o | ||
13 | $(LD) $(LDFLAGS) -o $@ $^ | ||
5 | 14 | ||
6 | elftosb: elftosb.c crc.c crypto.h aes128.c sha1.c elf.c sb.h dbparser.h dbparser.c | 15 | elftosb: elftosb.o crc.o crypto.o aes128.o sha1.o elf.o dbparser.o misc.o |
7 | gcc -g -std=c99 -o $@ -W -Wall $^ | 16 | $(LD) $(LDFLAGS) -o $@ $^ |
8 | 17 | ||
9 | clean: | 18 | clean: |
10 | rm -fr elftosb sbtoelf | 19 | rm -fr *.o |
20 | |||
21 | veryclean: | ||
22 | rm -rf sbtoelf elftosb | ||