Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-19 Thread Todd Greer
Principal Scientist, Affinegy, Inc. From: cmake-boun...@cmake.org [mailto:cmake-boun...@cmake.org] On Behalf Of Ansis Malinš Sent: Monday, February 4, 2013 2:23 AM To: cmake Subject: [CMake] When should I use add_subdirectory and when ExternalProject? If I have a dependency (e.g. SDL2

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-05 Thread Alexander Neundorf
On Monday 04 February 2013, David Cole wrote: The OpenChemistry project ( https://github.com/OpenChemistry/openchemistry ) is a very good example of a SuperBuild project that builds all of its external dependencies via ExternalProject, and then all of its git submodules (internal dependencies

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-05 Thread Jean-Christophe Fillion-Robin
Hi Alex, You could probably pass the CMAKE_INSTALL_PREFIX option. For example: https://github.com/Slicer/Slicer/blob/master/SuperBuild/External_DCMTK.cmake#L44 Hth Jc On Tue, Feb 5, 2013 at 1:10 PM, Alexander Neundorf a.neundorf-w...@gmx.netwrote: On Monday 04 February 2013, David Cole

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-05 Thread David Cole
-Original Message- From: Alexander Neundorf a.neundorf-w...@gmx.net To: cmake cmake@cmake.org Sent: Tue, Feb 5, 2013 1:09 pm Subject: Re: [CMake] When should I use add_subdirectory and when ExternalProject? On Monday 04 February 2013, David Cole wrote: The OpenChemistry

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-05 Thread Alexander Neundorf
On Tuesday 05 February 2013, David Cole wrote: -Original Message- From: Alexander Neundorf a.neundorf-w...@gmx.net To: cmake cmake@cmake.org Sent: Tue, Feb 5, 2013 1:09 pm Subject: Re: [CMake] When should I use add_subdirectory and when ExternalProject? On Monday 04 February 2013

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-05 Thread David Cole
-Original Message- From: Alexander Neundorf a.neundorf-w...@gmx.net To: David Cole dlrd...@aol.com Cc: cmake cmake@cmake.org Sent: Tue, Feb 5, 2013 2:50 pm Subject: Re: [CMake] When should I use add_subdirectory and when ExternalProject? On Tuesday 05 February 2013, David Cole

[CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Ansis Māliņš
If I have a dependency (e.g. SDL2) that seems to work with add_subdirectory just fine, should I still use ExternalProject_Add instead? Given both ways work, what should I prefer? What are the tradeoffs? -- Powered by www.kitware.com Visit other Kitware open-source projects at

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Ansis Māliņš
SDL installation? But there is no such thing. At least not on Windows. ... Right? On Mon, Feb 4, 2013 at 1:10 PM, Michael Wild them...@gmail.com wrote: In that case, clearly ExternalProject_Add. It is an external dependency, and should be treated as such. If a users have SDL already installed

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Michael Wild
I don't know about Windows, but then you might have a team that shares a common SDL build on a network drive, and then references that using the ExternalProject feature instead of building this external dependency over and over again. On Mon, Feb 4, 2013 at 12:26 PM, Ansis Māliņš

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Theodore Papadopoulo
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/04/2013 09:23 AM, Ansis Māliņš wrote: If I have a dependency (e.g. SDL2) that seems to work with add_subdirectory just fine, should I still use ExternalProject_Add instead? Given both ways work, what should I prefer? What are the

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Michael Wild
If your project is open source and you want to have any chance of it ever being included in any of the major Linux distros without making somebody very angry at you, forget about add_subdirectory() for external dependencies. On Mon, Feb 4, 2013 at 3:29 PM, Theodore Papadopoulo

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Kent Williams
They are two different things entirely. add_subdirectory is used when you have a project structured hierarchically in directories and subdirectories, but you want the entire project configured at one time. ExternalProject is used to download, configure and build a project that is a prerequisite

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Ansis Māliņš
SuperBuild pattern Tell me all about it! -- 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

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Michael Wild
In a SuperBuild, all projects, even your own, are built by one large super-build project that contains a series of ExternalProject_Add calls. That's all there is to it. On Mon, Feb 4, 2013 at 4:23 PM, Ansis Māliņš ansis.mal...@gmail.com wrote: SuperBuild pattern Tell me all about it! --

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread Kent Williams
The real world example is Slicer -- http://www.slicer.org/pages/DeveloperOrientation This is rather a large and complex project and the way they do somethings is hard to decode. Make sure you read through and understand this:

Re: [CMake] When should I use add_subdirectory and when ExternalProject?

2013-02-04 Thread David Cole
-Original Message- From: Ansis Māliņš ansis.mal...@gmail.com To: Kent Williams nkwmailingli...@gmail.com Cc: cmake cmake@cmake.org Sent: Mon, Feb 4, 2013 10:24 am Subject: Re: [CMake] When should I use add_subdirectory and when ExternalProject? SuperBuild pattern Tell me all about