<div dir="ltr"><div><div><div>Hi Jameson, <br><br></div>Good to know you are using Artichoke. <br><br>As you described Artichoke provides "ExternalProjectDependency", a CMake module extending the capabilities of ExternalProject. <br><br>It could eventually by integrated into CMake once the API is stable, the documentation is complete it is more widely adopted. <br><br></div>All of that said, here are few questions:<br><br> - By using the add_custom_target/add_custom_command with POST_BUILD, is your intent to systematically start the test once the build is done ? <br><br></div><div> - Or are you trying to add a "test" target at the top-level that would run the test of all projects ?<br><br><br></div><div>Finally, the addition ExternalProject_Install_CMake was an attempt to facilitate installation of the whole project by having "make install" working in the top-level build directory. We would have to first address an issue in CMake itself <a href="http://www.cmake.org/Bug/view.php?id=14955">http://www.cmake.org/Bug/view.php?id=14955</a>. <br><br>For now, to avoid confusion, I will remove the function.<br><br></div><div>Hth<br></div><div>Jc<br></div><div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 3, 2014 at 5:46 PM, jmerkow <span dir="ltr"><<a href="mailto:jmerkow@gmail.com" target="_blank">jmerkow@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<br>
My project is using ExternalProjectDependency from [1]. I know that is not a<br>
kitware/cmake project, but I thought Id ask here anyway....<br>
I have been using testing (ctest) with it by adding tests in the top level<br>
build with hard-coded directories and names (these targets aren't built<br>
until the non-superbuild project is built).  I wanted to move the tests to<br>
the non-superbuild portion of the code so I can use generator expressions,<br>
but I am having some trouble.<br>
<br>
Basically, what I am doing is to include ctest in the non-superbuild portion<br>
then add a custom target.  This works for 'make test' but does not work with<br>
ctest.<br>
<br>
add_custom_target(test)<br>
add_custom_command(TARGET test POST_BUILD<br>
COMMAND ${CMAKE_COMMAND} --build ${${PROJECT_NAME}_BINARY_DIR}/build<br>
--target test)<br>
<br>
ExternalProjectDependency added a function to add install:<br>
'ExternalProject_Install_CMake' I don't see a similar function for testing.<br>
Is there another good way to do this?  Im not sure what ctest calls to<br>
initiate testing, using that info, I might be able to get a good work<br>
around.<br>
<br>
-Jameson<br>
<br>
[1] <a href="https://github.com/commontk/Artichoke" target="_blank">https://github.com/commontk/Artichoke</a><br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://cmake.3232098.n2.nabble.com/ExternalProjectDependency-artichoke-and-ctest-tp7588929.html" target="_blank">http://cmake.3232098.n2.nabble.com/ExternalProjectDependency-artichoke-and-ctest-tp7588929.html</a><br>
Sent from the CMake mailing list archive at Nabble.com.<br>
--<br>
<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br>
<br>
Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br>
<br>
CMake Support: <a href="http://cmake.org/cmake/help/support.html" target="_blank">http://cmake.org/cmake/help/support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" target="_blank">http://cmake.org/cmake/help/consulting.html</a><br>
CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" target="_blank">http://cmake.org/cmake/help/training.html</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/cmake" target="_blank">http://public.kitware.com/mailman/listinfo/cmake</a><br>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature">+1 919 869 8849<br></div>
</div>