From 876529370d14b58d33b95932edf975853f6f7969 Mon Sep 17 00:00:00 2001 From: Juan RP Date: Tue, 18 Aug 2009 16:04:34 +0200 Subject: [PATCH] Fix DESTDIR + ETCDIR interaction. --HG-- extra : convert_revision : xtraeme%40gmail.com-20090818140434-3wttn8uvc7on7mry --- etc/Makefile | 8 ++++---- vars.mk | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/etc/Makefile b/etc/Makefile index d1242464..d0c2b83a 100644 --- a/etc/Makefile +++ b/etc/Makefile @@ -9,10 +9,10 @@ all: clean: install: - if [ ! -d $(ETCDIR) ]; then \ - install -d $(ETCDIR); \ + if [ ! -d $(DESTDIR)$(ETCDIR) ]; then \ + install -d $(DESTDIR)$(ETCDIR); \ fi - if [ ! -f $(ETCDIR)/$(CONF_FILE) ]; then \ - install -m 644 $(CONF_FILE) $(ETCDIR); \ + if [ ! -f $(DESTDIR)$(ETCDIR)/$(CONF_FILE) ]; then \ + install -m 644 $(CONF_FILE) $(DESTDIR)$(ETCDIR); \ fi diff --git a/vars.mk b/vars.mk index 8501149a..f6b8c507 100644 --- a/vars.mk +++ b/vars.mk @@ -3,7 +3,7 @@ PREFIX ?= /usr/local SBINDIR ?= $(DESTDIR)$(PREFIX)/sbin LIBDIR ?= $(DESTDIR)$(PREFIX)/lib -ETCDIR ?= $(DESTDIR)$(PREFIX)/etc +ETCDIR ?= $(PREFIX)/etc TOPDIR ?= .. INSTALL_STRIPPED ?= -s