]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
BuildSystem: Avoid $EUID and use id -u instead.
authorAlexander Traud <pabstraud@compuserve.com>
Tue, 16 Jan 2018 12:34:23 +0000 (13:34 +0100)
committerAlexander Traud <pabstraud@compuserve.com>
Tue, 16 Jan 2018 12:36:31 +0000 (06:36 -0600)
Makefile included a call to ${EUID} which requires the shell bash. To keep
compatibility with other shells like dash or ksh, use id -u instead.

ASTERISK-27589

Change-Id: Ia6e74f5bc9aab4e6dc62b7439f647b7964e6f657

Makefile

index e9972af33017ce50d3c42d43e85aa11895a8c082..28245aa971cb0b4be3537620c0eabae9fe306e67 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -625,7 +625,7 @@ oldmodcheck:
 ld-cache-update:
 ifneq ($(LDCONFIG),)
 ifeq ($(DESTDIR),)  # DESTDIR means binary archive creation; ldconfig should be run on postinst
-       @if [ $${EUID} -eq 0 ] ; then \
+       @if [ $$(id -u) -eq 0 ] ; then \
                $(LDCONFIG) "$(ASTLIBDIR)/" ; \
        else \
                echo " WARNING WARNING WARNING" ;\