russell: trunk r156 - in /trunk: Makefile tools/Makefile

asterisk-gui-commits at lists.digium.com asterisk-gui-commits at lists.digium.com
Thu Dec 7 23:59:31 MST 2006


Author: russell
Date: Fri Dec  8 00:59:31 2006
New Revision: 156

URL: http://svn.digium.com/view/asterisk-gui?view=rev&rev=156
Log:
Add some final fixups to the build and installation system changes to fix
duplication of the DESTDIR prefix, as well as not trying to install zapscan
if zaptel is not installed, and thus, not compiled.
(issue #8490, pabelanger)

Modified:
    trunk/Makefile
    trunk/tools/Makefile

Modified: trunk/Makefile
URL: http://svn.digium.com/view/asterisk-gui/trunk/Makefile?view=diff&rev=156&r1=155&r2=156
==============================================================================
--- trunk/Makefile (original)
+++ trunk/Makefile Fri Dec  8 00:59:31 2006
@@ -81,7 +81,7 @@
   endif
 endif
 
-HTTPDIR:=$(DESTDIR)$(ASTVARLIBDIR)/static-http
+HTTPDIR:=$(ASTVARLIBDIR)/static-http
 CONFIGDIR:=$(HTTPDIR)/config
 
 HTTPHOST?=$(shell hostname)
@@ -190,6 +190,7 @@
 	@ASTSBINDIR="$(ASTSBINDIR)" $(MAKE) -C $(@:-install=) install
 
 _install: _all $(SUBDIRS_INSTALL)
+	mkdir -p $(ASTETCDIR)
 	@echo "Installing into $(HTTPDIR)"
 	mkdir -p $(CONFIGDIR)
 	mkdir -p $(CONFIGDIR)/images
@@ -256,21 +257,21 @@
 	rm -f makeopts autom4te.cache
 
 samples:
-	mkdir -p $(DESTDIR)$(ASTETCDIR)
+	mkdir -p $(ASTETCDIR)
 	for x in configs/*.sample; do \
-		if [ -f $(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x .sample` ]; then \
+		if [ -f $(ASTETCDIR)/`$(BASENAME) $$x .sample` ]; then \
 			if [ "$(OVERWRITE)" = "y" ]; then \
-				if cmp -s $(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x .sample` $$x ; then \
+				if cmp -s (ASTETCDIR)/`$(BASENAME) $$x .sample` $$x ; then \
 					echo "Config file $$x is unchanged"; \
 					continue; \
 				fi ; \
-				mv -f $(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x .sample` $(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x .sample`.old ; \
+				mv -f $(ASTETCDIR)/`$(BASENAME) $$x .sample` $(ASTETCDIR)/`$(BASENAME) $$x .sample`.old ; \
 			else \
 				echo "Skipping config file $$x"; \
 				continue; \
 			fi ;\
 		fi ; \
-		$(INSTALL) -m 644 $$x $(DESTDIR)$(ASTETCDIR)/`$(BASENAME) $$x .sample` ;\
+		$(INSTALL) -m 644 $$x $(ASTETCDIR)/`$(BASENAME) $$x .sample` ;\
 	done
 
 makeopts: configure

Modified: trunk/tools/Makefile
URL: http://svn.digium.com/view/asterisk-gui/trunk/tools/Makefile?view=diff&rev=156&r1=155&r2=156
==============================================================================
--- trunk/tools/Makefile (original)
+++ trunk/tools/Makefile Fri Dec  8 00:59:31 2006
@@ -22,9 +22,10 @@
 zapscan.o: CFLAGS+=$(ZAPTEL_INCLUDE) $(ASTCFLAGS)
 
 install:
-	mkdir -p $(DESTDIR)/sbin
-	$(INSTALL) -m 755 zapscan $(ASTSBINDIR)
+ifeq ($(PBX_ZAPTEL),1)
+	mkdir -p $(ASTSBINDIR)
 	$(INSTALL) -m 755 zapscan.bin $(ASTSBINDIR)
+endif
 
 clean: 
 	rm -f zapscan.o



More information about the asterisk-gui-commits mailing list