views:

33

answers:

1

After doing a light search on the Lazarus site I've come to the conclusion that this question has been asked some times but I haven't found an answer, so I'll ask my SO peers.

Is there a a way to create a Makefile to replicate the action of the Lazarus IDE when it compiles a project.

If so I really don't mind if it's makefile.fpc or just plain makefile, I just want some pointers on how to get to it.

BTW, I've tried the option to enable the Makefile on the Lazarus options. Doesn't work.

+1  A: 

Afaik the key is "lazbuild", which is the cmdline build tool.

But no, afaik there is no makefile generation option, and I doubt there will ever be one.

FPC/lazarus use makefiles internally, to iterate over packages, but they don't generate a makefile for each compile like other systems do.

Marco van de Voort
So does Lazarus just issue a VERY LONG command line with all the paths on it?
Gustavo Carreno
Afaik yes. It theory it could also write those to file first
Marco van de Voort
@Marco And I suppose you're not on the Lazarus team right? :) So no use in me asking for that feature to you.
Gustavo Carreno
Hummm, looking at lazbuild on the wiki and extrapolating on what it does internally, I could probably do some shell magic if I get time to grok lazbuild's source... Interesting. Or, use lazbuild in the chain. I'll have to give this thought some more time/investigation.
Gustavo Carreno
No, I'm FPC team
Marco van de Voort