[CMake] Q: cmExportFileGenerator::GenerateImportedFileCheckLoop

2012-03-11 Thread Mathieu Malaterre
Hi there,

  CMake 2.8.7 recently added a new behavior when reading export files:

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=a2be068c

  I perfectly understand the goal here, I think this is a great user
functionality. However this breaks the old behavior of cmake being
tolerant with missing files. This is particularly difficult to handle
for large package such as VTK. Currently in debian we split the VTK
package into sub-packages:
 * C++ dev,
 * Qt dev,
 * TCL,
 * Java and
 * Python bindings.
  Since there is a single export file, we are now forced to install
all those sub-packages while in the past we could bypass any cmake
internals checks and only install -say- C++-dev package.

  Would it make sense to conditionally remove this automatic check ?
Something like:

diff --git a/Source/cmExportFileGenerator.cxx b/Source/cmExportFileGenerator.cxx
index c4f5dfb..6eaf4d5 100644
--- a/Source/cmExportFileGenerator.cxx
+++ b/Source/cmExportFileGenerator.cxx
@@ -384,7 +384,7 @@
cmExportFileGenerator::GenerateImportedFileCheckLoop(std::ostream& os)
   os << "# Loop over all imported files and verify that they actually exist\n"
 "FOREACH(target ${_IMPORT_CHECK_TARGETS} )\n"
 "  FOREACH(file ${_IMPORT_CHECK_FILES_FOR_${target}} )\n"
-"IF(NOT EXISTS \"${file}\" )\n"
+"IF(NOT CMAKE_SKIP_IMPORT_CHECK_FILES AND NOT EXISTS
\"${file}\" )\n"
 "  MESSAGE(FATAL_ERROR \"The imported target \\\"${target}\\\""
 " references the file\n"
 "   \\\"${file}\\\"\n"

Thanks for comments,

-- 
Mathieu
--

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


Re: [CMake] Triggers for isysroot

2012-03-11 Thread Michael Wild
On 03/11/2012 09:07 PM, P. Martin wrote:
> 
> On Mar 11, 2012, Michael Wild  wrote: 
>> On 03/11/2012 07:46 AM, P. Martin wrote:
>>> In CMake 2.8.7 on Lion, is there anything that would trigger -isysroot
>>> to appear in flags.make for a cxx program when there is no code by the
>>> devs to specifically add a -isysroot?  Thanks.
>>
>>
>> Yes, the CMAKE_OSX_SYSROOT in the cache does that.
>>
>> Michael
> 
> 
> I made a hello world program in c++, building in a CMake project.
> That variable gets defined during cmake.  It does not trigger the
> inclusion of -isysroot /some/path/to/an/sdk in flags.make.
> Thank you for your reply.

I think it depends on what you set it to. If it's the default SDK, it
doesn't get included. It could also be that the
CMAKE_OSX_DEPLOYMENT_TARGET variable plays into this.

Sadly, my Mac died quiet some time ago, so I can't check right now...

Michael

--

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


Re: [CMake] top level make

2012-03-11 Thread Totte Karlsson

See the ExternalProject module [1].


[1] http://www.cmake.org/cmake/help/cmake-2-8-docs.html#module:ExternalProject

cool!

Thanks,
Totte
--

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


Re: [CMake] top level make

2012-03-11 Thread Michael Hertling
On 03/11/2012 10:27 PM, Totte Karlsson wrote:
> Hi,
> My project depends on several third party libraries, e.g. vtk. I wonder, if 
> it 
> is possible to setup using CMake so that when building my project, necessary 
> third party libs are built as well.
> 
> Or is it advisable to keep it separate?
> 
> My src folder structure is
> top\
> -\mySource
> -\ThirdParty\vtk
> -\ThirdParty\SomeOther libs
> 
> Cheers,
> Totte

See the ExternalProject module [1].

Regards,

Michael

> [1] http://www.cmake.org/cmake/help/cmake-2-8-docs.html#module:ExternalProject
--

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


[CMake] top level make

2012-03-11 Thread Totte Karlsson

Hi,
My project depends on several third party libraries, e.g. vtk. I wonder, if it 
is possible to setup using CMake so that when building my project, necessary 
third party libs are built as well.


Or is it advisable to keep it separate?

My src folder structure is
top\
-\mySource
-\ThirdParty\vtk
-\ThirdParty\SomeOther libs

Cheers,
Totte

--

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


Re: [CMake] Triggers for isysroot

2012-03-11 Thread P. Martin

On Mar 11, 2012, Michael Wild  wrote: 
> On 03/11/2012 07:46 AM, P. Martin wrote:
> > In CMake 2.8.7 on Lion, is there anything that would trigger -isysroot
> > to appear in flags.make for a cxx program when there is no code by the
> > devs to specifically add a -isysroot?  Thanks.
> 
> 
> Yes, the CMAKE_OSX_SYSROOT in the cache does that.
> 
> Michael


I made a hello world program in c++, building in a CMake project.
That variable gets defined during cmake.  It does not trigger the
inclusion of -isysroot /some/path/to/an/sdk in flags.make.
Thank you for your reply.
--

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


Re: [CMake] Triggers for isysroot

2012-03-11 Thread Michael Wild
On 03/11/2012 07:46 AM, P. Martin wrote:
> In CMake 2.8.7 on Lion, is there anything that would trigger -isysroot
> to appear in flags.make for a cxx program when there is no code by the
> devs to specifically add a -isysroot?  Thanks.


Yes, the CMAKE_OSX_SYSROOT in the cache does that.

Michael
--

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