diff options
author | Roland McGrath <roland@gnu.org> | 2000-03-27 19:42:09 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 2000-03-27 19:42:09 +0000 |
commit | 480d827b660a4e13fd5b9a4bacb3df57cad1a5aa (patch) | |
tree | f7008331c3b564143156a8d07a5d60c9afb70319 /Makeconfig | |
parent | 22d5fbfe74038c925bae4abbb1a911818a77ee42 (diff) | |
download | glibc-480d827b660a4e13fd5b9a4bacb3df57cad1a5aa.zip glibc-480d827b660a4e13fd5b9a4bacb3df57cad1a5aa.tar.gz glibc-480d827b660a4e13fd5b9a4bacb3df57cad1a5aa.tar.bz2 |
2000-03-27 Roland McGrath <roland@baalperazim.frob.com>
* Makeconfig (preprocess-versions): New canned sequence for running
cpp on shlib-versions and the like.
(soversions.i): Use it.
* Makerules (Versions.all, sysd-versions): Use it to preprocess the
Versions.def and Versions files.
Diffstat (limited to 'Makeconfig')
-rw-r--r-- | Makeconfig | 13 |
1 files changed, 10 insertions, 3 deletions
@@ -670,6 +670,14 @@ endif ifeq (yes, $(build-shared)) +# Commands to put in a pipeline to preprocess a file with # comments +# %ifdef et al based on config.h settings or other %include'd files. +define preprocess-versions +sed 's/#.*$$//;s/^[ ]*%/#/' \ +| $(CC) $(CPPFLAGS) -E -undef -include $(common-objpfx)config.h -x c - \ +| sed 's/#.*$$//;/^[ ]*$$/d' +endef + # Process the shlib-versions file, which tells us what shared library # version numbers to use when we install shared objects on this system. # We need to wait until $(subdirs) is complete. @@ -681,9 +689,8 @@ $(common-objpfx)soversions.i: $(..)shlib-versions $(..)Makeconfig \ $(add-ons) \ $(subdirs))) \ $(common-objpfx)config.make - sed -e 's/#.*$$//;s/^[ ]*%/#/' \ - $(filter-out $(..)Makeconfig $(common-objpfx)config.make,$^) \ - | $(CC) -E -undef -include $(common-objpfx)config.h -x c - \ + cat $(filter-out $(..)Makeconfig $(common-objpfx)config.make,$^) \ + | $(preprocess-versions) \ | while read conf version setname; do \ test -n "$$version" && \ test `expr '$(config-machine)-$(config-vendor)-$(config-os)' \ |