build(cross): working on cross compilation

We want to be able to build all targets on one machine, began
implimenting cross compilation
This commit is contained in:
Emily Boudreaux
2025-12-01 09:59:22 -05:00
parent dac09ae24c
commit b06b622c06
3 changed files with 32 additions and 10 deletions

View File

@@ -4,8 +4,11 @@ cvode_cmake_options = cmake.subproject_options()
cvode_cmake_options.add_cmake_defines({
'CMAKE_CXX_FLAGS' : '-Wno-deprecated-declarations',
'CMAKE_C_FLAGS' : '-Wno-deprecated-declarations',
'BUILD_SHARED_LIBS' : 'ON',
'BUILD_STATIC_LIBS' : 'OFF',
'BUILD_SHARED_LIBS' : 'OFF',
'BUILD_STATIC_LIBS' : 'ON',
'CMAKE_BUILD_WITH_INSTALL_RPATH': 'ON',
'EXAMPLES_ENABLE_C': 'OFF',
'CMAKE_POSITION_INDEPENDENT_CODE': 'ON'
})
@@ -20,19 +23,19 @@ cvode_sp = cmake.subproject(
)
# For the core SUNDIALS library (SUNContext, etc.)
sundials_core_dep = cvode_sp.dependency('sundials_core_shared')
sundials_core_dep = cvode_sp.dependency('sundials_core_static')
# For the CVODE integrator library
sundials_cvode_dep = cvode_sp.dependency('sundials_cvode_shared')
sundials_cvode_dep = cvode_sp.dependency('sundials_cvode_static')
# For the serial NVector library
sundials_nvecserial_dep = cvode_sp.dependency('sundials_nvecserial_shared')
sundials_nvecserial_dep = cvode_sp.dependency('sundials_nvecserial_static')
# For the dense matrix library
sundials_sunmatrixdense_dep = cvode_sp.dependency('sundials_sunmatrixdense_shared')
sundials_sunmatrixdense_dep = cvode_sp.dependency('sundials_sunmatrixdense_static')
# For the dense linear solver library
sundials_sunlinsoldense_dep = cvode_sp.dependency('sundials_sunlinsoldense_shared')
sundials_sunlinsoldense_dep = cvode_sp.dependency('sundials_sunlinsoldense_static')
cvode_dep = declare_dependency(
dependencies: [