summaryrefslogtreecommitdiffstats
path: root/utils/imxtools/sbtools/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'utils/imxtools/sbtools/Makefile')
-rw-r--r--utils/imxtools/sbtools/Makefile11
1 files changed, 8 insertions, 3 deletions
diff --git a/utils/imxtools/sbtools/Makefile b/utils/imxtools/sbtools/Makefile
index 13b0a1280f..2dad20fe0c 100644
--- a/utils/imxtools/sbtools/Makefile
+++ b/utils/imxtools/sbtools/Makefile
@@ -1,7 +1,9 @@
-DEFINES=-DCRYPTO_LIBUSB
+DEFINES=
CC=gcc
-LD=gcc
-CFLAGS=-O3 -g -std=c99 -W -Wall `pkg-config --cflags libusb-1.0` $(DEFINES)
+CXX=g++
+LD=g++
+CFLAGS=-O3 -g -std=c99 -Wall `pkg-config --cflags libusb-1.0` $(DEFINES)
+CXXFLAGS=-O3 -g -Wall $(DEFINES)
LDFLAGS=`pkg-config --libs libusb-1.0`
BINS=elftosb sbtoelf sbloader rsrctool elftosb1
@@ -10,6 +12,9 @@ all: $(BINS)
%.o: %.c
$(CC) $(CFLAGS) -c -o $@ $<
+%.o: %.cpp
+ $(CXX) $(CXXFLAGS) -c -o $@ $<
+
sbtoelf: sbtoelf.o crc.o crypto.o aes128.o sha1.o xorcrypt.o dbparser.o elf.o misc.o sb.o sb1.o
$(LD) -o $@ $^ $(LDFLAGS)