help-make
[Top][All Lists]
Advanced

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

how to filter-out a word sequence?


From: David Boyce
Subject: how to filter-out a word sequence?
Date: Thu, 04 Jan 2007 20:05:04 -0500

My build model has a common link line which contains a number of -z options (-z is a way of passing keywords to the linker on Linux and Solaris). For instance:

        $(CC) -o program -z combreloc -z noversion -z defs ...

The problem is that occasionally a target will need one of these removed as a special case. But of course using $(filter-out -z foo,...) will remove *all* the -z flags, leaving the other keywords hanging there alone, while quoting the string like $(filter-out "-z foo",...) doesn't match anything. Does anybody know a reasonable way to remove a whitespace-containing string? I can think of ways involving $(shell) with but would prefer to do it all within the make process. Another complication is that, because this needs to be compatible with clearmake's GNU-compatibility mode, I'm limited to those features available since GNU make 3.76 or so.

Thanks,
David Boyce





reply via email to

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