Repository navigation
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
178 lines (157 loc) · 7.76 KB
/
Copy pathCMakeLists.txt
File metadata and controls
178 lines (157 loc) · 7.76 KB
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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
########################################################################
# Preamble
########################################################################
cmake_minimum_required( VERSION 3.14 )
project( ACEtk LANGUAGES CXX )
########################################################################
# Project-wide setup
########################################################################
set( CMAKE_CXX_STANDARD 17 )
set( CMAKE_CXX_STANDARD_REQUIRED YES )
option(ACEtk.tests "Build the ACEtk unit tests" OFF)
option( ACEtk.python "Build ACEtk python bindings" ON )
option( strict_compile
"Treat all warnings as errors." ON
)
# Compile flags
set( common_flags "-Wall" "-Wextra" "-Wpedantic" ) # i'm not sure why we manage flags this way...
set( strict_flags "-Werror" ) # improving this will need to happen in the future for spack
set( release_flags "-O3" )
set( debug_flags "-O0" "-g" )
########################################################################
# Dependencies
########################################################################
set( REPOSITORIES "release"
CACHE STRING
"Options for where to fetch repositories: develop, release, local"
)
message( STATUS "Using ${REPOSITORIES} repositories" )
if( REPOSITORIES STREQUAL "develop" )
include( cmake/develop_dependencies.cmake )
elseif( REPOSITORIES STREQUAL "release" )
include( cmake/release_dependencies.cmake )
elseif( REPOSITORIES STREQUAL "local" )
include( cmake/local_dependencies.cmake )
endif()
########################################################################
# Project targets
########################################################################
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# ACEtk : library
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
include_directories( src/ )
add_library( ACEtk INTERFACE )
target_include_directories( ACEtk INTERFACE src/ )
target_link_libraries( ACEtk
INTERFACE Log
INTERFACE catch-adapter
INTERFACE dimwits
INTERFACE disco
INTERFACE interpolation
INTERFACE hana-adapter
INTERFACE header-utilities
INTERFACE range-v3
)
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# ACEtk : python bindings
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
if(ACEtk.python)
pybind11_add_module( ACEtk.python
python/src/ACEtk.python.cpp
python/src/XsdirEntry.python.cpp
python/src/Xsdir.python.cpp
python/src/Header.python.cpp
python/src/Data.python.cpp
python/src/Table.python.cpp
python/src/ReferenceFrame.python.cpp
python/src/AngularDistributionType.python.cpp
python/src/EnergyDistributionType.python.cpp
python/src/block/InterpolationData.python.cpp
python/src/block/CrossSectionData.python.cpp
python/src/block/DosimetryCrossSectionData.python.cpp
python/src/block/PrincipalCrossSectionBlock.python.cpp
python/src/block/PolynomialFissionMultiplicity.python.cpp
python/src/block/TabulatedFissionMultiplicity.python.cpp
python/src/block/FissionMultiplicityBlock.python.cpp
python/src/block/ReactionNumberBlock.python.cpp
python/src/block/ReactionQValueBlock.python.cpp
python/src/block/FrameAndMultiplicityBlock.python.cpp
python/src/block/CrossSectionBlock.python.cpp
python/src/block/DosimetryCrossSectionBlock.python.cpp
python/src/block/EquiprobableAngularBins.python.cpp
python/src/block/TabulatedAngularDistribution.python.cpp
python/src/block/TabulatedAngularDistributionWithProbability.python.cpp
python/src/block/IsotropicAngularDistribution.python.cpp
python/src/block/AngularDistributionData.python.cpp
python/src/block/FullyIsotropicDistribution.python.cpp
python/src/block/DistributionGivenElsewhere.python.cpp
python/src/block/AngularDistributionBlock.python.cpp
python/src/block/SecondaryParticleAngularDistributionBlock.python.cpp
python/src/block/EquiprobableOutgoingEnergyBins.python.cpp
python/src/block/EquiprobableOutgoingEnergyBinData.python.cpp
python/src/block/LevelScatteringDistribution.python.cpp
python/src/block/DiscretePhotonDistribution.python.cpp
python/src/block/TabulatedEnergyDistribution.python.cpp
python/src/block/OutgoingEnergyDistributionData.python.cpp
python/src/block/GeneralEvaporationSpectrum.python.cpp
python/src/block/SimpleMaxwellianFissionSpectrum.python.cpp
python/src/block/EvaporationSpectrum.python.cpp
python/src/block/ParameterData.python.cpp
python/src/block/EnergyDependentWattSpectrum.python.cpp
python/src/block/TabulatedKalbachMannDistribution.python.cpp
python/src/block/KalbachMannDistributionData.python.cpp
python/src/block/NBodyPhaseSpaceDistribution.python.cpp
python/src/block/TwoBodyTransferDistribution.python.cpp
python/src/block/TabulatedEnergyAngleDistribution.python.cpp
python/src/block/EnergyAngleDistributionData.python.cpp
python/src/block/TabulatedAngleEnergyDistribution.python.cpp
python/src/block/AngleEnergyDistributionData.python.cpp
python/src/block/DistributionProbability.python.cpp
python/src/block/MultiDistributionData.python.cpp
python/src/block/EnergyDistributionBlock.python.cpp
python/src/block/SecondaryParticleEnergyDistributionBlock.python.cpp
python/src/block/DelayedNeutronPrecursorData.python.cpp
python/src/block/PhotonProductionBlock.python.cpp
python/src/block/PhotonProductionCrossSectionBlock.python.cpp
python/src/block/MultiplicityReactionNumberBlock.python.cpp
python/src/block/TabulatedMultiplicity.python.cpp
python/src/block/TabulatedSecondaryParticleMultiplicity.python.cpp
python/src/block/PhotonProductionCrossSectionData.python.cpp
python/src/block/DelayedNeutronPrecursorBlock.python.cpp
python/src/block/SecondaryParticleTypeBlock.python.cpp
python/src/block/SecondaryParticleInformationBlock.python.cpp
python/src/block/SecondaryParticleLocatorBlock.python.cpp
python/src/block/SecondaryParticleProductionBlock.python.cpp
python/src/block/SecondaryParticleProductionCrossSectionBlock.python.cpp
python/src/block/ProbabilityTable.python.cpp
python/src/block/ProbabilityTableBlock.python.cpp
python/src/block/ThermalScatteringCrossSectionBlock.python.cpp
python/src/block/ThermalScatteringDiscreteCosines.python.cpp
python/src/block/ThermalScatteringDiscreteCosinesWithProbability.python.cpp
python/src/block/ThermalScatteringElasticAngularDistributionBlock.python.cpp
python/src/block/ThermalScatteringInelasticAngularDistributionBlock.python.cpp
python/src/block/PhotoAtomicPrincipalCrossSectionBlock.python.cpp
python/src/block/IncoherentScatteringFunctionBlock.python.cpp
python/src/block/CoherentFormFactorBlock.python.cpp
python/src/block/PhotoAtomicFluorescenceDataBlock.python.cpp
python/src/block/PhotoAtomicHeatingNumbersBlock.python.cpp
python/src/block/PhotoAtomicElectronShellBlock.python.cpp
python/src/block/PhotoAtomicComptonProfile.python.cpp
python/src/block/PhotoAtomicComptonProfileBlock.python.cpp
python/src/ContinuousEnergyTable.python.cpp
python/src/DosimetryTable.python.cpp
python/src/ThermalScatteringTable.python.cpp
python/src/PhotoAtomicTable.python.cpp
)
target_link_libraries( ACEtk.python PRIVATE ACEtk )
target_include_directories( ACEtk.python PRIVATE python/src )
target_compile_options( ACEtk.python PRIVATE "-fvisibility=hidden" )
set_target_properties( ACEtk.python PROPERTIES OUTPUT_NAME ACEtk )
set_target_properties( ACEtk.python PROPERTIES COMPILE_DEFINITIONS "PYBIND11" )
set_target_properties( ACEtk.python PROPERTIES POSITION_INDEPENDENT_CODE ON)
endif()
if( CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR )
if( ACEtk.tests )
include( cmake/unit_testing.cmake )
endif()
endif()