Branko Čibej wrote:
> Julian Foad wrote:
>> Just an additional thought: is there a way to pass all the relevant options 
>> at once to the subordinate 'Makefile.PL', instead of just passing this 
>> one particular option? For example, GNU Make puts its flags and variables 
>> defined on the command line into the environment variable 'MAKEFLAGS' 
>> and a subordinate 'make' process inherits the same definitions by 
>> reading them from this variable.
> 
> But this is not a subordinate make process. Makefile.PL is a Perl script
> ... not confusing at all.

Ah, thanks. I realized it was a Perl script; I hadn't realized its purpose was 
*making* a Makefile rather than *being* a Makefile.

>  $(SWIG_PL_DIR)/native/Makefile: $(SWIG_PL_DIR)/native/Makefile.PL
> -    cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL
> +    cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL PREFIX=$(prefix)

So the OP's suggestion sounds like the right sort of fix.

(Another observation: Looking at the documentation of MakeMaker [1], I notice 
that as well as PREFIX, an alternative 'INSTALL_BASE' is documented as 'more 
like what everyone
else calls "prefix" than PREFIX is.')

- Julian

[1] http://perldoc.perl.org/ExtUtils/MakeMaker.html#INSTALL_BASE

Reply via email to