Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Eclipse vs make: which takes longer to "do nothing"?
Eclipse vs make: which takes longer to "do nothing"? [message #899895] Thu, 02 August 2012 13:53 Go to next message
Eclipse UserFriend
Hi,

I used 64 bit linux, cmake 2.8.7 to create a complex Juno CPP project. The project takes about 4 minutes to build from scratch. After it is built I might attempt to rebuild it. The following question is about "rebuilding" a project that is already built. Ideally this will take 0.0 seconds as nothing needs to be done.

From an xterm I cd to the build directory and type "/usr/bin/gmake -j4". This takes 0.8 seconds.

From eclipse I select the "all" make target and build that. This uses 4 processors also, and according to the make target, issues the identical command "/usr/bin/gmake -j4". However, it takes 3 seconds.

Q1: Why does it take longer to "not build" in eclipse than it takes to "not build" from an xterm?
a) eclipse dumps output to a "Console View" which is very slow
b) eclipse parses the output, which is very slow
c) [your idea here]

Q2: Eclipse supposedly is using the command "/usr/bin/gmake -j4" to perform the build. Why when I type this command in an xterm, I do not see the same output as Eclipse shows in the "Console View"?
a) Eclipse does not use the listed "build command" to perform the build. It uses a bunch of secret stuff.
b) [your idea here]

xterm:
BuildDebug $ /usr/bin/gmake -j4
[  1%] Built target VidtraccUtility
[  2%] Built target SimlibThread
   ...
[ 92%] Built target VIDTRACC
[100%] Built target Stabilizer
BuildDebug $ 


eclipse
10:49:55 **** Build of project uavlib@BuildDebug ****
/usr/bin/gmake -j4 all 
/usr/bin/cmake -H/home/cstankevitz/Work/2012-06-01_uavlib/uavlib -B/home/cstankevitz/Work/2012-06-01_uavlib/BuildDebug --check-build-system CMakeFiles/Makefile.cmake 0
/usr/bin/cmake -E cmake_progress_start /home/cstankevitz/Work/2012-06-01_uavlib/BuildDebug/CMakeFiles /home/cstankevitz/Work/2012-06-01_uavlib/BuildDebug/CMakeFiles/progress.marks
/usr/bin/gmake -f CMakeFiles/Makefile2 all
gmake[1]: Entering directory `/home/cstankevitz/Work/2012-06-01_uavlib/BuildDebug'
...
[ 98%] Built target Stabilizer
[100%] Built target VIDTRACC
gmake[1]: Leaving directory `/home/cstankevitz/Work/2012-06-01_uavlib/BuildDebug'
/usr/bin/cmake -E cmake_progress_start /home/cstankevitz/Work/2012-06-01_uavlib/BuildDebug/CMakeFiles 0

10:49:58 Build Finished (took 2s.930ms)
Re: Eclipse vs make: which takes longer to "do nothing"? [message #900488 is a reply to message #899895] Tue, 07 August 2012 05:39 Go to previous message
Eclipse UserFriend
Quote:
a) eclipse dumps output to a "Console View" which is very slow
b) eclipse parses the output, which is very slow

Yes, both are slow (but you get a list of errors/warnings!)
c) [your idea here]
Because Eclipse does not know which binaries were changed/created during the external build it has to scan the entire workspace. You can limit the search scope in Project Properties->C/C++ General_>Paths and Symbols->Output location


Quote:
Q2: Eclipse supposedly is using the command "/usr/bin/gmake -j4" to perform the build. Why when I type this command in an xterm, I do not see the same output as Eclipse shows in the "Console View"?
a) Eclipse does not use the listed "build command" to perform the build. It uses a bunch of secret stuff.

Eclipse does exactly what you tell it! For me it seems that you called make in different directories. Therefore different Makefiles are actually build!
Previous Topic:Which GNU tools are bundled with CDT?
Next Topic:Compiling updated code
Goto Forum:
  


Current Time: Thu Jun 19 09:54:06 EDT 2025

Powered by FUDForum. Page generated in 0.04475 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top