Check write perms in sys/ldconfig.sh

This commit is contained in:
pancake 2013-06-17 03:15:02 +02:00
parent def3e433bd
commit 6efdfd0e7a

View file

@ -1,8 +1,10 @@
#!/bin/sh
LD=/etc/ld.so.conf.d
type ldconfig > /dev/null 2>&1
if [ $? = 0 ]; then
mkdir -p $LD
awk -F= '/^LIBDIR/{print $2}' config-user.mk > $LD/radare.conf
ldconfig
if test -w $LD ; then
if type ldconfig > /dev/null 2>&1 ; then
mkdir -p $LD
awk -F= '/^LIBDIR/{print $2}' config-user.mk > $LD/radare.conf
ldconfig
fi
fi
exit 0