discuss-gnustep
[Top][All Lists]
Advanced

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

Re: Customizable filesystem support for GNUstep


From: Robert Slover
Subject: Re: Customizable filesystem support for GNUstep
Date: Fri, 09 Mar 2007 02:57:04 -0500

To avoid the overhead of starting the Bourne shell just to utilize IFS, you can use a csh variable modifier to break the path up on each ':'

foreach dir ( "" ${GNUSTEP_TOOLS_PATHLIST:as~:~ ~} )

instead of

foreach dir ( `/bin/sh -c 'IFS=:; for i in '"${GNUSTEP_TOOLS_PATHLIST}"'; do echo $i; done'` )

:a --> apply to all
:s~a~b~  --> substitute string b for string a

(Note that there is a space between the last two tildes, so this substitutes a space for all colon delimiters in the variable value).

HTH

--Robert

On Mar 8, 2007, at 9:13 AM, Nicola Pero wrote:

Thanks ... clever.  I fixed it on trunk. :-)

Thanks for your help



-----Original Message-----
From: Wolfgang Lux <wolfgang.lux@gmail.com>
Sent: Sat, March 3, 2007 10:17 am
To: nicola.pero@meta-innovation.com
Cc: Discuss-gnustep <discuss-gnustep@gnu.org>
Subject: Re: Customizable filesystem support for GNUstep

I wrote:

Nicola Pero wrote:

Anyway - let me know if it now works better! ;-)

It does. Thanks

I shall correct myself -- it almost works. GNUstep.csh doesn't
set up $path correctly. In particular, the various Tools
directories are not included in the path due to a quotation
error. The patch below fixes this.

Regards
Wolfgang

Index: GNUstep.csh.in
===================================================================
--- GNUstep.csh.in      (Revision 24757)
+++ GNUstep.csh.in      (Arbeitskopie)
@@ -197,7 +197,7 @@
end
set temp_path = ""
-foreach dir ( `/bin/sh -c 'IFS=:; for i in $
{GNUSTEP_TOOLS_PATHLIST}; do echo $i; done'` )
+foreach dir ( `/bin/sh -c 'IFS=:; for i in '"$
{GNUSTEP_TOOLS_PATHLIST}"'; do echo $i; done'` )
    set temp_path="${temp_path}${dir}:"
    if ( "${GNUSTEP_IS_FLATTENED}" == "no" ) then
      set temp_path="${temp_path}${dir}/${GNUSTEP_HOST_CPU}/$
{GNUSTEP_HOST_OS}/${LIBRARY_COMBO}:"




_______________________________________________
Discuss-gnustep mailing list
Discuss-gnustep@gnu.org
http://lists.gnu.org/mailman/listinfo/discuss-gnustep






reply via email to

[Prev in Thread] Current Thread [Next in Thread]