[CMake] add_subdirectory inheritance

Kent Williams nkwmailinglists at gmail.com
Tue Apr 17 11:58:38 EDT 2012


Frankly, I don't entirely understand what the problem is, or what your
proposed solution is.

What is it that you don't want the subdirectory context to inherit?

On Tue, Apr 17, 2012 at 10:30 AM, irukandji <irukandji at voidptr.eu> wrote:
> Hi,
>
> (as no one answered to my previous email, let me add this: multiplatform
> project with few million lines
> of code, sheer size of the project is not allowing to turn around whole
> directory tree as price / performance
> is a very relevant factor and even rewriting makefiles/vcprojs to cmake will
> take months)
>
> The add_subdirectory inheritance striked which is practically a show
> stopper, it was already discussed here
> http://www.mail-archive.com/cmake@cmake.org/msg34291.html What was proposed
> (DONT_INHERIT) was a great idea
> and improvement to versability of CMake and also harmless for backward
> compatibility so i dont really
> understand why forcing subproject to inherit all the settings.
>
> Yes, what is added with add_subdirectory is not a child but a sibling or
> even some other part of the tree
> but the point is that it doesnt stop the cmake from building it correctly
> but this inheritance is a problem
> as it adds include directories to wrong versions of headers in public libs
> (due to bugs in different versions,
> affecting different platforms,... the unification is impossible), the flags
> are used on wrong places etc.
>
> Is there a way to workaround it?
>
> Thank you.
>
> --
>
> 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