summaryrefslogtreecommitdiff
path: root/extra-lib.mk
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2002-10-16 22:09:55 +0000
committerRoland McGrath <roland@gnu.org>2002-10-16 22:09:55 +0000
commit0a951d0e31b5fb34f7e0428e933d7df55ef7f94d (patch)
tree2a33901f73f75e1d97df6b16495909d3c1f37c6e /extra-lib.mk
parent0d83b42e2d59b722a66c7e3fed50437a647ed4ee (diff)
downloadglibc-0a951d0e31b5fb34f7e0428e933d7df55ef7f94d.tar.gz
* cppflags-iterator.mk (CPPFLAGS-$(cpp-src)): Variable removed.
instead of += to append, to be sure $(lib) gets expanded at defn time. (libof-$(cpp-src)): New variable, define this instead. * extra-lib.mk (cpp-srcs-left): Reduce duplication in include setup. (lib): Don't use override. (CPPFLAGS-$(lib)): New variable, put -D's here. * Makeconfig (CPPFLAGS): Use basename fn for CPPFLAGS-basename. Also add $(CPPFLAGS-LIB) before the file-specific flags, for each LIB found by $(libof-*) for basename, target, or source. * Makerules (CPPFLAGS-nonlib): New variable. * nscd/Makefile (lib): Set to nonlib when using cppflags-iterator.mk. * locale/Makefile (lib): Likewise. * sunrpc/Makefile (lib): Likewise. * sysdeps/unix/sysv/linux/fpathconf.c (LINUX_LINK_MAX): Move macro ... * sysdeps/unix/sysv/linux/linux_fsinfo.h (LINUX_LINK_MAX): ... here. * sysdeps/unix/sysv/linux/pathconf.h: New file. (statfs_link_max): New function, guts from fpathconf.c. * sysdeps/unix/sysv/linux/fpathconf.c: Rewritten using that. * sysdeps/unix/sysv/linux/pathconf.c (__pathconf): Likewise. * sysdeps/unix/sysv/linux/alpha/pathconf.c (__pathconf): Rewritten to use the linux/pathconf.c code by #include rather than duplication. * sysdeps/unix/sysv/linux/alpha/fpathconf.c (__pathconf): Likewise. 2002-10-16 Jakub Jelinek <jakub@redhat.com> * sysdeps/unix/sysv/linux/x86_64/sysdep.h (SYSCALL_ERROR_HANDLER): Use __libc_errno only for libc itself.
Diffstat (limited to 'extra-lib.mk')
-rw-r--r--extra-lib.mk16
1 files changed, 7 insertions, 9 deletions
diff --git a/extra-lib.mk b/extra-lib.mk
index d48f0faaa1..5428523e06 100644
--- a/extra-lib.mk
+++ b/extra-lib.mk
@@ -6,7 +6,7 @@
# to be included in that library. A sysdep Makefile can add to
# $(lib)-sysdep_routines to include additional modules.
-override lib := $(firstword $(extra-libs-left))
+lib := $(firstword $(extra-libs-left))
extra-libs-left := $(filter-out $(lib),$(extra-libs-left))
object-suffixes-$(lib) := $(filter-out $($(lib)-inhibit-o),$(object-suffixes))
@@ -79,12 +79,10 @@ endif
endif
-cpp-srcs-left = $(lib)-routines
-ifneq (,$($(lib)-routines))
-cpp-srcs-left = $($(lib)-routines)
-include $(patsubst %,$(..)cppflags-iterator.mk,$($(lib)-routines))
-endif
-ifneq (,$($(lib)-sysdep_routines))
-cpp-srcs-left = $($(lib)-sysdep_routines)
-include $(patsubst %,$(..)cppflags-iterator.mk,$($(lib)-sysdep_routines))
+# This will define `libof-ROUTINE := LIB' for each of the routines.
+cpp-srcs-left := $($(lib)-routines) $($(lib)-sysdep_routines)
+ifneq (,$(cpp-srcs-left))
+include $(patsubst %,$(..)cppflags-iterator.mk,$(cpp-srcs-left))
endif
+
+CPPFLAGS-$(lib) := -DNOT_IN_libc=1 -DIS_IN_$(lib)=1