Building CodeLite in parallel sometimes fails

Discussion about CodeLite development process and patches
tankist02
CodeLite Veteran
Posts: 56
Joined: Thu Sep 22, 2011 11:29 pm
Genuine User: Yes
IDE Question: c++
Contact:

Building CodeLite in parallel sometimes fails

Post by tankist02 »

It looks CodeLite doesn't like when it is built in parallel. For example, when I do the following on a 4-core system:

Code: Select all

make clean
make -j5
sometimes the build fails, sometimes it doesn't. But it is always successful if I don't run multiple jobs:

Code: Select all

make clean
make
This is not a showstopper, but it does take about 4 times longer to build CodeLite.
DavidGH
CodeLite Plugin
Posts: 819
Joined: Wed Sep 03, 2008 7:26 pm
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by DavidGH »

Hi,

Try updating to the latest svn trunk. 2 or 3 days ago, Eran improved configure's -jN behaviour. It now works for me with -j4.
This is not a showstopper, but it does take about 4 times longer to build CodeLite.
If it's still necessary, a workaround is e.g. -j5; -j5; -j5

Regards,

David
tankist02
CodeLite Veteran
Posts: 56
Joined: Thu Sep 22, 2011 11:29 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by tankist02 »

Tested with today's 5172 version. Still fails or doesn't finish with -j5 on a 4-core system. But running make -j5 a few times seems to complete the build.
User avatar
eranif
CodeLite Plugin
Posts: 6373
Joined: Wed Feb 06, 2008 9:29 pm
Genuine User: Yes
IDE Question: C++
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by eranif »

After you updated, did you remember to re-run configure again?

Eran
Make sure you have read the HOW TO POST thread
tankist02
CodeLite Veteran
Posts: 56
Joined: Thu Sep 22, 2011 11:29 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by tankist02 »

Here is my update/build procedure:

make clean
svn update
./configure
make -j5

BTW today's version still didn't finish successfully - I needed to run 'make -j5' a couple of times.
DavidGH
CodeLite Plugin
Posts: 819
Joined: Wed Sep 03, 2008 7:26 pm
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by DavidGH »

Hmm. I just tried exactly that (on a 4-core box; I usually do -j4) and it built just as it should.

One thing that doesn't usually work, at least after a 'make clean', is the "Done, please run sudo make install" message: it's now common for it to appear much too soon, and so is invisible at the end of 'make'. Could this be making you think that the build failed, or do you get an actual error message?
tankist02
CodeLite Veteran
Posts: 56
Joined: Thu Sep 22, 2011 11:29 pm
Genuine User: Yes
IDE Question: c++
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by tankist02 »

Hi David,

Yeah, it looks you are right. There are no make errors (except compilation warnings) during make -j4. The message "Done, please run sudo make install." is indeed buried in output from other build jobs and not easily visible.
foxmuldr
CodeLite Expert
Posts: 120
Joined: Sun May 10, 2009 6:56 am
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by foxmuldr »

On my 6-core AMD64 machine I've seen similar build errors with -j6. This was many months ago though. I fixed it with a workaround to -j2 I believe. I also always assumed this was an error with the GNU toolchain, and not Codelite, btw.
Best regards,
Rick C. Hodgin
www.Visual-FreePro.org
www.LibSF.org
foxmuldr
CodeLite Expert
Posts: 120
Joined: Sun May 10, 2009 6:56 am
Contact:

Re: Building CodeLite in parallel sometimes fails

Post by foxmuldr »

Note: I've been using -j6 recently and it's working again. I can only assume it was a GCC issue, or possibly an issue with Ubuntu's version of GCC as I've since switched to Trisquel and am using GCC 4.5.2.
Best regards,
Rick C. Hodgin
www.Visual-FreePro.org
www.LibSF.org
Post Reply