help-make
[Top][All Lists]
Advanced

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

how to use a string in a .SHELLFLAGS option?


From: Britton Kerin
Subject: how to use a string in a .SHELLFLAGS option?
Date: Sat, 8 Jan 2022 15:58:14 -0900

I'd like to use:

     SHELL = /usr/bin/perl
     .SHELLFLAGS = -w -E 'use warnings FATAL => "all";' -E

but it doesn't work, saying at recipe execution time:

     Can't find string terminator "'" anywhere before EOF at -e line 1.

I tried a few other quoting combinations without any luck.  It looks
like maybe the problem is that there's no way to group words at all.
This works to get the fatal warnings pragma:

     .SHELLFLAGS = -w -e use -e warnings -e FATAL -e => -e "all";

but it's sort of gruesome and there are still other reasons I'd like
to be able to pass spaces, for example to get the line number right as
in:

     perl -Mv5.20 -e \#line\ 42 -e 'say "$undeclared_var"'

That pragma has to go all on one line and I didn't find a substitute.
Anything I'm missing here?

Britton



reply via email to

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