Gentoo Archives: gentoo-dev

From: Steve Long <slong@××××××××××××××××××.uk>
To: gentoo-dev@l.g.o
Subject: [gentoo-dev] Re: Re: RFC: qemu -> add gcc-3.x dependency
Date: Tue, 13 May 2008 01:25:43
Message-Id: g0aqlt$aos$1@ger.gmane.org
In Reply to: Re: [gentoo-dev] Re: RFC: qemu -> add gcc-3.x dependency by Matthias Schwarzott
1 Matthias Schwarzott wrote:
2 > Well, you want it compact, without loops.
3 > Here is it:
4 >
5 > set -- /usr/bin/gcc-3*
6 > Get first entry: CC="$1"
7 > Get last entry: eval CC="\${$#}"
8 >
9 Nice one, yeah I thought : splitting was posix silly me ;)
10 I still shy clear of eval for general use and you have to go thru
11 contortions with sh, so I'll stick with BASH arrays and "syntactic sugar"
12 which gets twisted enough as it is.
13
14
15 --
16 gentoo-dev@l.g.o mailing list