[Pkg-voip-commits] r3008 - asterisk/trunk/debian
Kilian Krause
kilian at alioth.debian.org
Sat Jan 13 14:13:01 CET 2007
Author: kilian
Date: 2007-01-13 14:13:00 +0100 (Sat, 13 Jan 2007)
New Revision: 3008
Modified:
asterisk/trunk/debian/asterisk_fix
asterisk/trunk/debian/changelog
Log:
Write a more robust verison to update /usr/share/asterisk/sounds/priv-callerintros.
Modified: asterisk/trunk/debian/asterisk_fix
===================================================================
--- asterisk/trunk/debian/asterisk_fix 2007-01-13 12:56:20 UTC (rev 3007)
+++ asterisk/trunk/debian/asterisk_fix 2007-01-13 13:13:00 UTC (rev 3008)
@@ -26,12 +26,27 @@
# Update from /usr/share/asterisk/sounds/priv-callerintros to
# /var/lib/asterisk/sounds/priv-callerintros
if [ -d /usr/share/asterisk/sounds/priv-callerintros ];then
- echo -n "Updating private callerinfos location to /var/lib/asterisk/sounds/priv-callerintros"
- if [ `find /usr/share/asterisk/sounds/priv-callerintros -mindepth 1|wc -l` -gt 0 ];then
- mv /usr/share/asterisk/sounds/priv-callerintros/* /var/lib/asterisk/sounds/priv-callerintros
+ if [ -L /usr/share/asterisk/sounds/priv-callerintros ];then
+ # if this is a fresh install just try to move the symlink.
+ rmdir --ignore-fail-on-non-empty /var/lib/asterisk/sounds/priv-callerintros
+ if [ ! -d /var/lib/asterisk/sounds/priv-callerintros ];then
+ echo -n "Updating private callerintros location to /var/lib/asterisk/sounds/priv-callerintros"
+ ln -s `readlink /usr/share/asterisk/sounds/priv-callerintros` /var/lib/asterisk/sounds/priv-callerintros
+ rm /usr/share/asterisk/sounds/priv-callerintros
+ echo '.'
+ else
+ echo 'Found user installed private callerintros. Not updating private callerintros'
+ echo 'directory to new directory. Please adjust symlink manually to new location'
+ echo '/var/lib/asterisk/sounds/priv-callerintros.'
+ fi
+ else
+ echo -n "Updating private callerintros location to /var/lib/asterisk/sounds/priv-callerintros"
+ if [ `find /usr/share/asterisk/sounds/priv-callerintros -mindepth 1|wc -l` -gt 0 ];then
+ mv /usr/share/asterisk/sounds/priv-callerintros/* /var/lib/asterisk/sounds/priv-callerintros
+ fi
+ rmdir /usr/share/asterisk/sounds/priv-callerintros
+ echo "."
fi
- rmdir /usr/share/asterisk/sounds/priv-callerintros
- echo "."
fi
# Make sure all (possibly) used dirs exist and is owned by asterisk
Modified: asterisk/trunk/debian/changelog
===================================================================
--- asterisk/trunk/debian/changelog 2007-01-13 12:56:20 UTC (rev 3007)
+++ asterisk/trunk/debian/changelog 2007-01-13 13:13:00 UTC (rev 3008)
@@ -1,8 +1,10 @@
asterisk (1:1.2.14~dfsg-3) UNRELEASED; urgency=low
* NOT RELEASED YET
+ * Write a more robust version of the FHS-update for
+ /usr/share/asterisk/sounds/priv-callerintros.
- -- Kilian Krause <kilian at debian.org> Sat, 13 Jan 2007 12:19:50 +0100
+ -- Kilian Krause <kilian at debian.org> Sat, 13 Jan 2007 14:12:26 +0100
asterisk (1:1.2.14~dfsg-2) unstable; urgency=low
More information about the Pkg-voip-commits
mailing list