## use-test-binary.dpatch by Vagrant Cascadian <vagrant@freegeek.org>
##
## DP: use /usr/bin/test instead of relying on the shell test builtin, as bash
## DP: and dash behave inconsistantly. works around
## DP: http://bugs.debian.org/539909

Index: ltsp-5.2.2/client/initscripts/ltsp-init-common
===================================================================
--- ltsp-5.2.2.orig/client/initscripts/ltsp-init-common	2010-07-05 12:44:54.000000000 -0700
+++ ltsp-5.2.2/client/initscripts/ltsp-init-common	2010-07-05 12:45:16.000000000 -0700
@@ -338,7 +338,7 @@
 
 configure_cron() {
     CRON_FILE=/etc/cron.d/ltsp
-    if [ ! -w "/etc/cron.d" ]; then
+    if ! /usr/bin/test -w "/etc/cron.d" ; then
         echo "Warning: /etc/cron.d is not writeable."
         return 1
     fi
Index: ltsp-5.2.2/localapps/ldm-rc.d/X01-localapps
===================================================================
--- ltsp-5.2.2.orig/localapps/ldm-rc.d/X01-localapps	2010-07-05 12:45:09.000000000 -0700
+++ ltsp-5.2.2/localapps/ldm-rc.d/X01-localapps	2010-07-05 12:45:16.000000000 -0700
@@ -122,7 +122,7 @@
 
 
     if [ -n "$myGroups" ]; then
-        if [ -w /etc ]; then
+        if /usr/bin/test -w /etc ; then
             oldifs="${IFS-not set}"
             IFS=,
             for ngroup in $tocreate; do
