[SOLVED] I want to modify the Makefile for using distcc
ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I use "make -j4 CC=distcc" to compile a project,and use distccmon-text to check whether distcc is runing.
When I set CC = distcc,and use "make -j4",distcc does not work.
Another thing,is "-j4" can be write in Makefile?So I only implement "make",the distcc and 4 jobs will work.
Console print follow thing when compile:
gcc -o dbus-cleanup-sockets dbus-cleanup-sockets.o
How do I modify the Makefile,console can print like this:
distcc gcc -o dbus-cleanup-sockets dbus-cleanup-sockets.o
Last edited by peng6662001; 10-11-2013 at 08:52 AM.
I write "export CC=distcc" to the PATH,the distcc does not run.
I find many Makefile in sub directory,but I only modify Makefile in root directory.
When I modify All the Makefile,distcc can work normally.
But it is complex to modify all the Makefile,can I set a flag to do that?
When you have "many Makefile" you may also have a "configure"
script in the top directory ?
How to use "./configure" to generate new Makefile's :
$ export CC=distcc && ./configure
Thank you for your anwser.
After I use "./configure CC=distcc",all the Makefile is modify "CC = gcc" to "CC = distcc".
But I want to know how can I modify a parent Makefile,all the sub Makefile will USE "CC = distcc",can this flag inherit from parent to child?
And,how achieve multi jobs by modify parent Makefile instead of call "make -j4"