summaryrefslogtreecommitdiff
path: root/MakeTAGS
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>1995-10-11 03:34:46 +0000
committerRoland McGrath <roland@gnu.org>1995-10-11 03:34:46 +0000
commit8e3cc80f6d4f69ce003c82d3561ac324692792ad (patch)
tree46dcca133fd8477dee761d12ae692fda7cfd9ff3 /MakeTAGS
parentb122c7038e826eeabbc0118612b988c1a0f5b991 (diff)
Tue Oct 10 23:08:53 1995 Roland McGrath <roland@churchy.gnu.ai.mit.edu>
* Makerules (build-shlib): Pass -rpath and -rpath-link options. (LDFLAGS-c.so): Don't pass -dynamic-linker here. * Makeconfig (+link): Pass $(sysdep-LDFLAGS). (link-libc): Pass -rpath and -rpath-link options. * MakeTAGS (all-dirs): Omit CVS directories. Specify vpath directives to find source files in $(all-dirs). (sources, headers): Append sources and headers from $(all-dist) to these. (all-dist): Filter them out of this. (all-headers, all-sources): Use $(shell find ...) instead of $(wildcard ...). * sysdeps/mach/hurd/Makefile (sysdep-LDFLAGS): New variable; pass -rpath-link. * hurd/hurdexec.c: Pass poly and dealloc args to __file_exec. * elf/Makefile (install-others): Add missing $. * mach/Makefile ($(objpfx)errsystems.c): Rule reenabled.
Diffstat (limited to 'MakeTAGS')
-rw-r--r--MakeTAGS31
1 files changed, 20 insertions, 11 deletions
diff --git a/MakeTAGS b/MakeTAGS
index 29dfc47f01..96dc59e587 100644
--- a/MakeTAGS
+++ b/MakeTAGS
@@ -43,7 +43,8 @@ sysdep-dirs := $(addprefix $(sysdep_dir)/,$(sysdirs))
ifndef sysdep_dirs
# Find all sysdep directories.
-sysdep_dirs := $(shell find $(..)sysdeps -type d ! -name RCS -print)
+sysdep_dirs := $(shell find $(..)sysdeps -type d \
+ ! -name RCS ! -name CVS -print)
endif
# Find all sysdep dirs there are, but putting the ones
@@ -53,6 +54,11 @@ all-dirs := $(objdir) \
$(source_dirs) \
$(filter-out $(sysdep-dirs),$(sysdep_dirs))
+vpath %.h $(all-dirs)
+vpath %.c $(all-dirs)
+vpath %.S $(all-dirs)
+vpath %.s $(all-dirs)
+
# Find all the subdirs there are, but putting the ones
# we are configured to use first and preserving their order.
ifndef subdir
@@ -71,18 +77,21 @@ else
all-dist = $(distribute)
endif
+sources += $(filter %.c %.s %.S,$(all-dist))
+headers += $(filter %.h,$(all-dist))
+all-dist := $(filter-out %.h %.c %.s %.S,$(all-dist))
+
# All different versions of $(sources), preserving the configured sysdep
# directory order.
-all-sources = $(wildcard $(foreach file,$(sources),\
- $(file) \
- $(foreach dir,$(all-dirs),\
- $(dir)/$(file) \
- $(dir)/$(file:.c=.S) \
- $(dir)/$(file:.c=.s))))
-
-all-headers = $(wildcard $(foreach file,$(headers),\
- $(file) \
- $(foreach dir,$(all-dirs),$(dir)/$(file))))
+all-sources = $(shell find $(all-dirs) -maxdepth 1 \( -name fnord \
+ $(foreach file,$(sort $(sources) $(sources:.c=.S) \
+ $(sources:.c=.s)),\
+ -o -name $(file)) \
+ \) -print)
+
+all-headers = $(shell find $(all-dirs) -maxdepth 1 \( -name fnord \
+ $(foreach file,$(headers),-o -name $(file)) \
+ \) -print)
tags_sources := $(strip $(tags_sources))