projects
/
kopensolaris-gnu
/
glibc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Formerly ../Rules.~34~
[kopensolaris-gnu/glibc.git]
/
Rules
diff --git
a/Rules
b/Rules
index
5f1b33a
..
b548d6a
100644
(file)
--- a/
Rules
+++ b/
Rules
@@
-1,4
+1,4
@@
-# Copyright (C) 1991, 1992 Free Software Foundation, Inc.
+# Copyright (C) 1991, 1992
, 1993, 1994
Free Software Foundation, Inc.
# This file is part of the GNU C Library.
# The GNU C Library is free software; you can redistribute it and/or
# This file is part of the GNU C Library.
# The GNU C Library is free software; you can redistribute it and/or
@@
-17,12
+17,15
@@
# Cambridge, MA 02139, USA.
#
# Cambridge, MA 02139, USA.
#
-# Propagated rules for making the GNU C library
+# Rules for making a subdirectory in the GNU C library.
+# Each subdirectory Makefile defines some variables and includes this.
#
ifneq (,)
This makefile requires GNU Make.
endif
#
ifneq (,)
This makefile requires GNU Make.
endif
+all: # Don't let the default goal come from Makeconfig.
+
include ../Makeconfig
ifndef subdir
include ../Makeconfig
ifndef subdir
@@
-31,14
+34,18
@@
endif
# This is benign and useless in GNU make before 3.63.
export subdir := $(subdir)
\f
# This is benign and useless in GNU make before 3.63.
export subdir := $(subdir)
\f
-# This is the default target; it makes the library.
+# This is the default target; it makes the library
and auxiliary programs
.
.PHONY: all
.PHONY: all
-all: lib
+all: lib
others
ifneq "$(findstring env,$(origin headers))" ""
headers :=
endif
ifneq "$(findstring env,$(origin headers))" ""
headers :=
endif
+ifneq "$(findstring env,$(origin generated))" ""
+generated :=
+endif
+
ifeq "$(strip $(headers))" ""
ifneq "$(wildcard $(subdir).h)" ""
override headers := $(subdir).h
ifeq "$(strip $(headers))" ""
ifneq "$(wildcard $(subdir).h)" ""
override headers := $(subdir).h
@@
-74,6
+81,12
@@
$(objpfx)%.out: $(objpfx)%
$(dir $<)$(notdir $<) > $@
endif # tests
$(dir $<)$(notdir $<) > $@
endif # tests
+# Because the link above depends on libc.a, which I don't want built
+# automatically, this is necessary. -mib
+ifdef mib_hacks
+others :=
+endif
+
export others := $(others)
export tests := $(tests)
\f
export others := $(others)
export tests := $(tests)
\f
@@
-81,15
+94,16
@@
export tests := $(tests)
# except for the object files and the object-file library members.
.PHONY: mostlyclean
mostlyclean:
# except for the object files and the object-file library members.
.PHONY: mostlyclean
mostlyclean:
- -rm -f $(addprefix $(objpfx),$(tests) $(others))
- -rm -f core TAGS depend
+ -rm -f $(addprefix $(objpfx),$(tests) $(others) \
+ $(addsuffix .o,$(tests) $(others)))
+ -rm -f core TAGS $(objpfx)depend-$(subdir)
# This removes absolutely everything that can be regenerated.
.PHONY: subdir_clean clean realclean
subdir_clean realclean: clean
# This removes absolutely everything that can be regenerated.
.PHONY: subdir_clean clean realclean
subdir_clean realclean: clean
-+objs := $(objects)
clean: mostlyclean
clean: mostlyclean
- -rm -f $(+objs) $(+depfiles)
+ -rm -f $(objects) $(addprefix $(objpfx),$(extra-objs)) \
+ $(+depfiles) $(generated)
\f
.PHONY: subdir_echo-headers
subdir_echo-headers: echo-headers
\f
.PHONY: subdir_echo-headers
subdir_echo-headers: echo-headers
@@
-97,10
+111,13
@@
subdir_echo-headers: echo-headers
.PHONY: subdir_echo-distinfo
subdir_echo-distinfo:
@echo $(addprefix +header+,$(headers)) \
.PHONY: subdir_echo-distinfo
subdir_echo-distinfo:
@echo $(addprefix +header+,$(headers)) \
- $(addprefix +nodist+,$(dont_distribute))
-
\f
+ $(addprefix +nodist+,$(generated) $(dont_distribute))
+
+# We want to install everything except the library itself, but update all
+# our portions of the library because the parent make will install it later
+# (likewise the stubs file).
.PHONY: subdir_install
.PHONY: subdir_install
-subdir_install: install
+subdir_install: install
-no-libc.a lib-noranlib stubs
.PHONY: subdir_TAGS
subdir_TAGS: TAGS
.PHONY: subdir_TAGS
subdir_TAGS: TAGS
@@
-108,7
+125,12
@@
subdir_TAGS: TAGS
# Make the distribution tarfile for the parent makefile.
export distribute := $(distribute)
export dont_distribute := $(dont_distribute)
# Make the distribution tarfile for the parent makefile.
export distribute := $(distribute)
export dont_distribute := $(dont_distribute)
+export generated := $(generated)
.PHONY: subdir_dist dist
subdir_dist: dist
dist: ../Make-dist
$(MAKE) -f $< $(Make-dist-args)
.PHONY: subdir_dist dist
subdir_dist: dist
dist: ../Make-dist
$(MAKE) -f $< $(Make-dist-args)
+
+# Convenient target to update all the generated source files.
+.PHONY: generated
+generated: $(generated)