Somewhat OT: Using Pipes Inside a GNU Make File
Bryan Drewery
bryan at shatow.net
Thu Sep 6 00:24:19 UTC 2012
On 9/5/2012 7:02 PM, Tim Daneliuk wrote:
> A bit off topic, but I'm kind of stuck. I am using gmake and want to
> do something like this:
>
> FOO := $(shell a | b | c)
>
> But this appears not to work. Only the 'a' command is executed. The
> remainder
> of the pipeline is ignored. Is there some clean way to implement this
> kind of thing?
>
>
I use this in a GNUMakefile and it works fine.
BRANCH := $(shell git branch --no-color | grep "^*" | sed -e 's/^\* //')
You may need to post a more specific example.
Bryan
More information about the freebsd-questions
mailing list