bugmake - Bugs: bug #57681, 2nd expansion only for required...

 
 

bug #57681: 2nd expansion only for required targets

Submitted by:  Yannick DAVELUY <ydaveluy>
Submitted on:  Mon 27 Jan 2020 09:02:13 PM UTC  
 
Severity:  3 - Normal Item Group:  Enhancement
Status:  None Privacy:  Public
Assigned to:  None Open/Closed:  Open
Component Version:  4.3 Operating System:  Any
Fixed Release:  None Triage Status:  None

Add a New Comment (Rich Markup)
   

You are not logged in

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

 

Mon 27 Jan 2020 09:02:13 PM UTC, original submission:  

Hello,

The second expansion of the prerequisites should be done only when a target is needed. This could improve performances.

With this design it will be possible to include dependencies file only when needed.

Actually the next pattern is often used:

deps:=$(patsubst %.o,%.d,${objects})

-include ${deps}
%.o : %.c
        ${GCC} ...

With this pattern all existing dependencies files are included even if only one file needs to be recompiled.

If 2nd expansions were performed only when a target is needed, we could write previous pattern like this:

%.o : %.c $$(get_dependencies %.d)

get_dependencies can be a user or builtin function that read the dependency file and return the list of prerequisites.

I developed this enhancement in the following repo:
https://github.com/ydaveluy/make/tree/feature_2nd_expansion_improvement

Thanks to give me your feedback.

Yannick

Yannick DAVELUY <ydaveluy>

 

(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 ydaveluy (Submitted the item)
  •  

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

    Only logged-in users can vote.

     

     

     

    No changes have been made to this item

    Back to the top


    Powered by Savane 3.5