echo "file $paket.co missing or not executable."
exit 1
fi
-if [ ! -x $paket.cp ]
+
+# clean dirs and check out
+if [ -d src ]
then
- echo "warning: file $paket.cp missing or not executable:"
- echo " this file is necessary for any package production."
+ echo "Shall I delete src dir? [y]/n"
+ read key
+ if [ "$key" != "n" ]
+ then
+ rm -rf src
+ fi
fi
-# clean dirs and check out
if [ -e $paket ]
then
rm -rf $paket
version=$(grep Version $paket.control |sed "s/Version: //")
fi
+# check for copy file
+copy=$(find src -name $paket.cp)
+if [ -n "$copy" ]
+then
+ ln -sf $copy .
+else
+ echo "warning: file $paket.cp missing or not executable:"
+ echo " this file is necessary for any package production."
+fi
# check for postinst
postinst=$(find src -name $paket.postinst)