diff options
Diffstat (limited to 'nuttx/arch/sim/src/Makefile')
-rw-r--r-- | nuttx/arch/sim/src/Makefile | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/nuttx/arch/sim/src/Makefile b/nuttx/arch/sim/src/Makefile index 780cff596..53b4c6a7e 100644 --- a/nuttx/arch/sim/src/Makefile +++ b/nuttx/arch/sim/src/Makefile @@ -49,7 +49,7 @@ COBJS = $(CSRCS:.c=.o) SRCS = $(ASRCS) $(CSRCS) OBJS = $(AOBJS) $(COBJS) -all: up_head.o libarch.a +all: up_head.o libarch$(LIBEXT) $(AOBJS): %.o: %.S $(CC) -c $(CFLAGS) -D__ASSEMBLY__ $< -o $@ @@ -57,8 +57,11 @@ $(AOBJS): %.o: %.S $(COBJS) up_head.o: %.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 @@ -67,7 +70,7 @@ libarch.a: $(OBJS) depend: .depend clean: - rm -f libarch.a *.o *~ + rm -f libarch$(LIBEXT) *.o *~ distclean: clean rm -f Make.dep .depend |