Re: patch for the ldconfig fix in latest snapshot
Dustin Navea wrote: [snip]
--- tools/wineinstall Sat May 4 13:31:24 2002 +++ tools/wineinstall.new Sat May 11 01:19:04 2002 @@ -319,7 +319,9 @@ # to our sucommand string if [ -f /etc/ld.so.conf ] then - if [ ! grep -qs "$libdir" /etc/ld.so.conf ] + # why were there brackets around this? it wasn't evaluating + # correctly because of them! -Dustin Navea
Doh!... The previous two lines should not be in the patch . If it was applied it would make for very strange reading. Please re-submit without them.
+ if ! grep -qs "$libdir" /etc/ld.so.conf then { echo echo "$libdir doesn't exist in your /etc/ld.so.conf, it will be added"
lookingoveryourshoulder Tony Lambregts
I would be more comfortable with the following (warning, direct edit of the original patch): --- tools/wineinstall Sat May 4 13:31:24 2002 +++ tools/wineinstall.new Sat May 11 01:19:04 2002 @@ -319,7 +319,8 @@ # to our sucommand string if [ -f /etc/ld.so.conf ] then - if [ ! grep -qs "$libdir" /etc/ld.so.conf ] + grep -qs "$libdir" /etc/ld.so.conf 2>/dev/null + if [ $? -ne 0 ] then { echo echo "$libdir doesn't exist in your /etc/ld.so.conf, it will be added" -- Francois Gouget fgouget(a)free.fr http://fgouget.free.fr/ Stolen from an Internet user: "f u cn rd ths, u cn gt a gd jb n cmptr prgrmmng !"
On Sat, May 11, 2002 at 08:30:56PM -0700, Francois Gouget wrote:
I would be more comfortable with the following (warning, direct edit of the original patch):
or even....
--- tools/wineinstall Sat May 4 13:31:24 2002 +++ tools/wineinstall.new Sat May 11 01:19:04 2002 @@ -319,7 +319,8 @@ # to our sucommand string if [ -f /etc/ld.so.conf ] then - if [ ! grep -qs "$libdir" /etc/ld.so.conf ] + grep -qs "$libdir" /etc/ld.so.conf 2>/dev/null || { echo echo "$libdir doesn't exist in your /etc/ld.so.conf, it will be added"
remembering to delete the endif... I normally use && and || rather than if/then/else/endif - generates slightly more concise shell scripts :-) David -- David Laight: david(a)l8s.co.uk
participants (3)
-
David Laight -
Francois Gouget -
Tony Lambregts