dwarfs/cmake/dwarfs_install.cmake.in
2023-07-09 10:57:37 +02:00

25 lines
1.2 KiB
CMake

#
# Copyright (c) Marcus Holland-Moritz
#
# This file is part of dwarfs.
#
# dwarfs is free software: you can redistribute it and/or modify it under the
# terms of the GNU General Public License as published by the Free Software
# Foundation, either version 3 of the License, or (at your option) any later
# version.
#
# dwarfs is distributed in the hope that it will be useful, but WITHOUT ANY
# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
# A PARTICULAR PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along with
# dwarfs. If not, see <https://www.gnu.org/licenses/>.
#
if(CPACK_SOURCE_INSTALLED_DIRECTORIES)
message(STATUS "Adding versioning files from @PROJECT_BINARY_DIR@ to ${CMAKE_CURRENT_BINARY_DIR}...")
file(INSTALL "@PROJECT_BINARY_DIR@/include/dwarfs/version.h" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/include/dwarfs")
file(INSTALL "@PROJECT_BINARY_DIR@/src/dwarfs/version.cpp" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/src/dwarfs")
file(INSTALL "@PROJECT_BINARY_DIR@/package_version.cmake" DESTINATION "${CMAKE_CURRENT_BINARY_DIR}/cmake")
endif()