#! /bin/sh
deplist=$(ldd Client | awk '{if (match($3,"/")){print $3}}')
for nfile in $deplist;
do
if [ -L $nfile ]
then
realfile=$(ls -l $nfile | awk -F'->' '{print $2}' | tr -d ' ')
path="`dirname $nfile`"
if [ -f $realfile ]
then
echo "yes"
cp -Lf $realfile ./libtest
else
echo "no"
cp -Lf $path/$realfile ./libtest
fi
cp -df $nfile ./libtest
else
cp -Lf $nfile ./libtest
fi
done