summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2001-11-14 23:58:22 +0000
committerRoland McGrath <roland@gnu.org>2001-11-14 23:58:22 +0000
commit84a99c799b319587cfb709e551b5c0655fc7a33c (patch)
tree306d32f157a92dd78c949a59e4fb363c786bbabe
parent056f339cdd660312e8c130f7c476efc764ac1748 (diff)
2001-11-14 Roland McGrath <roland@frob.com>
* Makeconf: Include config.make only if it exists. (configured): Set this if we included config.make. [! configured]: Set no_deps=t.
-rw-r--r--Makeconf17
1 files changed, 12 insertions, 5 deletions
diff --git a/Makeconf b/Makeconf
index e4de2769..9d299511 100644
--- a/Makeconf
+++ b/Makeconf
@@ -63,7 +63,16 @@ CFLAGS += -Wall -g -O3
# Include the configure-generated file of parameters.
# This sets up variables for build tools and installation directories.
+ifneq (,$(wildard $(..)config.make))
include $(..)config.make
+# Set a flag for the makefiles to indicated config.make was included.
+configured = yes
+endif
+
+# If we're not configured, don't do deps; then `make TAGS' and such can work.
+ifndef configured
+no_deps = t
+endif
# Test build options set by configure.
ifeq (no,$(build-profiled))
@@ -370,9 +379,7 @@ endif
# TAGS files
ifneq ($(dir),.)
-DEP_SRCS = sed -e 's/^.*://' -e 's/ \\$$//' | tr ' ' '\012'| \
- sed -n -e 's@^$(srcdir)@&@p' -e 's@^[^/]@&@p' | sort -ur
-ifeq ($(OBJS),)
+ifeq ($(SRCS),)
TAGS: $(OTHERTAGS)
ifeq ($(OTHERTAGS),)
# no tags, but parent will include this file, so make empty one.
@@ -381,8 +388,8 @@ else
etags -o $@ $^
endif
else
-TAGS: $(OBJS:.o=.d) $(OTHERTAGS)
- cat $(OBJS:.o=.d) | $(DEP_SRCS) | etags -o $@ - $(OTHERTAGS)
+TAGS: $(SRCS) $(OTHERTAGS)
+ etags -o $@ $^
endif
endif