From: Jason Parker Date: Tue, 26 Feb 2008 18:09:13 +0000 (+0000) Subject: Since all shells aren't as awesome as bash, we have to fail if somebody tries to... X-Git-Tag: 1.4.19~138 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3d6b98b1ca03b8ee72a4a3d7ee281a35d3ada251;p=thirdparty%2Fasterisk.git Since all shells aren't as awesome as bash, we have to fail if somebody tries to use a literal "~" in DESTDIR. git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@104139 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/Makefile b/Makefile index 5343672372..c7f1661501 100644 --- a/Makefile +++ b/Makefile @@ -498,7 +498,14 @@ oldmodcheck: echo " WARNING WARNING WARNING" ;\ fi -install: datafiles bininstall $(SUBDIRS_INSTALL) +badshell: +ifneq ($(findstring ~,$(DESTDIR)),) + @echo "Your shell doesn't do ~ expansion when expected (specifically, when doing \"make install DESTDIR=~/path\")." + @echo "Try replacing ~ with \$$HOME, as in \"make install DESTDIR=\$$HOME/path\"." + @exit 1 +endif + +install: badshell datafiles bininstall $(SUBDIRS_INSTALL) @if [ -x /usr/sbin/asterisk-post-install ]; then \ /usr/sbin/asterisk-post-install $(DESTDIR) . ; \ fi