AR_normal := $(TARGET_PREFIX)ar
LD_normal := $(TARGET_PREFIX)ld
OBJCOPY_normal := $(TARGET_PREFIX)objcopy
-RANLIB_normal := $(TARGET_PREFIX)ranlib
CC_quiet = @echo " CC " $@ && $(TARGET_PREFIX)gcc
CX_quiet = @echo " CX " $@ && $(TARGET_PREFIX)g++
AR_quiet = @echo " AR " $@ && $(TARGET_PREFIX)ar
LD_quiet = @echo " LD " $@ && $(TARGET_PREFIX)ld
OBJCOPY_quiet = @echo " OBJCOPY " $@ && $(TARGET_PREFIX)objcopy
-RANLIB_quiet = @echo " RANLIB " $@ && $(TARGET_PREFIX)ranlib
MSC_GIT_ID := $(shell cd $(MSCDIR) && python3 -c "from misoclib.cpu.identifier import get_id; print(hex(get_id()), end='')")
AR = $(AR_normal)
LD = $(LD_normal)
OBJCOPY = $(OBJCOPY_normal)
- RANLIB = $(RANLIB_normal)
else
CC = $(CC_quiet)
CX = $(CX_quiet)
AR = $(AR_quiet)
LD = $(LD_quiet)
OBJCOPY = $(OBJCOPY_quiet)
- RANLIB = $(RANLIB_quiet)
endif
# Toolchain options
-include $(OBJECTS:.o=.d)
libbase.a: $(OBJECTS) vsnprintf.o
- $(AR) clr libbase.a $(OBJECTS) vsnprintf.o
- $(RANLIB) libbase.a
+ $(AR) crs libbase.a $(OBJECTS) vsnprintf.o
libbase-nofloat.a: $(OBJECTS) vsnprintf-nofloat.o
- $(AR) clr libbase-nofloat.a $(OBJECTS) vsnprintf-nofloat.o
- $(RANLIB) libbase-nofloat.a
+ $(AR) crs libbase-nofloat.a $(OBJECTS) vsnprintf-nofloat.o
vsnprintf-nofloat.o: vsnprintf.c
$(call compile-dep,-DNO_FLOAT)
-include $(OBJECTS:.o=.d)
libcompiler-rt.a: $(OBJECTS)
- $(AR) clr libcompiler-rt.a $(OBJECTS)
- $(RANLIB) libcompiler-rt.a
+ $(AR) crs libcompiler-rt.a $(OBJECTS)
%.o: $(MSCDIR)/software/compiler-rt/lib/builtins/%.c
$(compile-dep)
-include $(OBJECTS:.o=.d)
libnet.a: $(OBJECTS)
- $(AR) clr libnet.a $(OBJECTS)
- $(RANLIB) libnet.a
+ $(AR) crs libnet.a $(OBJECTS)
%.o: %.c
$(compile-dep)