Move header into subdir

This commit is contained in:
Haowen Liu 2025-04-28 21:02:00 -04:00
parent d02cdeedc2
commit cbb57fff5f
No known key found for this signature in database
GPG Key ID: F65B4067F3357C78
2 changed files with 7 additions and 2 deletions

View File

@ -1,5 +1,5 @@
cmake_minimum_required(VERSION 3.5) cmake_minimum_required(VERSION 3.5)
project(subprocess VERSION 0.0.1 LANGUAGES CXX) project(subprocess VERSION 0.1.0 LANGUAGES CXX)
set(CMAKE_CXX_STANDARD 11 CACHE STRING "C++ standard to use") set(CMAKE_CXX_STANDARD 11 CACHE STRING "C++ standard to use")
option(EXPORT_COMPILE_COMMANDS "create clang compile database" ON) option(EXPORT_COMPILE_COMMANDS "create clang compile database" ON)
@ -10,7 +10,12 @@ find_package(Threads REQUIRED)
add_library(subprocess INTERFACE) add_library(subprocess INTERFACE)
target_link_libraries(subprocess INTERFACE Threads::Threads) target_link_libraries(subprocess INTERFACE Threads::Threads)
target_include_directories(subprocess INTERFACE . ) target_sources(subprocess PUBLIC
FILE_SET HEADERS
FILES
subprocess/subprocess.hpp
BASE_DIRS ${CMAKE_CURRENT_SOURCE_DIR}/
)
if(SUBPROCESS_INSTALL) if(SUBPROCESS_INSTALL)
install(FILES subprocess.hpp DESTINATION include/cpp-subprocess/) install(FILES subprocess.hpp DESTINATION include/cpp-subprocess/)

0
subprocess.hpp → cpp-subprocess/subprocess.hpp Executable file → Normal file
View File