This should fix -f usage in other files as well: php5-mapscript.config,
php5-mapscript.postinst, php5-mapscript.prerm.

diff -r 4b617e127b92 php5-mapscript.config
--- a/php5-mapscript.config	Wed Mar 12 11:50:37 2008 +0100
+++ b/php5-mapscript.config	Wed Mar 12 12:18:39 2008 +0100
@@ -17,8 +17,7 @@ do
 		# installed after the module was.
 		if [ -n "$2" ] && dpkg --compare-versions "$2" ge 4:4.3.2+rc3-2
 		then
-			if -f "/etc/$phpver/$SAPI/conf.d/mapscript.ini"
-			then
+			if [ -f "/etc/$phpver/$SAPI/conf.d/mapscript.ini" ]; then
 				db_set $phpver/extension_mapscript_$SAPI true
 			else
 				db_set $phpver/extension_mapscript_$SAPI false
diff -r 4b617e127b92 php5-mapscript.postinst
--- a/php5-mapscript.postinst	Wed Mar 12 11:50:37 2008 +0100
+++ b/php5-mapscript.postinst	Wed Mar 12 12:17:14 2008 +0100
@@ -17,8 +17,7 @@ do
 do
 	if [ -f /etc/$phpver/$SAPI/php.ini ] && [ -e /etc/$phpver/$SAPI/conf.d ]; then
 		db_get $phpver/extension_mapscript_$SAPI
-		if [ "$RET" = "true" ] && ! -f /etc/$phpver/$SAPI/conf.d/mapscript.ini
-		then
+		if [ "$RET" = "true" -a ! -f /etc/$phpver/$SAPI/conf.d/mapscript.ini ]; then
 			echo "extension=php_mapscript.so" > /etc/$phpver/$SAPI/conf.d/mapscript.ini
 		fi
 	fi
diff -r 4b617e127b92 php5-mapscript.prerm
--- a/php5-mapscript.prerm	Wed Mar 12 11:50:37 2008 +0100
+++ b/php5-mapscript.prerm	Wed Mar 12 12:18:15 2008 +0100
@@ -16,8 +16,7 @@ do
 do
 	# Use the same question for all extensions, because it's only
 	# used once per package: right here.
-	if [ -f "/etc/$phpver/$SAPI/php.ini" ] && -f /etc/$phpver/$SAPI/conf.d/mapscript.ini
-	then
+	if [ -f "/etc/$phpver/$SAPI/php.ini" -a -f /etc/$phpver/$SAPI/conf.d/mapscript.ini ]; then
 		db_set $phpver-mapscript/remove_extension true
 		db_title "PHP"
 		db_subst $phpver-mapscript/remove_extension extname Mapscript
_______________________________________________
Pkg-grass-devel mailing list
Pkg-grass-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/mailman/listinfo/pkg-grass-devel

Reply via email to