cmake parallel make problem.

Richard Shaw hobbes1069 at gmail.com
Tue Jan 10 14:35:02 UTC 2012


On Tue, Jan 10, 2012 at 8:28 AM, Laurent Rineau
<laurent.rineau__fedora at normalesup.org> wrote:
> Le mardi 10 janvier 2012 08:18:18 Rex Dieter a écrit :
>> Richard Shaw wrote:
>> > I've gone through the CMakeLists.txt and added "add_dependencies(..."
>> > but I think that's redundant because target_link_libraries is getting
>> > set properly.
>>
>> I'm not sure this is redundant, as I would imaging it would be hard to infer
>> the origin of the target_link_library (ie, if it's local or not).
>>
>> (I'll try to look into it, and let you know if I find anything that
>> indicates otherwise).
>
> In target_link_library(..), if we want to link with libFooBar.so, that is
> build as the target FooBar in the same project, we can use the name of the
> target "FooBar" instead of "/path/to/libFooBar.so". That way, CMake creates
> the dependency itself.

If I understand you correctly I'm pretty sure it's already doing that.
All of the arguments passed to target_link_libraries are target names.

Thanks,
Richard


More information about the devel mailing list