[icinga-checkins] icinga.org: icinga-web/r1.6: * Detecting which config files are installed ( ref #2376)

git at icinga.org git at icinga.org
Wed Feb 29 16:40:55 CET 2012


Module: icinga-web
Branch: r1.6
Commit: 26be08cd0a0f443618372773676bfec5b51939b6
URL:    https://git.icinga.org/?p=icinga-web.git;a=commit;h=26be08cd0a0f443618372773676bfec5b51939b6

Author: Marius Hein <marius.hein at netways.de>
Date:   Wed Feb 29 13:35:11 2012 +0100

* Detecting which config files are installed (ref #2376)
* make install|upgrade are now the same

---

 Makefile.in            |    4 ++--
 etc/conf.d/Makefile.in |    6 +++++-
 2 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/Makefile.in b/Makefile.in
index e2261b2..45d0e1f 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -235,9 +235,9 @@ install-siteconfig:
 install-log:
 	$(INSTALL) -m 755 $(INSTALL_OPTS_WEB) -d $(DESTDIR)$(LOGDIR)
 
-install-all: install-lib install-pub install-etc install-bin install-doc install-app install-log
+install-all: install-lib install-pub install-etc install-bin install-doc install-app install-log install-siteconfig
 
-install: install-all install-siteconfig install-done
+install: install-all install-done
 
 install-done:
 	@printf "\n\n"
diff --git a/etc/conf.d/Makefile.in b/etc/conf.d/Makefile.in
index 55099c9..7c98bb5 100644
--- a/etc/conf.d/Makefile.in
+++ b/etc/conf.d/Makefile.in
@@ -14,5 +14,9 @@ install:
 	$(INSTALL) -m 755 $(INSTALL_OPTS) -d $(DESTDIR)/$(WEB_CFG_DIR)
 	@files=`find . -type f -name "*.xml"`; \
 	for file in $$files; do \
-		$(INSTALL) -m 644 $(INSTALL_OPTS) "$$file" $(DESTDIR)$(WEB_CFG_DIR)/"$$file"; \
+		TARGET_FILE=$(DESTDIR)$(WEB_CFG_DIR)/`basename $$file`; \
+		if test ! -e $$TARGET_FILE; then \
+			$(INSTALL) -m 644 $(INSTALL_OPTS) "$$file" $(DESTDIR)$(WEB_CFG_DIR)/"$$file"; \
+			echo "Installing `basename $$TARGET_FILE` ... "; \
+		fi \
 	done





More information about the icinga-checkins mailing list