<br><br><div class="gmail_quote">On Thu, Mar 12, 2009 at 10:56 PM, Alexander Neundorf <span dir="ltr"><<a href="mailto:a.neundorf-work@gmx.net">a.neundorf-work@gmx.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="im">On Thursday 12 March 2009, Bill Hoffman wrote:<br>
> Alexander Neundorf wrote:<br>
> >> I'm using CMake 2.6.2 and Eclipse CDT5 (not CDT4, could this be an<br>
> >> issue?)<br>
> ><br>
> > I don't think so.<br>
> > We could add some special variable, like<br>
> > CMAKE_MAKEFILE_PROJECT_FLAGS or CMAKE_MAKEFILE_PARALLELITY, and use this<br>
> > in the makefile-based generators to set the "-jx" parameter for make. But<br>
> > then again, this shouldn't be hardcoded in the CMakeLists.txt, so it<br>
> > could only be a cache variable.<br>
> > Or should cmake try to determine automatically how many cores there are<br>
> > and add "-jx" automatically ? E.g. using sysconf(_SC_NPROCESSORS_ONLN) ?<br>
> > This could also be disabled by default and enabled e.g. via an option<br>
> > like CMAKE_AUTOMATIC_PARALLEL_MAKE_INVOCATION or something like this.<br>
><br>
> This sounds like an Eclipse issue... Does this work:<br>
><br>
> <a href="http://dev.eclipse.org/newslists/news.eclipse.tools.cdt/msg15742.html" target="_blank">http://dev.eclipse.org/newslists/news.eclipse.tools.cdt/msg15742.html</a><br>
<br>
</div>From that link:<br>
<br>
> project properties -> C/C++ Build -> Behaviour tab<br>
<br>
I can't find this here.<br>
I have Project -> Properties -> C/C++ Make project<br>
and then there is nothing with parallel builds.<br>
<br>
Can you see that option ?</blockquote><div> </div><div>I have compared two Eclipse projects, one generated manually using custom Makefiles, and another one genereated by CMake with the "Eclipse CDT4 - Unix Makefiles" generator.<br>
Effectively, the former _has_ the <i>project properties -> C/C++ Build -> Behaviour </i>tab, but the CMake project does _not_. Could this be related to the way CMake creates an Eclipse project? I used CDT5 and not 4, could it be version related?<br>
<br>As Alex points out, the closest thing that is available is <i>Project -> Properties -> C/C++ Make project</i>. There, in the Make Builder tab you can set the Build command and add the -j# option. This is a per-project setting and will only work if you build your project by doing <i>Project->Build Project</i> or <i>Project->Build All</i>. It turns out that I had played with this parameter before, and didn't seem to work because I was invoking directly the individual targets (all, foo) from the Make Targets tab of the C/C++ perspective (and these targets have separate build settings).<br>
<br>As I'm quite ignorant on all things Eclipse, could it be possible to use the Build Command specified in <i>Project -> Properties -> C/C++ Make project</i> for each individual target? so that if it changes, this change will be propagated. Right now I'm under the impression that they are decoupled.<br>
<br>Thanks,<br><br>Adolfo<br> <br>P.S. The current workaround seems a good-enough solution for now.<br></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
Alex<br>
<div><div></div><div class="h5">_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.cmake.org/mailman/listinfo/cmake" target="_blank">http://www.cmake.org/mailman/listinfo/cmake</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Adolfo Rodríguez Tsouroukdissian<br><br>Robotics engineer<br>PAL ROBOTICS S.L<br><a href="http://www.pal-robotics.com">http://www.pal-robotics.com</a><br>Tel. +34.93.414.53.47<br>
Fax.+34.93.209.11.09<br>