bugmake - Bugs: bug #63639, Make syntax inconsistencies...

 
 

bug #63639: Make syntax inconsistencies (perhaps old, no way to tell)

Submitter:  None
Submitted:  Tue 10 Jan 2023 11:54:24 AM UTC
   
 
Severity:  3 - Normal Item Group:  Bug
Status:  Not A Bug Privacy:  Public
Assigned to:  None Open/Closed:  Closed
Component Version:  3.81 Operating System:  None
Fixed Release:  None Triage Status:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Sat 14 Jan 2023 04:08:08 PM UTC, comment #2: 

Just to note:

# Issue with grouped targets
target&: prereqs
#is not the same as
target &: prereqs
#The former works, the latter (with a space) tries to find a prereq called &

The comment at the end of this is not correct.

In GNU Make 3.81, the first rule target&: prereqs will cause make to try to build a target named, literally, target& (you can see this by adding a recipe that shows the value of the $@ automatic variable).

The second rule target &: prereqs will declare two targets: one named target and one named &.  It won't "try to create a prereq called &".

Paul D. Smith <psmith>
Group administrator
Sat 14 Jan 2023 04:01:52 PM UTC, comment #1: 

You are using a version which does not support these features.

GNU Make 3.81 was released in 2006 (17 years ago).  You should be reviewing the documentation that came with the version of GNU Make you are using, not the online documentation for the latest released version.

Assignment operators on define blocks were added in GNU Make 3.82.

Grouped targets were added in GNU Make 4.3.

You can view the GNU Make NEWS file online to see which features have been added since GNU Make 3.81:

https://git.savannah.gnu.org/cgit/make.git/tree/NEWS

Paul D. Smith <psmith>
Group administrator
Tue 10 Jan 2023 11:54:24 AM UTC, original submission:  

I've been working with a makefile where I found the following in 3.81.  I am assuming these are old bugs or intended behaviour and I am lumped with a legacy version. I have no to test in a newer version as I can't easily install newer tools.

# Issue with grouped targets
target&: prereqs
#is not the same as
target &: prereqs
#The former works, the latter (with a space) tries to find a prereq called &

# Inconsistency with define block
define func
...
endef
#is not the same as
define func =
...
endef
# Even though the docs say it should be (make manual section 3.7, Variable Assignment)



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
    2023-01-14 psmith StatusNone Not A Bug
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code