blob: bf99f7c12177a9d753009fc712743a0405ae32ac (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
cmake_minimum_required(VERSION 3.24...3.28)
project(cxx_modules_internal_partitions CXX)
include("${CMAKE_SOURCE_DIR}/../cxx-modules-rules.cmake")
include(GenerateExportHeader)
add_library(internal-partitions)
generate_export_header(internal-partitions)
target_sources(internal-partitions
PUBLIC
FILE_SET HEADERS
BASE_DIRS
"${CMAKE_CURRENT_BINARY_DIR}"
FILES
"${CMAKE_CURRENT_BINARY_DIR}/internal-partitions_export.h"
FILE_SET CXX_MODULES
BASE_DIRS
"${CMAKE_CURRENT_SOURCE_DIR}"
FILES
importable.cxx
partition.cxx)
target_compile_features(internal-partitions PUBLIC cxx_std_20)
add_executable(exe)
target_link_libraries(exe PRIVATE internal-partitions)
target_sources(exe
PRIVATE
main.cxx)
add_test(NAME exe COMMAND exe)
|