[CMake] Generated Files Dependencies
Mike Krus
mike at mve.com
Wed Jun 5 09:51:43 EDT 2013
Hi
sorry for the delay. Yes, it indeed seems to be limited to the ninja generator. When I use Makefiles it all works fine (well, apart from it particularly slow which is why I switched to ninja in the first place ;-))
Also to note that I get he same rebuild-everything behaviour with files generated by moc or uic (from the Qt toolset).
Any ideas on how to track it down?
Mike
On 28 May 2013, at 20:26, Bill Hoffman <bill.hoffman at kitware.com> wrote:
> On 5/27/2013 4:45 PM, Mike Krus wrote:
>> Hi
>>
>> I've started to use Protocol Buffers in my project.
>>
>> .proto files gets "compiled" into c++ .cc and .h files using the
>> PROTOBUF_GENERATE_CPP that comes with CMake (2.8.10, Ninja
>> generator).
>>
>> It all works fine except that the generated .cc and .h files become
>> dependencies of all the other files in the library, so if I change
>> the .proto file, the .cc and .h get regenerated (good), but then my
>> entire library gets recompiled (not just the files that #include the
>> generated .h file, bad!).
>>
>> Is there an easy way of stopping this? Is it a CMake bug?
>
> This maybe a ninja bug. Can you try it with makefiles?
>
> -Bill
>
> --
>
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.cmake.org/mailman/listinfo/cmake
More information about the CMake
mailing list