Re: [CMake] Two phase install?

2016-03-24 Thread Scott Aron Bloom
I am not using a dashboard.. 

What I found is this.. When running a test from a VCXProj system, CMake sets up 
the custom command as follows
Ctest . -C $(Configuration)

The $(Configuration) is a visual studio/devenv variable, that is set by the 
system baed on the current configuration.

However, when running cmake via a "super project" to a "subordinate external 
project" (sorry if my nomenclature is wrong), it runs without the -C option.

Using a custom TEST_COMMAND doesn’t help in the ExternalProject_Add command, 
because for windows VS multi-config setups, the current configuration isn’t 
known as a CMAKE variable at the proper time

So I descided to just "hard code" it in, like you suggested.
Scott

-Original Message-
From: David Cole [mailto:dlrd...@aol.com] 
Sent: Thursday, March 24, 2016 12:30 PM
To: Scott Aron Bloom
Cc: Hendrik Sattler; Alan W. Irwin; cmake@cmake.org
Subject: Re: [CMake] Two phase install?

Are you running a dashboard script (ctest -S script) when this happens? Or 
calling ctest directly with other arguments?

If you are running a -S script, you can specify the configuration to build and 
test in the script itself with the CTEST_CONFIGURATION_TYPE script variable. 
Read the docs here on the ctest_build and ctest_test
steps: https://cmake.org/cmake/help/v3.5/manual/ctest.1.html#ctest-build-step

The ctest_build command also takes a "CONFIGURATION" argument directly, but 
surprisingly, the ctest_test command does not seem to have that arg. 
https://cmake.org/cmake/help/v3.5/command/ctest_build.html
and https://cmake.org/cmake/help/v3.5/command/ctest_test.html

If you're not calling a -S script, I'm not sure how else you can do it besides 
passing "-C Release" on the command line...


HTH,
David C.



On Thu, Mar 24, 2016 at 2:09 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
>
>
> -Original Message-
> From: Hendrik Sattler [mailto:p...@hendrik-sattler.de]
> Sent: Thursday, March 24, 2016 3:54 AM
> To: Alan W. Irwin; Scott Aron Bloom
> Cc: cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
>
>
> Am 24. März 2016 10:14:40 MEZ, schrieb "Alan W. Irwin" 
> <ir...@beluga.phys.uvic.ca>:
>>On 2016-03-24 03:59- Scott Aron Bloom wrote:
>>
>>> That method does NOT work with windows...  And since the visual
>>studio project has the external as a single command, (not sure if its 
>>calling nmake or the new build cmd) the proeject is not run in 
>>parallel.
>>
>>I am pretty sure ExternalProject_Add only works with generators 
>>associated with build commands you can run from the command line such 
>>as make, nmake, jom, ninja, etc..  So, for MSVC the way you arrange 
>>that is avoid all the visual studio generators, and instead use one of 
>>"NMake Makefiles", "NMake Makefiles JOM", or "Ninja".
>
> No. Just as with cmake-generated solutions, you can build those on the 
> command line using msbuild or devenv, the one used by cmake depends on the 
> cmake version. You can even use cmake itself to trigger the right build 
> command for those. Parallel building must be enabled by hand when using 
> msbuild. For devenv, the setting from the IDE is used.
>
> HS
> 
>
> The final hurdle Im hitting.  When ctest is run, on windows I get the 
> complaint that the configuration is not set.
>
> Is there any way to set the -C option to ctest?
>
> Scott
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at: 
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more 
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at 
> http://www.kitware.com/opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Two phase install?

2016-03-24 Thread David Cole via CMake
Are you running a dashboard script (ctest -S script) when this
happens? Or calling ctest directly with other arguments?

If you are running a -S script, you can specify the configuration to
build and test in the script itself with the CTEST_CONFIGURATION_TYPE
script variable. Read the docs here on the ctest_build and ctest_test
steps: https://cmake.org/cmake/help/v3.5/manual/ctest.1.html#ctest-build-step

The ctest_build command also takes a "CONFIGURATION" argument
directly, but surprisingly, the ctest_test command does not seem to
have that arg. https://cmake.org/cmake/help/v3.5/command/ctest_build.html
and https://cmake.org/cmake/help/v3.5/command/ctest_test.html

If you're not calling a -S script, I'm not sure how else you can do it
besides passing "-C Release" on the command line...


HTH,
David C.



On Thu, Mar 24, 2016 at 2:09 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
>
>
> -Original Message-
> From: Hendrik Sattler [mailto:p...@hendrik-sattler.de]
> Sent: Thursday, March 24, 2016 3:54 AM
> To: Alan W. Irwin; Scott Aron Bloom
> Cc: cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
>
>
> Am 24. März 2016 10:14:40 MEZ, schrieb "Alan W. Irwin" 
> <ir...@beluga.phys.uvic.ca>:
>>On 2016-03-24 03:59- Scott Aron Bloom wrote:
>>
>>> That method does NOT work with windows...  And since the visual
>>studio project has the external as a single command, (not sure if its
>>calling nmake or the new build cmd) the proeject is not run in
>>parallel.
>>
>>I am pretty sure ExternalProject_Add only works with generators
>>associated with build commands you can run from the command line such
>>as make, nmake, jom, ninja, etc..  So, for MSVC the way you arrange
>>that is avoid all the visual studio generators, and instead use one of
>>"NMake Makefiles", "NMake Makefiles JOM", or "Ninja".
>
> No. Just as with cmake-generated solutions, you can build those on the 
> command line using msbuild or devenv, the one used by cmake depends on the 
> cmake version. You can even use cmake itself to trigger the right build 
> command for those. Parallel building must be enabled by hand when using 
> msbuild. For devenv, the setting from the IDE is used.
>
> HS
> 
>
> The final hurdle Im hitting.  When ctest is run, on windows I get the 
> complaint that the configuration is not set.
>
> Is there any way to set the -C option to ctest?
>
> Scott
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at: 
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more 
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at 
> http://www.kitware.com/opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Two phase install?

2016-03-24 Thread Scott Aron Bloom


-Original Message-
From: Hendrik Sattler [mailto:p...@hendrik-sattler.de] 
Sent: Thursday, March 24, 2016 3:54 AM
To: Alan W. Irwin; Scott Aron Bloom
Cc: cmake@cmake.org
Subject: Re: [CMake] Two phase install?



Am 24. März 2016 10:14:40 MEZ, schrieb "Alan W. Irwin" 
<ir...@beluga.phys.uvic.ca>:
>On 2016-03-24 03:59- Scott Aron Bloom wrote:
>
>> That method does NOT work with windows...  And since the visual
>studio project has the external as a single command, (not sure if its 
>calling nmake or the new build cmd) the proeject is not run in 
>parallel.
>
>I am pretty sure ExternalProject_Add only works with generators 
>associated with build commands you can run from the command line such 
>as make, nmake, jom, ninja, etc..  So, for MSVC the way you arrange 
>that is avoid all the visual studio generators, and instead use one of 
>"NMake Makefiles", "NMake Makefiles JOM", or "Ninja".

No. Just as with cmake-generated solutions, you can build those on the command 
line using msbuild or devenv, the one used by cmake depends on the cmake 
version. You can even use cmake itself to trigger the right build command for 
those. Parallel building must be enabled by hand when using msbuild. For 
devenv, the setting from the IDE is used.

HS


The final hurdle Im hitting.  When ctest is run, on windows I get the complaint 
that the configuration is not set.

Is there any way to set the -C option to ctest?

Scott
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Two phase install?

2016-03-24 Thread Hendrik Sattler


Am 24. März 2016 10:14:40 MEZ, schrieb "Alan W. Irwin" 
:
>On 2016-03-24 03:59- Scott Aron Bloom wrote:
>
>> That method does NOT work with windows...  And since the visual
>studio project has the external as a single command, (not sure if its
>calling nmake or the new build cmd) the proeject is not run in
>parallel.
>
>I am pretty sure ExternalProject_Add only works with generators
>associated with build commands you can run from the command line such
>as make, nmake, jom, ninja, etc..  So, for MSVC the way you arrange
>that is
>avoid all the visual studio generators, and instead use one of
>"NMake Makefiles", "NMake Makefiles JOM", or "Ninja".

No. Just as with cmake-generated solutions, you can build those on the command 
line using msbuild or devenv, the one used by cmake depends on the cmake 
version. You can even use cmake itself to trigger the right build command for 
those. Parallel building must be enabled by hand when using msbuild. For 
devenv, the setting from the IDE is used.

HS

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Two phase install?

2016-03-24 Thread Alan W. Irwin

On 2016-03-24 03:59- Scott Aron Bloom wrote:


That method does NOT work with windows...  And since the visual studio project 
has the external as a single command, (not sure if its calling nmake or the new 
build cmd) the proeject is not run in parallel.


I am pretty sure ExternalProject_Add only works with generators
associated with build commands you can run from the command line such
as make, nmake, jom, ninja, etc..  So, for MSVC the way you arrange that is
avoid all the visual studio generators, and instead use one of
"NMake Makefiles", "NMake Makefiles JOM", or "Ninja".

Alan

__
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__

Linux-powered Science
__
--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Two phase install?

2016-03-23 Thread Scott Aron Bloom
Just a note.. .

That method does NOT work with windows...  And since the visual studio project 
has the external as a single command, (not sure if its calling nmake or the new 
build cmd) the proeject is not run in parallel.

Scott

-Original Message-
From: CMake [mailto:cmake-boun...@cmake.org] On Behalf Of Scott Aron Bloom
Sent: Wednesday, March 23, 2016 8:53 PM
To: Alan W. Irwin
Cc: cmake@cmake.org
Subject: Re: [CMake] Two phase install?

> Thanks I'm getting close now.
>
> However, for the two sub projects, there doesn’t seem to be a way to run the 
> make stage with -j 6 or any make options.
>
> Am I missing something? I see how to set CMAKE_ARGS but no MAKE_ARGS

Hi Scott:

Some of my further comments are somewhat off your original topic since I 
discuss parallel build issues for the case of larger numbers of projects in the 
superproject, but I thought you might be interested in that case even though 
you just have two projects in your superproject.

For the superproject (epa_build in my case) I configure the 
EPA_PARALLEL_BUILD_COMMAND variable to create the build command that I use for 
all individual projects.  That can be anything accessible from the command-line 
such as nmake in the Windows case and make in the Unix case.  So in your case, 
your overall superproject could specify

set(SUPERPROJECT_BUILD_COMMAND make -j4)

(say), and then each of your two projects could be configured via 
ExternalProject_Add to use ${SUPERPROJECT_BUILD_COMMAND} as the build command 
for each individual project.  But getting back to the more complex case, for 
Unix on Windows (e.g. Cygwin, MinGW-w64/MSYS2,
MinGW/MSYS) I find parallel build options are not reliable (presumably because 
of make bugs in all those platforms) so to work around that issue, epa_build 
deliberately drops any -j options that might be specified in 
EPA_PARALLEL_BUILD_COMMAND for those platforms.  But for the Linux case (and I 
assume Mac OS X, also although I haven't tried it yet), the -j option for make 
does work reliably so I allow that option to be part of the 
EPA_PARALLEL_BUILD_COMMAND for that platform.

N.B. with 60 projects being built (each one using a parallel build on
Linux) with one overall make command, I am currently careful to build each of 
those projects one at a time (i.e., avoid any parallel options on the overall 
build or just use -j1) to avoid overwhelming my computer with parallel builds.  
However, come to think of it I have always used that combination of -j options 
(-j4 for individual project builds and -j1 for overall build) out of inertia, 
and there are many other ways that avoidance can be done (e.g., -j4 on the 
overall build and -j1 on the individual builds) so long as the product of the 
two integers specified by the -j options does not get too excessive.  So I may 
do some experimentation concerning the most efficient combination of individual 
and overall -j options the next time I do an epa_build on Linux.

Alan

==
Thanks that  is what I was planning.  I was just hoping, there was a variable I 
was missing in the docs

I have it working now on linux, off to try and see how it works with windows

Scott

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Two phase install?

2016-03-23 Thread Scott Aron Bloom
> Thanks I'm getting close now.
>
> However, for the two sub projects, there doesn’t seem to be a way to run the 
> make stage with -j 6 or any make options.
>
> Am I missing something? I see how to set CMAKE_ARGS but no MAKE_ARGS

Hi Scott:

Some of my further comments are somewhat off your original topic since I 
discuss parallel build issues for the case of larger numbers of projects in the 
superproject, but I thought you might be interested in that case even though 
you just have two projects in your superproject.

For the superproject (epa_build in my case) I configure the 
EPA_PARALLEL_BUILD_COMMAND variable to create the build command that I use for 
all individual projects.  That can be anything accessible from the command-line 
such as nmake in the Windows case and make in the Unix case.  So in your case, 
your overall superproject could specify

set(SUPERPROJECT_BUILD_COMMAND make -j4)

(say), and then each of your two projects could be configured via 
ExternalProject_Add to use ${SUPERPROJECT_BUILD_COMMAND} as the build command 
for each individual project.  But getting back to the more complex case, for 
Unix on Windows (e.g. Cygwin, MinGW-w64/MSYS2,
MinGW/MSYS) I find parallel build options are not reliable (presumably because 
of make bugs in all those platforms) so to work around that issue, epa_build 
deliberately drops any -j options that might be specified in 
EPA_PARALLEL_BUILD_COMMAND for those platforms.  But for the Linux case (and I 
assume Mac OS X, also although I haven't tried it yet), the -j option for make 
does work reliably so I allow that option to be part of the 
EPA_PARALLEL_BUILD_COMMAND for that platform.

N.B. with 60 projects being built (each one using a parallel build on
Linux) with one overall make command, I am currently careful to build each of 
those projects one at a time (i.e., avoid any parallel options on the overall 
build or just use -j1) to avoid overwhelming my computer with parallel builds.  
However, come to think of it I have always used that combination of -j options 
(-j4 for individual project builds and -j1 for overall build) out of inertia, 
and there are many other ways that avoidance can be done (e.g., -j4 on the 
overall build and -j1 on the individual builds) so long as the product of the 
two integers specified by the -j options does not get too excessive.  So I may 
do some experimentation concerning the most efficient combination of individual 
and overall -j options the next time I do an epa_build on Linux.

Alan

==
Thanks that  is what I was planning.  I was just hoping, there was a variable I 
was missing in the docs

I have it working now on linux, off to try and see how it works with windows

Scott

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Two phase install?

2016-03-23 Thread Alan W. Irwin

On 2016-03-24 02:02- Scott Aron Bloom wrote:


Thanks I'm getting close now.

However, for the two sub projects, there doesn’t seem to be a way to run the 
make stage with -j 6 or any make options.

Am I missing something? I see how to set CMAKE_ARGS but no MAKE_ARGS


Hi Scott:

Some of my further comments are somewhat off your original topic since
I discuss parallel build issues for the case of larger numbers of
projects in the superproject, but I thought you might be interested in
that case even though you just have two projects in your superproject.

For the superproject (epa_build in my case) I configure the
EPA_PARALLEL_BUILD_COMMAND variable to create the build command that I
use for all individual projects.  That can be anything accessible from the
command-line such as nmake in the Windows case and make in the Unix
case.  So in your case, your overall superproject could specify

set(SUPERPROJECT_BUILD_COMMAND make -j4)

(say), and then each of your two projects could be configured via
ExternalProject_Add to use ${SUPERPROJECT_BUILD_COMMAND} as the build
command for each individual project.  But getting back to the more
complex case, for Unix on Windows (e.g. Cygwin, MinGW-w64/MSYS2,
MinGW/MSYS) I find parallel build options are not reliable (presumably
because of make bugs in all those platforms) so to work around that
issue, epa_build deliberately drops any -j options that might be
specified in EPA_PARALLEL_BUILD_COMMAND for those platforms.  But for
the Linux case (and I assume Mac OS X, also although I haven't tried
it yet), the -j option for make does work reliably so I allow that
option to be part of the EPA_PARALLEL_BUILD_COMMAND for that platform.

N.B. with 60 projects being built (each one using a parallel build on
Linux) with one overall make command, I am currently careful to build
each of those projects one at a time (i.e., avoid any parallel options
on the overall build or just use -j1) to avoid overwhelming my
computer with parallel builds.  However, come to think of it I have
always used that combination of -j options (-j4 for individual project
builds and -j1 for overall build) out of inertia, and there are many
other ways that avoidance can be done (e.g., -j4 on the overall build
and -j1 on the individual builds) so long as the product of the two
integers specified by the -j options does not get too excessive.  So I
may do some experimentation concerning the most efficient combination
of individual and overall -j options the next time I do an epa_build
on Linux.

Alan
__
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__

Linux-powered Science
__
--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Re: [CMake] Two phase install?

2016-03-23 Thread Alan W. Irwin

On 2016-03-24 01:08- Scott Aron Bloom wrote:


Do you have apointer to an example of using the external_project.

I have split the projects up, and install the first one.. But I cant seem to 
get the external project on the downstream cmake run to properly depend that 
the previous one was run


Hi Scott:

I suspect Nicholas has already given you better (simpler) examples
that are more suitable for your two-project needs, but if you are
interested in a more complex case, then you may want to look at my
epa_build project (which builds ~60 PLplot dependencies as well as
PLplot itself with all dependencies between those projects handled
correctly with one simple function call per project).  See the
cmake/epa_build subdirectory of the PLplot-5.11.1 release that you can
download from SourceForge following links at
.  There are also instructions
at the URL (click on the Code link) for accessing our git version of
PLplot which contains the epa_build project in the same
cmake/epa_build location.

Alan
__
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__

Linux-powered Science
__
--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Two phase install?

2016-03-23 Thread Scott Aron Bloom
Thanks I'm getting close now.

However, for the two sub projects, there doesn’t seem to be a way to run the 
make stage with -j 6 or any make options.

Am I missing something? I see how to set CMAKE_ARGS but no MAKE_ARGS

Scott
-Original Message-
From: Nicholas Braden [mailto:nicholas11bra...@gmail.com] 
Sent: Wednesday, March 23, 2016 6:14 PM
To: Scott Aron Bloom
Cc: cmake@cmake.org
Subject: Re: [CMake] Two phase install?

Sure, here are a couple of my own projects:
https://github.com/LB--/events/blob/e3215d84644c67848b6d716d308e66c6f186b84e/CMakeLists.txt#L26-L29
https://github.com/LB--/simple-platformer/blob/5b8541354109137798d648bc9d8fe164137de9ab/CMakeLists.txt#L63-L67

On Wed, Mar 23, 2016 at 8:11 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
> Ok.. Do you have an example somewhere ?
>
> -Original Message-
> From: Nicholas Braden [mailto:nicholas11bra...@gmail.com]
> Sent: Wednesday, March 23, 2016 6:11 PM
> To: Scott Aron Bloom
> Cc: Alan W. Irwin; cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
> Both projects should be built via ExternalProject within a superproject, this 
> way you can use the DEPENDS arguments to guarantee build order.
>
> On Wed, Mar 23, 2016 at 8:08 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
>> Do you have apointer to an example of using the external_project.
>>
>> I have split the projects up, and install the first one.. But I cant 
>> seem to get the external project on the downstream cmake run to 
>> properly depend that the previous one was run
>>
>> Scott
>>
>> -Original Message-
>> From: CMake [mailto:cmake-boun...@cmake.org] On Behalf Of Scott Aron 
>> Bloom
>> Sent: Wednesday, March 23, 2016 2:50 PM
>> To: Alan W. Irwin
>> Cc: cmake@cmake.org
>> Subject: Re: [CMake] Two phase install?
>>
>> -Original Message-
>> From: Alan W. Irwin [mailto:ir...@beluga.phys.uvic.ca]
>> Sent: Wednesday, March 23, 2016 2:48 PM
>> To: Scott Aron Bloom
>> Cc: cmake@cmake.org
>> Subject: Re: [CMake] Two phase install?
>>
>> On 2016-03-23 20:25- Scott Aron Bloom wrote:
>>
>>> Here is my problem.
>>>
>>> The project I have creates an application, that is needed to build the rest 
>>> of the project.
>>>
>>> To imagine it, imagine the application is a custom yacc/lex based parser 
>>> that reads in a file and generates an output file.
>>>
>>> In order for the application to run correctly, it needs an install step.  
>>> However, the results of the application, are part of the final install.
>>>
>>> Is there anyway to say "build this, and create its install area" and 
>>> afterwards run the rest of the requirements for install?
>>
>> Yes.  I suggest you build and install your application and the rest of your 
>> project as two separate CMake projects with a common install-tree prefix.
>>
>> Of course, you could stop there with two completely independent projects 
>> that you (and your users) learn to build and install in the correct order. 
>> However, CMake allows you to organize such multiple builds and installs with 
>> ExternalProject_Add.  I like and use that a lot for large numbers of 
>> different projects that depend on each other, and you might also find it 
>> useful for your case of just two independent projects.
>>
>> Alan
>> 
>>
>> Thanks, the ExternalProject_Add is exactly what I needed a hint towards!!!
>>
>>
>>
>> --
>>
>> Powered by www.kitware.com
>>
>> Please keep messages on-topic and check the CMake FAQ at:
>> http://www.cmake.org/Wiki/CMake_FAQ
>>
>> Kitware offers various services to support the CMake community. For more 
>> information on each offering, please visit:
>>
>> CMake Support: http://cmake.org/cmake/help/support.html
>> CMake Consulting: http://cmake.org/cmake/help/consulting.html
>> CMake Training Courses: http://cmake.org/cmake/help/training.html
>>
>> Visit other Kitware open-source projects at 
>> http://www.kitware.com/opensource/opensource.html
>>
>> Follow this link to subscribe/unsubscribe:
>> http://public.kitware.com/mailman/listinfo/cmake
>> --
>>
>> Powered by www.kitware.com
>>
>> Please keep messages on-topic and check the CMake FAQ at:
>> http://www.cmake.org/Wiki/CMake_FAQ
>>
>> Kitware offers various services to support the CMake community. For more 
>> information on each offering, please visit:
>>
>> CMake Support: http://cmake.org/cmake/help/support.html
>> CMak

Re: [CMake] Two phase install?

2016-03-23 Thread Nicholas Braden
Sure, here are a couple of my own projects:
https://github.com/LB--/events/blob/e3215d84644c67848b6d716d308e66c6f186b84e/CMakeLists.txt#L26-L29
https://github.com/LB--/simple-platformer/blob/5b8541354109137798d648bc9d8fe164137de9ab/CMakeLists.txt#L63-L67

On Wed, Mar 23, 2016 at 8:11 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
> Ok.. Do you have an example somewhere ?
>
> -Original Message-
> From: Nicholas Braden [mailto:nicholas11bra...@gmail.com]
> Sent: Wednesday, March 23, 2016 6:11 PM
> To: Scott Aron Bloom
> Cc: Alan W. Irwin; cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
> Both projects should be built via ExternalProject within a superproject, this 
> way you can use the DEPENDS arguments to guarantee build order.
>
> On Wed, Mar 23, 2016 at 8:08 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
>> Do you have apointer to an example of using the external_project.
>>
>> I have split the projects up, and install the first one.. But I cant
>> seem to get the external project on the downstream cmake run to
>> properly depend that the previous one was run
>>
>> Scott
>>
>> -Original Message-
>> From: CMake [mailto:cmake-boun...@cmake.org] On Behalf Of Scott Aron
>> Bloom
>> Sent: Wednesday, March 23, 2016 2:50 PM
>> To: Alan W. Irwin
>> Cc: cmake@cmake.org
>> Subject: Re: [CMake] Two phase install?
>>
>> -Original Message-
>> From: Alan W. Irwin [mailto:ir...@beluga.phys.uvic.ca]
>> Sent: Wednesday, March 23, 2016 2:48 PM
>> To: Scott Aron Bloom
>> Cc: cmake@cmake.org
>> Subject: Re: [CMake] Two phase install?
>>
>> On 2016-03-23 20:25- Scott Aron Bloom wrote:
>>
>>> Here is my problem.
>>>
>>> The project I have creates an application, that is needed to build the rest 
>>> of the project.
>>>
>>> To imagine it, imagine the application is a custom yacc/lex based parser 
>>> that reads in a file and generates an output file.
>>>
>>> In order for the application to run correctly, it needs an install step.  
>>> However, the results of the application, are part of the final install.
>>>
>>> Is there anyway to say "build this, and create its install area" and 
>>> afterwards run the rest of the requirements for install?
>>
>> Yes.  I suggest you build and install your application and the rest of your 
>> project as two separate CMake projects with a common install-tree prefix.
>>
>> Of course, you could stop there with two completely independent projects 
>> that you (and your users) learn to build and install in the correct order. 
>> However, CMake allows you to organize such multiple builds and installs with 
>> ExternalProject_Add.  I like and use that a lot for large numbers of 
>> different projects that depend on each other, and you might also find it 
>> useful for your case of just two independent projects.
>>
>> Alan
>> 
>>
>> Thanks, the ExternalProject_Add is exactly what I needed a hint towards!!!
>>
>>
>>
>> --
>>
>> Powered by www.kitware.com
>>
>> Please keep messages on-topic and check the CMake FAQ at:
>> http://www.cmake.org/Wiki/CMake_FAQ
>>
>> Kitware offers various services to support the CMake community. For more 
>> information on each offering, please visit:
>>
>> CMake Support: http://cmake.org/cmake/help/support.html
>> CMake Consulting: http://cmake.org/cmake/help/consulting.html
>> CMake Training Courses: http://cmake.org/cmake/help/training.html
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Follow this link to subscribe/unsubscribe:
>> http://public.kitware.com/mailman/listinfo/cmake
>> --
>>
>> Powered by www.kitware.com
>>
>> Please keep messages on-topic and check the CMake FAQ at:
>> http://www.cmake.org/Wiki/CMake_FAQ
>>
>> Kitware offers various services to support the CMake community. For more 
>> information on each offering, please visit:
>>
>> CMake Support: http://cmake.org/cmake/help/support.html
>> CMake Consulting: http://cmake.org/cmake/help/consulting.html
>> CMake Training Courses: http://cmake.org/cmake/help/training.html
>>
>> Visit other Kitware open-source projects at
>> http://www.kitware.com/opensource/opensource.html
>>
>> Follow this link to subscribe/unsubscribe:
>> http://public.kitware.com/mailman/listinfo/cmake
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Two phase install?

2016-03-23 Thread Scott Aron Bloom
Ok.. Do you have an example somewhere ?

-Original Message-
From: Nicholas Braden [mailto:nicholas11bra...@gmail.com] 
Sent: Wednesday, March 23, 2016 6:11 PM
To: Scott Aron Bloom
Cc: Alan W. Irwin; cmake@cmake.org
Subject: Re: [CMake] Two phase install?

Both projects should be built via ExternalProject within a superproject, this 
way you can use the DEPENDS arguments to guarantee build order.

On Wed, Mar 23, 2016 at 8:08 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
> Do you have apointer to an example of using the external_project.
>
> I have split the projects up, and install the first one.. But I cant 
> seem to get the external project on the downstream cmake run to 
> properly depend that the previous one was run
>
> Scott
>
> -Original Message-
> From: CMake [mailto:cmake-boun...@cmake.org] On Behalf Of Scott Aron 
> Bloom
> Sent: Wednesday, March 23, 2016 2:50 PM
> To: Alan W. Irwin
> Cc: cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
> -Original Message-
> From: Alan W. Irwin [mailto:ir...@beluga.phys.uvic.ca]
> Sent: Wednesday, March 23, 2016 2:48 PM
> To: Scott Aron Bloom
> Cc: cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
> On 2016-03-23 20:25- Scott Aron Bloom wrote:
>
>> Here is my problem.
>>
>> The project I have creates an application, that is needed to build the rest 
>> of the project.
>>
>> To imagine it, imagine the application is a custom yacc/lex based parser 
>> that reads in a file and generates an output file.
>>
>> In order for the application to run correctly, it needs an install step.  
>> However, the results of the application, are part of the final install.
>>
>> Is there anyway to say "build this, and create its install area" and 
>> afterwards run the rest of the requirements for install?
>
> Yes.  I suggest you build and install your application and the rest of your 
> project as two separate CMake projects with a common install-tree prefix.
>
> Of course, you could stop there with two completely independent projects that 
> you (and your users) learn to build and install in the correct order. 
> However, CMake allows you to organize such multiple builds and installs with 
> ExternalProject_Add.  I like and use that a lot for large numbers of 
> different projects that depend on each other, and you might also find it 
> useful for your case of just two independent projects.
>
> Alan
> 
>
> Thanks, the ExternalProject_Add is exactly what I needed a hint towards!!!
>
>
>
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at: 
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more 
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at 
> http://www.kitware.com/opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at: 
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more 
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at 
> http://www.kitware.com/opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Two phase install?

2016-03-23 Thread Nicholas Braden
Both projects should be built via ExternalProject within a
superproject, this way you can use the DEPENDS arguments to guarantee
build order.

On Wed, Mar 23, 2016 at 8:08 PM, Scott Aron Bloom <sc...@towel42.com> wrote:
> Do you have apointer to an example of using the external_project.
>
> I have split the projects up, and install the first one.. But I cant seem to 
> get the external project on the downstream cmake run to properly depend that 
> the previous one was run
>
> Scott
>
> -Original Message-
> From: CMake [mailto:cmake-boun...@cmake.org] On Behalf Of Scott Aron Bloom
> Sent: Wednesday, March 23, 2016 2:50 PM
> To: Alan W. Irwin
> Cc: cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
> -Original Message-
> From: Alan W. Irwin [mailto:ir...@beluga.phys.uvic.ca]
> Sent: Wednesday, March 23, 2016 2:48 PM
> To: Scott Aron Bloom
> Cc: cmake@cmake.org
> Subject: Re: [CMake] Two phase install?
>
> On 2016-03-23 20:25- Scott Aron Bloom wrote:
>
>> Here is my problem.
>>
>> The project I have creates an application, that is needed to build the rest 
>> of the project.
>>
>> To imagine it, imagine the application is a custom yacc/lex based parser 
>> that reads in a file and generates an output file.
>>
>> In order for the application to run correctly, it needs an install step.  
>> However, the results of the application, are part of the final install.
>>
>> Is there anyway to say "build this, and create its install area" and 
>> afterwards run the rest of the requirements for install?
>
> Yes.  I suggest you build and install your application and the rest of your 
> project as two separate CMake projects with a common install-tree prefix.
>
> Of course, you could stop there with two completely independent projects that 
> you (and your users) learn to build and install in the correct order. 
> However, CMake allows you to organize such multiple builds and installs with 
> ExternalProject_Add.  I like and use that a lot for large numbers of 
> different projects that depend on each other, and you might also find it 
> useful for your case of just two independent projects.
>
> Alan
> 
>
> Thanks, the ExternalProject_Add is exactly what I needed a hint towards!!!
>
>
>
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at: 
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more 
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at 
> http://www.kitware.com/opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
> --
>
> Powered by www.kitware.com
>
> Please keep messages on-topic and check the CMake FAQ at: 
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Kitware offers various services to support the CMake community. For more 
> information on each offering, please visit:
>
> CMake Support: http://cmake.org/cmake/help/support.html
> CMake Consulting: http://cmake.org/cmake/help/consulting.html
> CMake Training Courses: http://cmake.org/cmake/help/training.html
>
> Visit other Kitware open-source projects at 
> http://www.kitware.com/opensource/opensource.html
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/cmake
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Two phase install?

2016-03-23 Thread Scott Aron Bloom
Do you have apointer to an example of using the external_project.

I have split the projects up, and install the first one.. But I cant seem to 
get the external project on the downstream cmake run to properly depend that 
the previous one was run

Scott

-Original Message-
From: CMake [mailto:cmake-boun...@cmake.org] On Behalf Of Scott Aron Bloom
Sent: Wednesday, March 23, 2016 2:50 PM
To: Alan W. Irwin
Cc: cmake@cmake.org
Subject: Re: [CMake] Two phase install?

-Original Message-
From: Alan W. Irwin [mailto:ir...@beluga.phys.uvic.ca] 
Sent: Wednesday, March 23, 2016 2:48 PM
To: Scott Aron Bloom
Cc: cmake@cmake.org
Subject: Re: [CMake] Two phase install?

On 2016-03-23 20:25- Scott Aron Bloom wrote:

> Here is my problem.
>
> The project I have creates an application, that is needed to build the rest 
> of the project.
>
> To imagine it, imagine the application is a custom yacc/lex based parser that 
> reads in a file and generates an output file.
>
> In order for the application to run correctly, it needs an install step.  
> However, the results of the application, are part of the final install.
>
> Is there anyway to say "build this, and create its install area" and 
> afterwards run the rest of the requirements for install?

Yes.  I suggest you build and install your application and the rest of your 
project as two separate CMake projects with a common install-tree prefix.

Of course, you could stop there with two completely independent projects that 
you (and your users) learn to build and install in the correct order. However, 
CMake allows you to organize such multiple builds and installs with 
ExternalProject_Add.  I like and use that a lot for large numbers of different 
projects that depend on each other, and you might also find it useful for your 
case of just two independent projects.

Alan


Thanks, the ExternalProject_Add is exactly what I needed a hint towards!!!



-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Two phase install?

2016-03-23 Thread Scott Aron Bloom
-Original Message-
From: Alan W. Irwin [mailto:ir...@beluga.phys.uvic.ca] 
Sent: Wednesday, March 23, 2016 2:48 PM
To: Scott Aron Bloom
Cc: cmake@cmake.org
Subject: Re: [CMake] Two phase install?

On 2016-03-23 20:25- Scott Aron Bloom wrote:

> Here is my problem.
>
> The project I have creates an application, that is needed to build the rest 
> of the project.
>
> To imagine it, imagine the application is a custom yacc/lex based parser that 
> reads in a file and generates an output file.
>
> In order for the application to run correctly, it needs an install step.  
> However, the results of the application, are part of the final install.
>
> Is there anyway to say "build this, and create its install area" and 
> afterwards run the rest of the requirements for install?

Yes.  I suggest you build and install your application and the rest of your 
project as two separate CMake projects with a common install-tree prefix.

Of course, you could stop there with two completely independent projects that 
you (and your users) learn to build and install in the correct order. However, 
CMake allows you to organize such multiple builds and installs with 
ExternalProject_Add.  I like and use that a lot for large numbers of different 
projects that depend on each other, and you might also find it useful for your 
case of just two independent projects.

Alan


Thanks, the ExternalProject_Add is exactly what I needed a hint towards!!!



-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


Re: [CMake] Two phase install?

2016-03-23 Thread Alan W. Irwin

On 2016-03-23 20:25- Scott Aron Bloom wrote:


Here is my problem.

The project I have creates an application, that is needed to build the rest of 
the project.

To imagine it, imagine the application is a custom yacc/lex based parser that 
reads in a file and generates an output file.

In order for the application to run correctly, it needs an install step.  
However, the results of the application, are part of the final install.

Is there anyway to say "build this, and create its install area" and afterwards 
run the rest of the requirements for install?


Yes.  I suggest you build and install your application and the rest of your
project as two separate CMake projects with a common install-tree prefix.

Of course, you could stop there with two completely independent
projects that you (and your users) learn to build and install in the
correct order. However, CMake allows you to organize such multiple
builds and installs with ExternalProject_Add.  I like and use that a
lot for large numbers of different projects that depend on each other,
and you might also find it useful for your case of just two
independent projects.

Alan
__
Alan W. Irwin

Astronomical research affiliation with Department of Physics and Astronomy,
University of Victoria (astrowww.phys.uvic.ca).

Programming affiliations with the FreeEOS equation-of-state
implementation for stellar interiors (freeeos.sf.net); the Time
Ephemerides project (timeephem.sf.net); PLplot scientific plotting
software package (plplot.sf.net); the libLASi project
(unifont.org/lasi); the Loads of Linux Links project (loll.sf.net);
and the Linux Brochure Project (lbproject.sf.net).
__

Linux-powered Science
__
--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake


[CMake] Two phase install?

2016-03-23 Thread Scott Aron Bloom
Here is my problem.

The project I have creates an application, that is needed to build the rest of 
the project.

To imagine it, imagine the application is a custom yacc/lex based parser that 
reads in a file and generates an output file.

In order for the application to run correctly, it needs an install step.  
However, the results of the application, are part of the final install.

Is there anyway to say "build this, and create its install area" and afterwards 
run the rest of the requirements for install?

Scott
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake