Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-09-10 Thread Brad King
On 08/30/2013 06:49 AM, Stephen Kelly wrote: I've pushed the IMPORTED-target-SYSTEM-includes topic to my clone for review. It introduces a policy-controlled default handling of INTERFACE_INCLUDE_DIRECTORIES from IMPORTED targets as SYSTEM. It also introduces a default-initialized target

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-09-10 Thread Stephen Kelly
Brad King wrote: On 08/30/2013 06:49 AM, Stephen Kelly wrote: I've pushed the IMPORTED-target-SYSTEM-includes topic to my clone for review. It introduces a policy-controlled default handling of INTERFACE_INCLUDE_DIRECTORIES from IMPORTED targets as SYSTEM. It also introduces a

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-09-10 Thread Brad King
On 09/10/2013 12:20 PM, Stephen Kelly wrote: Brad King wrote: Do we really need a policy? Without one, projects will magically start building with fewer unnecessary warnings. I'm fine with not controlling this with a policy. An abundance of caution led me to introduce one for it, but I'll

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-08-30 Thread Stephen Kelly
Stephen Kelly steveire@... writes: Matthew Woehlke wrote: Perhaps that is a misreading on my part, but I was getting the impression this change would make it so that imported targets can only ever be SYSTEM. I didn't really make that clear as the discussion developed, but yes, I think

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-26 Thread Brad King
On 07/25/2013 01:25 PM, Stephen Kelly wrote: Either way, the tll() SYSTEM option could still be useful. I'll add that tomorrow. Can we wait until after 2.8.12 to add this? We're already adding the new tll signature and policy CMP0023. I'd like to avoid confusion of new and old signatures

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-26 Thread Stephen Kelly
Brad King wrote: On 07/25/2013 01:25 PM, Stephen Kelly wrote: Either way, the tll() SYSTEM option could still be useful. I'll add that tomorrow. Can we wait until after 2.8.12 to add this? We're already adding the new tll signature and policy CMP0023. I'd like to avoid confusion of

[cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Stephen Kelly
Hi, In response to https://bugreports.qt-project.org/browse/QTBUG-32599 I first considered adding something like if(NOT QT_INCLUDE_DIRS_NO_SYSTEM) set_property(TARGET Qt5::Core SYSTEM_INTERFACE_INCLUDE_DIRECTORIES ${Qt5Core_INCLUDE_DIRS} ) endif() for each imported

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Brad King
On 07/25/2013 09:16 AM, Stephen Kelly wrote: target_link_libraries(foo SYSTEM Qt5::Core) That looks okay to me so long as SYSTEM must always be the first keyword. We could also consider adding it only to the modern (newest) keyword signature to encourage conversion to it. Should we treat the

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Stephen Kelly
Brad King wrote: On 07/25/2013 09:16 AM, Stephen Kelly wrote: target_link_libraries(foo SYSTEM Qt5::Core) That looks okay to me so long as SYSTEM must always be the first keyword. Yes, that's how I've implemented it currently. We could also consider adding it only to the modern (newest)

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Matthew Woehlke
On 2013-07-25 11:25, Stephen Kelly wrote: Brad King wrote: On 07/25/2013 09:16 AM, Stephen Kelly wrote: Should we treat the INTERFACE_INCLUDE_DIRECTORIES of all IMPORTED targets as SYSTEM includes automatically? I don't think so because one could be importing targets from a dependency that

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Stephen Kelly
Matthew Woehlke wrote: On 2013-07-25 11:25, Stephen Kelly wrote: Brad King wrote: On 07/25/2013 09:16 AM, Stephen Kelly wrote: Should we treat the INTERFACE_INCLUDE_DIRECTORIES of all IMPORTED targets as SYSTEM includes automatically? I don't think so because one could be importing targets

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Brad King
On 07/25/2013 12:22 PM, Stephen Kelly wrote: library A should have a unit test which attempts to compile all of its headers with all warnings enabled. In Qt every module has a 'headersclean' unit test which does exactly that. While this is a good idea we're not going to assume every project

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Matthew Woehlke
On 2013-07-25 13:25, Stephen Kelly wrote: Brad King wrote: On 07/25/2013 12:22 PM, Stephen Kelly wrote: library A should have a unit test which attempts to compile all of its headers with all warnings enabled. In Qt every module has a 'headersclean' unit test which does exactly that. While

Re: [cmake-developers] target_link_libraries, IMPORTED targets and SYSTEM includes

2013-07-25 Thread Stephen Kelly
Matthew Woehlke wrote: On 2013-07-25 13:25, Stephen Kelly wrote: Brad King wrote: On 07/25/2013 12:22 PM, Stephen Kelly wrote: library A should have a unit test which attempts to compile all of its headers with all warnings enabled. In Qt every module has a 'headersclean' unit test which