bugmake - Bugs: bug #13401, MAKEFILES indirect include...

 
 

bug #13401: MAKEFILES indirect include incorrectly supplies default goal

Submitted by:  None
Submitted on:  Tue 14 Jun 2005 03:08:58 PM UTC  
 
Severity: 3 - NormalItem Group: Bug
Status: FixedPrivacy: Public
Assigned to: Paul D. Smith <psmith>Open/Closed: Closed
Component Version: 3.80Operating System: POSIX-Based
Fixed Release: 3.82Triage Status: None

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sat 13 Jun 2009 11:10:11 PM UTC, comment #1:

Fixed. Thanks.

Paul D. Smith <psmith>
Project AdministratorIn charge of this item.
Tue 14 Jun 2005 03:08:58 PM UTC, original submission:

The documentation for the MAKEFILES variable says "the default goal is never
taken from one of these makefiles". The set of makefiles described below
demonstrate that if a file in MAKEFILES includes another file which contains a
goal definition, that goal gets used as the default goal. While the
documentation for MAKEFILES doesn't explicitly discuss this situation, I think
the present behavior is certainly contrary to reasonable expectations.

To test, create separate files from the makefiles described below, all in a
single directory, and invoke make in that directory. The goal called
indirect_goal from include_bug_indirect.mk will be run, printing the message

"MAKEFILES indirectly included goal used as default."

The expected (and I believe correct behavior) is to instead run the all goal
from include_bug_recurse.mk, printing the message

"This should be the default goal."

The makefiles are:

---------- Makefile ----------
all: ; $(MAKE) -f include_bug_recurse.mk MAKEFILES=include_bug_include.mk

---------- include_bug_recurse.mk ----------
all: ; @echo This should be the default goal.

---------- include_bug_indirect.mk ----------
.PHONY: indirect_goal
indirect_goal: ; @echo MAKEFILES indirectly included goal used as default.

---------- include_bug_include.mk ----------
include include_bug_indirect.mk

---------- (end of makefiles) ----------

Anonymous

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

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

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 28 Jul 2010 06:22:01 AM UTCpsmithFixed Release4.0=>3.82
    Sat 13 Jun 2009 11:10:10 PM UTCpsmithStatusNone=>Fixed
      Assigned toNone=>psmith
      Open/ClosedOpen=>Closed
      Fixed ReleaseNone=>4.0

    Back to the top


    Powered by Savane 3.1-cleanup1