Hello,
I have a CMake project that uses CPack to generate a tgz file. When I
build it and run CPack, it produces project-X.Y.Z in the build directory
(where X, Y, and Z are ${CPACK_PACKAGE_VERSION_MAJOR}/minor/patch).
I recently decided to add a new "super project" that builds both my project
and a few other external projects. In a new top-level CMakeLists.txt file
I have:
project(super)
cmake_minimum_required(VERSION 3.1)
# build my project
ExternalProject_Add(my_project
SOURCE_DIR ${CMAKE_CURRENT_LIST_DIR}/my_project
BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR}/my_project
BUILD_COMMAND ${CMAKE_COMMAND} --build .
INSTALL_COMMAND ${CMAKE_CPACK_COMMAND})
# Build another custom target
add_custom_target(custom ALL
WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/custom
COMMAND make
)
The super project, works well. It does build both my original project (via
external project) and another item by invoking make with add_custom_target.
I would like to generate a tgz file that contains both the output of my
custom target and the output of running CPack on my external project, but
can't figure out how to do so. I've tried to use CPack again (one level
higher) or just forego CPack and manually create a tar file, but both
approaches led to new challenges. Is there some way to generate a new
package containing the output of an external project?
Thanks for any help,
Zac
--
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