[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: subst question
From: |
Dave Korn |
Subject: |
RE: subst question |
Date: |
Fri, 26 Jan 2007 14:43:29 -0000 |
On 26 January 2007 11:01, Brendan Heading wrote:
> All,
>
> Another quick question. Does anyone know a way in GNU Make to filter off the
> first instance only of a given string.
>
> For example, at the moment I'm doing
>
> $(subst lib,,libfoo.a)
>
> which gives me "foo.a". However if I do :
>
> $(subst lib,,libbarlib.a)
>
> this also gives me "bar.a" even though what I need is "barlib.a".
>
> Any ideas ?
How about
$(patsubst lib%,%,libbarlib.a)
cheers,
DaveK
--
Can't think of a witty .sigline today....