new solution for empty lib dir (old one had some problems)
authorRich Felker <dalias@aerifal.cx>
Thu, 17 Feb 2011 22:12:52 +0000 (17:12 -0500)
committerRich Felker <dalias@aerifal.cx>
Thu, 17 Feb 2011 22:12:52 +0000 (17:12 -0500)
Makefile
lib/empty [new file with mode: 0644]

index c3d29d240c64646083efbd6d6b666cfeda8fea05..56bfb40d1834ca508673139c3a29cbef1aaedaed 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -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
diff --git a/lib/empty b/lib/empty
new file mode 100644 (file)
index 0000000..e69de29