bugmake - Bugs: bug #45252, $(MAKE) not recognized in output...

 
 

bug #45252: $(MAKE) not recognized in output of $(call)

Submitter:  None
Submitted:  Wed 03 Jun 2015 06:36:58 PM UTC
   
 
Severity:  3 - Normal Item Group:  Bug
Status:  Not A Bug Privacy:  Public
Assigned to:  None Open/Closed:  Closed
Component Version:  4.2 Operating System:  Any
Fixed Release:  None Triage Status:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Wed 03 Jun 2015 07:11:01 PM UTC, comment #2: 

I should point out, you CAN add the '+' into the variable; this will work:


define foo
        +$(MAKE) bar
endef

default:
        $(call foo)

bar:


Obviously this requires that the variable expansion appears as the first thing in the recipe; it won't work to do something like:


define foo
        +$(MAKE) bar
endef

default:
        @echo hi ; $(call foo)

bar:


Paul D. Smith <psmith>
Group administrator
Wed 03 Jun 2015 07:08:20 PM UTC, comment #1: 

This is not a bug.  The documentation clearly discusses this in http://www.gnu.org/software/make/manual/html_node/MAKE-Variable.html :

As a special feature, using the variable 'MAKE' in the recipe of a rule alters the effects of the '-t' ('--touch'), '-n' ('--just-print'), or '-q' ('--question') option.  Using the 'MAKE' variable has the same effect as using a '+' character at the beginning of the recipe line.  This special feature is only enabled if the 'MAKE' variable appears directly in the recipe: it does not apply if the 'MAKE' variable is referenced through expansion of another variable.  In the latter case you must use the '+' token to get these special effects.

Paul D. Smith <psmith>
Group administrator
Wed 03 Jun 2015 06:36:58 PM UTC, original submission:  

A sub-make invoked by `$(call foo)` is not recognized as a sub-make, so a `+' must be added to the command returned by foo for `make -jN` to work. Example follows.


define foo
        $(MAKE) bar
endef

default:
        $(call foo)

bar:


Anonymous

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by psmith (Posted a comment)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2015-06-03 psmith StatusNone Not A Bug
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code