summaryrefslogtreecommitdiff
path: root/libc
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2001-03-20 03:20:50 +0000
committerEric Andersen <andersen@codepoet.org>2001-03-20 03:20:50 +0000
commit9f1c86779c5bfbd2221640c78ce71e69f6beef6e (patch)
tree56ba782de5cedf3ed0ddf4588c24a0fea88c0608 /libc
parent089e0182638fc37d67f01738fb25d91cba7dcd97 (diff)
I think this fixes the dependancy problems. Manuel, can you
double check that this is what you intended? -Erik
Diffstat (limited to 'libc')
-rw-r--r--libc/unistd/Makefile16
1 files changed, 12 insertions, 4 deletions
diff --git a/libc/unistd/Makefile b/libc/unistd/Makefile
index 13da721a8..0f639df11 100644
--- a/libc/unistd/Makefile
+++ b/libc/unistd/Makefile
@@ -59,9 +59,15 @@ sysconf_$(TARGET_ARCH).c: sysconf.c
cp -f sysconf.c sysconf_$(TARGET_ARCH).c
# We are compiling for the native platform, so build an optimized sysconf.c.
-sysconf_native: sysconf.c
- $(CC) $(CFLAGS) -D_UCLIBC_GENERATE_SYSCONF_ARCH -c sysconf.c -o sysconf_tester.o
- $(CC) $(CFLAGS) -D_UCLIBC_GENERATE_SYSCONF_ARCH -c ../sysdeps/linux/common/getpagesize.c -o getpagesize_tester.o
+getpagesize_tester.o:
+ $(CC) $(CFLAGS) -D_UCLIBC_GENERATE_SYSCONF_ARCH \
+ -c ../sysdeps/linux/common/getpagesize.c -o getpagesize_tester.o
+
+sysconf_tester.o:
+ $(CC) $(CFLAGS) -D_UCLIBC_GENERATE_SYSCONF_ARCH -c sysconf.c \
+ -o sysconf_tester.o
+
+gen_sysconf_tester.o: sysconf_tester.o getpagesize_tester.o
@ld -r -o gen_sysconf_tester.o sysconf_tester.o getpagesize_tester.o
@if nm -s gen_sysconf_tester.o | grep -v "U errno" | grep " U " ;\
then \
@@ -78,6 +84,8 @@ sysconf_native: sysconf.c
fi ;\
fi
+sysconf_native: gen_sysconf_tester.o
+
sysconf_src.c: sysconf_$(TARGET_ARCH).c
cp -f sysconf_$(TARGET_ARCH).c sysconf_src.c
@@ -101,7 +109,7 @@ $(patsubst %, _dir_%, $(DIRS)) : dummy
$(patsubst %, _dirclean_%, $(DIRS)) : dummy
$(MAKE) -C $(patsubst _dirclean_%, %, $@) clean
-.PHONY: dummy
+.PHONY: dummy sysconf_native
dummy:
clean: