updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / wine-uk / wine.install
blob700200fd67c5be6d127a8d1752323e4f4a64976d
1 post_install ()
3 echo "   Initlize lib settings..."
4 echo "    Checking path \"/usr/local/lib/\" in file /etc/ld.so.conf "
5 if [ "X"`sed -e '/\/usr\/local\/lib\//!d' -e '/^.\{16\}/!p' -e d /etc/ld.so.conf` != "X""/usr/local/lib/" ]; then
6 echo "    backup /etc/ld.so.conf"
7 cp -f /etc/ld.so.conf /etc/.ld.so.conf.ukbak
8 echo "    Adding path \"/usr/local/lib/\" to /etc/ld.so.conf"   
9 # add "/usr/local/lib/" to ld.so.conf
10 echo "/usr/local/lib/" >> /etc/ld.so.conf
11 /sbin/ldconfig
13 echo "   Done."
17 post_upgrade()
19         post_install
22 post_remove()
24 echo "   Initlize lib settings..."
25 if [ -f /etc/.ld.so.conf.ukbak ]; then
26 echo "    backup old /etc/ld.so.conf"
27 cp -f /etc/ld.so.conf /etc/.ld.so.conf.ukbak
28 echo "    Removing path \"/usr/local/lib/\" form file /etc/ld.so.conf"
29 sed `grep -n "^/usr/local/lib/$" /etc/.ld.so.conf.ukbak | awk -F":" '{print $1}'`'d' /etc/.ld.so.conf.ukbak > /etc/ld.so.conf
30 /sbin/ldconfig
31 rm -f /etc/.ld.so.conf.ukbak
33 echo "   Done."