bug-make
[Top][All Lists]
Advanced

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

[bug #60919] Communicating -j to sub-make not working properly after mak


From: Paul D. Smith
Subject: [bug #60919] Communicating -j to sub-make not working properly after make 4.1
Date: Thu, 15 Jul 2021 13:48:17 -0400 (EDT)
User-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.114 Safari/537.36

Update of bug #60919 (project make):

                  Status:                    None => Not A Bug              
             Open/Closed:                    Open => Closed                 

    _______________________________________________________

Follow-up Comment #1:

Your parent makefile is incorrect.  By adding an explicit -j option to the
submake command line you are forcing the sub-make to run in a mode with no
restrictions on the amount of parallelism; see the documentation:

> If there is nothing looking like an integer after the ā€˜-jā€™ option, there
is no limit on the number of job slots.

If you want to have your sub-makes participate in the jobserver and obey the
limits provided by the make command line, you should remove the -j option from
the submake command line.  In other words, change:


test1:
        sleep .1; echo start test1; sleep .1; cd child; $(MAKE) -j ;  echo end 
test1


to this:


test1:
        sleep .1; echo start test1; sleep .1; cd child; $(MAKE) ;  echo end 
test1


And the same for all other sub-make invocations obviously.

In general you never want to add specific options to the command line of
sub-makes unless you're trying to modify or override the operations that the
user specified when they invoked the top-level make (which should be extremely
rare).

    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?60919>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

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