From: Automerge script Date: Wed, 13 Jun 2012 16:18:25 +0000 (+0000) Subject: Merged revisions 368831,368853 via svnmerge from X-Git-Tag: 10.7.0-digiumphones-rc1~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=18527968d284adf0e1c41aa4ad8950f1d8fab275;p=thirdparty%2Fasterisk.git Merged revisions 368831,368853 via svnmerge from file:///srv/subversion/repos/asterisk/branches/10 ................ r368831 | mjordan | 2012-06-12 13:30:06 -0500 (Tue, 12 Jun 2012) | 24 lines Do not perform install on existing directories If a directory already exists, performing a 'make install' will remove the permissions associated with the current directory and replace them with the permissions of the user executing the install. This patch changes this behavior to only perform an install on the directory if the directory does not exist. Thus, if a user later changes the permissions on that directory, those permissions will be preserved in subsequent installs. Review: https://reviewboard.asterisk.org/r/1986 Review: https://reviewboard.asterisk.org/r/1864 (closes issue ASTERISK-19492) Reported by: Karl Fife Tested by: Paul Belanger, Tilghman Lesher patches: ASTERISK-19492 by pabelanger (uploaded by mjordan) ........ Merged revisions 368830 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ................ r368853 | mjordan | 2012-06-13 09:30:34 -0500 (Wed, 13 Jun 2012) | 11 lines Do not install empty directories; add ASTLIBDIR r368830 modified the installation script to only create a directory if that directory does not exist. If some directory variable was empty, it would attempt to create the empty location. It also failed to create the ASTLIBDIR directory. This patch fixes it such that the correct directories are made and only created if a value specifying them actually exists. ........ Merged revisions 368852 from http://svn.asterisk.org/svn/asterisk/branches/1.8 ................ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/10-digiumphones@368872 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/Makefile b/Makefile index 1034c26445..f302ce6880 100644 --- a/Makefile +++ b/Makefile @@ -476,39 +476,23 @@ update: NEWHEADERS=$(notdir $(wildcard include/asterisk/*.h)) OLDHEADERS=$(filter-out $(NEWHEADERS) $(notdir $(DESTDIR)$(ASTHEADERDIR)),$(notdir $(wildcard $(DESTDIR)$(ASTHEADERDIR)/*.h))) +INSTALLDIRS="$(ASTLIBDIR)" "$(MODULES_DIR)" "$(ASTSBINDIR)" "$(ASTETCDIR)" "$(ASTVARRUNDIR)" \ + "$(ASTSPOOLDIR)" "$(ASTSPOOLDIR)/dictate" "$(ASTSPOOLDIR)/meetme" \ + "$(ASTSPOOLDIR)/monitor" "$(ASTSPOOLDIR)/system" "$(ASTSPOOLDIR)/tmp" \ + "$(ASTSPOOLDIR)/voicemail" "$(ASTHEADERDIR)" "$(ASTHEADERDIR)/doxygen" \ + "$(ASTLOGDIR)" "$(ASTLOGDIR)/cdr-csv" "$(ASTLOGDIR)/cdr-custom" \ + "$(ASTLOGDIR)/cel-custom" "$(ASTDATADIR)" "$(ASTDATADIR)/documentation" \ + "$(ASTDATADIR)/documentation/thirdparty" "$(ASTDATADIR)/firmware" \ + "$(ASTDATADIR)/firmware/iax" "$(ASTDATADIR)/images" "$(ASTDATADIR)/keys" \ + "$(ASTDATADIR)/phoneprov" "$(ASTDATADIR)/static-http" "$(ASTDATADIR)/sounds" \ + "$(ASTDATADIR)/moh" "$(ASTMANDIR)/man8" "$(AGI_DIR)" "$(ASTDBDIR)" installdirs: - $(INSTALL) -d "$(DESTDIR)$(MODULES_DIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTSBINDIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTETCDIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTVARRUNDIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTSPOOLDIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTSPOOLDIR)/dictate" - $(INSTALL) -d "$(DESTDIR)$(ASTSPOOLDIR)/meetme" - $(INSTALL) -d "$(DESTDIR)$(ASTSPOOLDIR)/monitor" - $(INSTALL) -d "$(DESTDIR)$(ASTSPOOLDIR)/system" - $(INSTALL) -d "$(DESTDIR)$(ASTSPOOLDIR)/tmp" - $(INSTALL) -d "$(DESTDIR)$(ASTSPOOLDIR)/voicemail" - $(INSTALL) -d "$(DESTDIR)$(ASTHEADERDIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTHEADERDIR)/doxygen" - $(INSTALL) -d "$(DESTDIR)$(ASTLOGDIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTLOGDIR)/cdr-csv" - $(INSTALL) -d "$(DESTDIR)$(ASTLOGDIR)/cdr-custom" - $(INSTALL) -d "$(DESTDIR)$(ASTLOGDIR)/cel-custom" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/documentation" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/documentation/thirdparty" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/firmware" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/firmware/iax" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/images" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/keys" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/phoneprov" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/static-http" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/sounds" - $(INSTALL) -d "$(DESTDIR)$(ASTDATADIR)/moh" - $(INSTALL) -d "$(DESTDIR)$(ASTMANDIR)/man8" - $(INSTALL) -d "$(DESTDIR)$(AGI_DIR)" - $(INSTALL) -d "$(DESTDIR)$(ASTDBDIR)" + @for i in $(INSTALLDIRS); do \ + if [ ! -z "$${i}" -a ! -d "$(DESTDIR)$${i}" ]; then \ + $(INSTALL) -d "$(DESTDIR)$${i}"; \ + fi; \ + done bininstall: _all installdirs $(SUBDIRS_INSTALL) $(INSTALL) -m 755 main/asterisk "$(DESTDIR)$(ASTSBINDIR)/"