On Sat, 2013-02-23 at 17:28 +0000, Ian Lynagh wrote: > On Sat, Feb 23, 2013 at 06:57:27AM +0200, Shachar Shemesh wrote: > > > > What I'm also interested in is why .SECONDARY made everything slow. > > I've put a cut-down makefile demonstrating this here: > http://urchin.earth.li/~ian/tmp/Makefile
I haven't looked deeply into this; however handling an intermediate prerequisite is more expensive than handling a normal prerequisite. By adding the .SECONDARY: target with no prerequisites you're essentially declaring every single file in the makefile as an intermediate file. That's causing your slowdowns. There is probably an opportunity here to add some kind of short-circuiting (I think make is doing the same work multiple times in this situation). I've never really been clear on the purpose and use of .SECONDARY; the comments in both the GNU make manual and in the code seem odd to me. I would really appreciate anyone out there who is using this (either for specific targets or all by itself as in this example) to explain why they use it / what they need it for. _______________________________________________ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make