[CMake] Cmake Dependency Generation with Compiler Specific Plugins
Mathias Gaunard
mathias.gaunard at ens-lyon.org
Thu Mar 17 12:18:21 EDT 2011
On 28/07/2010 15:34, Brad King wrote:
> On 07/27/2010 06:48 PM, Russell Harmon wrote:
>> We're looking to use cmake on a project which has some dependencies
>> which are not properly picked up by cmake's dependency scanner. I'm not
>> looking to fix the scanner, because I feel the scanner is fundamentally
>> broken:
>
> Yes, it certainly has some limitations. I agree that the solution is
> not to fix the current scanner. I've considered using the "wave" c++
> preprocessor library but it is problematic to locate all the implicit
> include directories and preprocessor definitions for each compiler.
> Using the compiler itself to get dependencies is much better.
>
> [...]
>> I would have (tried to) made these changes to cmake already, but since
>> this is both a non-trivial change and an architectural change, I felt it
>> necessary to get an ok from you before I changed anything.
>
> I'm interested in seeing a solution to this problem. Let's
> discuss the design here first though. What interface do you
> propose?
>
Has any progress been made on this? I really need this feature.
The Boost C++ libraries use such includes to generate their
meta-programmation code.
Several hardware abstraction libraries use such systems to include the
correct files for the architectures configured.
Without correct dependencies, cmake cannot be used reliably without a
full clean.
This is especially important when you want to deploy cmake for
continuous integration solutions. Those compile and run all tests
everytime someone does a commit, and there you want to avoid recompiling
unnecessary code.
In the meantime, is there a way to add those dependencies from a
CMakeLists.txt file? OBJECT_DEPENDS doesn't seem to work.
More information about the CMake
mailing list