'grep -q' is not portable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The 'standard grep' of some platforms, e.g. Solaris, does not support
the -q option.


Changelog:

 * documentation/PACKAGING,
   tools/wineinstall

   'grep -q' is not portable -> don't use it

Index: documentation/PACKAGING
===================================================================
RCS file: /home/wine/wine/documentation/PACKAGING,v
retrieving revision 1.2
diff -u -r1.2 PACKAGING
--- documentation/PACKAGING	18 Jun 2003 03:30:40 -0000	1.2
+++ documentation/PACKAGING	29 Jul 2003 16:47:39 -0000
@@ -448,7 +448,7 @@

 The post-install script:

-	if ! grep -q /usr/X11R6/lib/wine /etc/ld.so.conf; then
+	if ! grep /usr/X11R6/lib/wine /etc/ld.so.conf >/dev/null; then
 	    echo "/usr/X11R6/lib/wine" >> /etc/ld.so.conf
 	fi
 	/sbin/ldconfig
Index: tools/wineinstall
===================================================================
RCS file: /home/wine/wine/tools/wineinstall,v
retrieving revision 1.56
diff -u -r1.56 wineinstall
--- tools/wineinstall	7 Jun 2003 00:35:19 -0000	1.56
+++ tools/wineinstall	29 Jul 2003 16:47:46 -0000
@@ -274,7 +274,7 @@
       # to our sucommand string
       if [ -f /etc/ld.so.conf ]
       then
-        if ! grep -qs "$libdir" /etc/ld.so.conf
+        if ! grep -s "$libdir" /etc/ld.so.conf >/dev/null 2>&1
         then {
           echo
           echo "$libdir doesn't exist in your /etc/ld.so.conf, it will be added"



-- 
Francois Gouget         fgouget@free.fr        http://fgouget.free.fr/
  Good judgment comes from experience, and experience comes from bad judgment
                               -- Barry LePatner



[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux