new solution for empty lib dir (old one had some problems)

This commit is contained in:
Rich Felker 2011-02-17 17:12:52 -05:00
parent a36164c474
commit 4fd159568a
2 changed files with 5 additions and 7 deletions

View File

@ -74,22 +74,20 @@ include/bits/alltypes.h: include/bits/alltypes.h.sh
%.lo: %.c $(GENH)
$(CC) $(CFLAGS) $(INC) $(PIC) -c -o $@ $<
lib:
mkdir -p lib
lib/libc.so: $(LOBJS) lib
lib/libc.so: $(LOBJS)
$(CC) $(LDFLAGS) -o $@ $(LOBJS) -lgcc
$(OBJCOPY) --weaken $@
lib/libc.a: $(OBJS) lib
lib/libc.a: $(OBJS)
rm -f $@
$(AR) rc $@ $(OBJS)
$(RANLIB) $@
$(EMPTY_LIBS): lib
$(EMPTY_LIBS):
rm -f $@
$(AR) rc $@
lib/%.o: crt/%.o lib
lib/%.o: crt/%.o
cp $< $@
tools/musl-gcc: tools/gen-musl-gcc.sh config.mak

0
lib/empty Normal file
View File