help-make
[Top][All Lists]
Advanced

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

Re: shortcut of ":" but not /bin/true


From: Paul D. Smith
Subject: Re: shortcut of ":" but not /bin/true
Date: Tue, 18 May 2004 09:46:16 -0400

%% David Boyce <address@hidden> writes:

  db> The ":" is given a third way which we might call the "blazing fast
  db> path"; it's not executed at all.

Right--along with the empty string :).

  db> Which raises the question: why wasn't the fast path in use in the
  db> truss output I showed? The answer is apparently that the generated
  db> Perl makefiles have an explicit SHELL=/bin/sh which disables the
  db> fast path.

Are you sure?  I'm surprised because there's some code in job.c which
checks the value of the SHELL variable to see whether it looks like a
valid shell; it basically does a strcmp() with "/bin/sh" and if it's
different it uses the slow path.

If this is broken we should definitely investigate.

Hm, I just ran a test and I don't think it invoked a shell:

    SHELL = /bin/sh
    all: ; @echo hi

-- 
-------------------------------------------------------------------------------
 Paul D. Smith <address@hidden>          Find some GNU make tips at:
 http://www.gnu.org                      http://make.paulandlesley.org
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist




reply via email to

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