Small Makefile fixes.

/trunk/Makefile.in |   29    17    12     0 +++++++++++++++++------------
 1 file changed, 17 insertions(+), 12 deletions(-)
This commit is contained in:
Yann E. MORIN" 2008-12-28 10:19:50 +00:00
parent 59f66ebdee
commit fb4b418266

View File

@ -5,21 +5,6 @@ MAKEFLAGS += --no-print-directory --no-builtin-rules
all: Makefile build
###############################################################################
# Sanity checks
# Check if Makefile is up to date:
Makefile: Makefile.in
@echo "$< did changed: you must re-run './configure'"
@false
# If installing with DESTDIR, check it's an absolute path
ifneq ($(strip $(DESTDIR)),)
ifneq ($(DESTDIR),$(abspath /$(DESTDIR)))
$(error DESTDIR is not an absolute PATH: '$(DESTDIR)')
endif
endif
###############################################################################
# Configuration variables
@ -30,7 +15,27 @@ DOCDIR := @@DOCDIR@@
MANDIR := @@MANDIR@@
DATE := @@DATE@@
LOCAL := @@LOCAL@@
MAKE := $(shell which $(MAKE) || type -p $(MAKE) || echo /usr/bin/make)
MAKE := $(shell which $(MAKE) 2>/dev/null || type -p $(MAKE) 2>/dev/null || echo "ct-ng:nomake")
###############################################################################
# Sanity checks
# Check if Makefile is up to date:
Makefile: Makefile.in
@echo "$< did changed: you must re-run './configure'"
@false
# Check we do have make
ifeq ($(strip $(MAKE)),ct-ng:nomake)
$(error 'make' was not found on your system)
endif
# If installing with DESTDIR, check it's an absolute path
ifneq ($(strip $(DESTDIR)),)
ifneq ($(DESTDIR),$(abspath /$(DESTDIR)))
$(error DESTDIR is not an absolute PATH: '$(DESTDIR)')
endif
endif
###############################################################################
# Global make rules