summaryrefslogtreecommitdiff
path: root/rbutil/mkamsboot/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'rbutil/mkamsboot/Makefile')
-rw-r--r--rbutil/mkamsboot/Makefile24
1 files changed, 16 insertions, 8 deletions
diff --git a/rbutil/mkamsboot/Makefile b/rbutil/mkamsboot/Makefile
index a76259794e..052904211b 100644
--- a/rbutil/mkamsboot/Makefile
+++ b/rbutil/mkamsboot/Makefile
@@ -1,9 +1,15 @@
1# __________ __ ___.
2# Open \______ \ ____ ____ | | _\_ |__ _______ ___
3# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
4# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
5# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
6# \/ \/ \/ \/ \/
1 7
2#change for releases 8#change for releases
3ifndef APPVERSION 9ifndef APPVERSION
4APPVERSION=`../../tools/version.sh ../../` 10APPVERSION=$(shell ../../tools/version.sh ../../)
5endif 11endif
6 12TARGET_DIR ?= $(shell pwd)/
7# We use the UCL code available in the Rockbox tools/ directory 13# We use the UCL code available in the Rockbox tools/ directory
8CFLAGS=-I../../tools/ucl/include -Wall -DVERSION=\"$(APPVERSION)\" 14CFLAGS=-I../../tools/ucl/include -Wall -DVERSION=\"$(APPVERSION)\"
9 15
@@ -37,10 +43,10 @@ endif
37all: $(OUTPUT) 43all: $(OUTPUT)
38 44
39# additional link dependencies for the standalone executable 45# additional link dependencies for the standalone executable
40LIBUCL=../../tools/ucl/src/libucl$(RBARCH).a 46LIBUCL=$(OBJDIR)libucl$(RBARCH).a
41 47
42$(LIBUCL): 48$(LIBUCL):
43 $(MAKE) -C ../../tools/ucl/src $(TARGET_DIR)libucl$(RBARCH).a 49 $(SILENT)$(MAKE) -C ../../tools/ucl/src TARGET_DIR=$(OBJDIR) libucl$(RBARCH).a
44 50
45# inputs 51# inputs
46LIBSOURCES := dualboot.c md5.c mkamsboot.c 52LIBSOURCES := dualboot.c md5.c mkamsboot.c
@@ -58,9 +64,11 @@ $(OBJDIR)%.o: %.c
58 $(SILENT)mkdir -p $(dir $@) 64 $(SILENT)mkdir -p $(dir $@)
59 $(SILENT)$(CC) $(CFLAGS) -c -o $@ $< 65 $(SILENT)$(CC) $(CFLAGS) -c -o $@ $<
60 66
61libmkamsboot$(RBARCH).a: $(LIBOBJS) 67libmkamsboot$(RBARCH).a: $(TARGET_DIR)libmkamsboot$(RBARCH).a
62 @echo AR $@ 68
63 $(SILENT)$(AR) rucs $(TARGET_DIR)$@ $^ 69$(TARGET_DIR)libmkamsboot$(RBARCH).a: $(LIBOBJS)
70 @echo AR $(notdir $@)
71 $(SILENT)$(AR) rucs $@ $^
64 72
65# building the standalone executable 73# building the standalone executable
66$(OUTPUT): $(OBJS) $(EXTRADEPS) 74$(OUTPUT): $(OBJS) $(EXTRADEPS)
@@ -74,7 +82,7 @@ $(TARGET_DIR)libmkamsbooti386.a:
74 82
75$(TARGET_DIR)libmkamsbootppc.a: 83$(TARGET_DIR)libmkamsbootppc.a:
76 make RBARCH=ppc TARGET_DIR=$(TARGET_DIR) libmkamsbootppc.a 84 make RBARCH=ppc TARGET_DIR=$(TARGET_DIR) libmkamsbootppc.a
77endif 85endif
78 86
79libmkamsboot-universal: $(TARGET_DIR)libmkamsbooti386.a $(TARGET_DIR)libmkamsbootppc.a 87libmkamsboot-universal: $(TARGET_DIR)libmkamsbooti386.a $(TARGET_DIR)libmkamsbootppc.a
80 @echo lipo $(TARGET_DIR)libmkamsboot.a 88 @echo lipo $(TARGET_DIR)libmkamsboot.a