[Pcsclite-cvs-commit] r6092 - /trunk/PCSC/src/spy/install_spy.sh
rousseau at users.alioth.debian.org
rousseau at users.alioth.debian.org
Mon Oct 31 14:12:54 UTC 2011
Author: rousseau
Date: Mon Oct 31 14:12:54 2011
New Revision: 6092
URL: http://svn.debian.org/wsvn/pcsclite/?sc=1&rev=6092
Log:
Make the script idempotent
The symbolic links are repared if needed. They were broken after the
sequence:
$ spy/install_spy.sh
$ make install
Modified:
trunk/PCSC/src/spy/install_spy.sh
Modified: trunk/PCSC/src/spy/install_spy.sh
URL: http://svn.debian.org/wsvn/pcsclite/trunk/PCSC/src/spy/install_spy.sh?rev=6092&op=diff
==============================================================================
--- trunk/PCSC/src/spy/install_spy.sh (original)
+++ trunk/PCSC/src/spy/install_spy.sh Mon Oct 31 14:12:54 2011
@@ -5,14 +5,16 @@
cd /usr/lib
-if [ -f libpcsclite_nospy.so.1 ]
+NOSPY=libpcsclite_nospy.so.1
+
+if [ -f $NOSPY ]
then
- echo "File libpcsclite_nospy.so.1 already exists"
- exit
+ echo "File $NOSPY already exists"
+else
+ # backup the real library
+ cp libpcsclite.so.1 $NOSPY
fi
-
-# backup the real library
-cp libpcsclite.so.1 libpcsclite_nospy.so.1
# link to the spy library
ln -sf libpcscspy.so.0.0.0 libpcsclite.so.1.0.0
+ln -sf libpcsclite.so.1.0.0 libpcsclite.so.1
More information about the Pcsclite-cvs-commit
mailing list