Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/src/Progmasoft/meson.build
blob: 0c838140172981787c8d6b373289276db3e163e8 (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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# Copyright (c) 2026 Progmasoft.
# SPDX-License-Identifier: MPL-2.0 WITH AdditionRef-Progmasoft-Exception-1.1

# Compile the non-template C++20 utilities separately while retaining Catch2's
# own C++14 baseline for existing users.
progmasoft_catch3 = static_library(
  'ProgmasoftCatch3',
  [
    'ChoiceShrinker.cpp',
    'Context.cpp',
    'PropertyEngine.cpp',
    'Results.cpp',
    'Snapshot.cpp',
    'XmlWriter.cpp',
  ],
  include_directories: '..',
  dependencies: catch2_dep,
  override_options: ['cpp_std=c++20'],
  install: get_option('install'),
)
progmasoft_catch3_dep = declare_dependency(
  link_with: progmasoft_catch3,
  dependencies: catch2_dep,
  include_directories: include_directories('..'),
)

if get_option('install')
  install_headers('Catch3.hpp', subdir: 'Progmasoft')
  install_headers('Catch3/Assertions.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Detail/InvalidArgument.hpp', subdir: 'Progmasoft/Catch3/Detail')
  install_headers('Catch3/Detail/Sequence.hpp', subdir: 'Progmasoft/Catch3/Detail')
  install_headers('Catch3/Generator.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Property.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Random.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Results.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Snapshot.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/XmlWriter.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/ForAll.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Relations.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Stateful.hpp', subdir: 'Progmasoft/Catch3')
  install_headers('Catch3/Strategy/ChoiceSource.hpp', subdir: 'Progmasoft/Catch3/Strategy')
  install_headers('Catch3/Strategy/Containers.hpp', subdir: 'Progmasoft/Catch3/Strategy')
  install_headers('Catch3/Strategy/Context.hpp', subdir: 'Progmasoft/Catch3/Strategy')
  install_headers('Catch3/Strategy/Engine.hpp', subdir: 'Progmasoft/Catch3/Strategy')
  install_headers('Catch3/Strategy/Numeric.hpp', subdir: 'Progmasoft/Catch3/Strategy')
  install_headers('Catch3/Strategy/Strategy.hpp', subdir: 'Progmasoft/Catch3/Strategy')
  install_headers('Catch3/Generators/Boolean.hpp', subdir: 'Progmasoft/Catch3/Generators')
  install_headers('Catch3/Generators/Integer.hpp', subdir: 'Progmasoft/Catch3/Generators')
  install_headers('Catch3/Generators/Element.hpp', subdir: 'Progmasoft/Catch3/Generators')
  install_headers('Catch3/Generators/Text.hpp', subdir: 'Progmasoft/Catch3/Generators')
  install_headers('Catch3/Generators/Tuple.hpp', subdir: 'Progmasoft/Catch3/Generators')
  install_headers('Catch3/Generators/Vector.hpp', subdir: 'Progmasoft/Catch3/Generators')
endif