summaryrefslogtreecommitdiff
path: root/nuttx/arch/c5471/src/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'nuttx/arch/c5471/src/Makefile')
-rw-r--r--nuttx/arch/c5471/src/Makefile11
1 files changed, 7 insertions, 4 deletions
diff --git a/nuttx/arch/c5471/src/Makefile b/nuttx/arch/c5471/src/Makefile
index a4f953c6f..57d741aaa 100644
--- a/nuttx/arch/c5471/src/Makefile
+++ b/nuttx/arch/c5471/src/Makefile
@@ -56,7 +56,7 @@ COBJS = $(CSRCS:.c=.o)
SRCS = $(ASRCS) $(CSRCS)
OBJS = $(AOBJS) $(COBJS)
-all: up_head.o libarch.a
+all: up_head.o libarch$(LIBEXT)
$(AOBJS) up_head.o: %.o: %.S
$(CC) -c $(CFLAGS) -D__ASSEMBLY__ $< -o $@
@@ -64,8 +64,11 @@ $(AOBJS) up_head.o: %.o: %.S
$(COBJS): %.o: %.c
$(CC) -c $(CFLAGS) $< -o $@
-libarch.a: $(OBJS)
- $(AR) rcs $@ $(OBJS)
+libarch$(LIBEXT): $(OBJS)
+ ( for obj in $(OBJS) ; do \
+ $(AR) $@ $${obj} || \
+ { echo "$(AR) $@ $obj FAILED!" ; exit 1 ; } ; \
+ done ; )
.depend: Makefile $(SRCS)
$(MKDEP) $(CC) -- $(CFLAGS) -- $(SRCS) >Make.dep
@@ -74,7 +77,7 @@ libarch.a: $(OBJS)
depend: .depend
clean:
- rm -f libarch.a *.o *~
+ rm -f libarch$(LIBEXT) *.o *~
distclean: clean
rm -f Make.dep .depend