From b36f39016c9241b9efb5c626a673dbc4b534c2b8 Mon Sep 17 00:00:00 2001 From: "Michael I. Bushnell" Date: Thu, 27 Jun 1996 14:04:42 +0000 Subject: (MKINSTALLDIRS): New variable. (install) [all versions]: Add dependency on the directory being installed into. ($(installationdirlist)): New dependency. --- Makeconf | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'Makeconf') diff --git a/Makeconf b/Makeconf index d0a29a15..62356d2c 100644 --- a/Makeconf +++ b/Makeconf @@ -67,6 +67,12 @@ top_srcdirinc=-I$(top_srcdir) endif CPPFLAGS += -I. $(srcdirinc) -I.. $(top_srcdirinc) -I$(top_srcdir)/include -D_GNU_SOURCE CFLAGS += -Wall -g -O3 + + +# Local programs: +MKINSTALLDIRS = $(top_srcdir)/mkinstalldirs + + # Decode makemode: @@ -123,14 +129,14 @@ endif # Installation ifeq ($(doinst),one) all: $(target) -install: $(installationdir)/$(target) +install: $(installationdir)/$(target) $(installationdir) $(installationdir)/$(target): $(target) $(INSTALL_PROGRAM) $< $@ endif ifeq ($(doinst),many) all: $(targets) -install: $(addprefix $(installationdir)/,$(targets)) +install: $(addprefix $(installationdir)/,$(targets)) $(installationdir) $(addprefix $(installationdir)/,$(targets)): $(installationdir)/%: % $(INSTALL_PROGRAM) $< $@ endif @@ -138,7 +144,7 @@ endif ifeq ($(makemode),library) all: libs libs: $(targets) -install: $(addprefix $(libdir)/,$(targets)) $(addprefix $(includedir)/$(installhdrsubdir)/,$(installhdrs)) +install: $(addprefix $(libdir)/,$(targets)) $(addprefix $(includedir)/$(installhdrsubdir)/,$(installhdrs)) $(libdir) $(includedir) # Arrange to have the headers installed locally anytime we build the library. # Not quite perfect, but at least it does end up getting done; and once done @@ -164,9 +170,14 @@ $(addprefix $(includedir)/$(installhdrsubdir)/,$(installhdrs)): $(includedir)/$( $(INSTALL_DATA) $< $@ endif + # Provide default. install: +# Making installation directories +$(installationdirlist): %: + $(MKINSTALLDIRS) $@ + # Building the target ifeq ($(OBJS),) OBJS=%.o -- cgit v1.2.3