Skip to content

Commit

Permalink
Updating dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
whaeck committed Apr 23, 2024
1 parent eab32e8 commit 5c6c090
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 20 deletions.
11 changes: 9 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,11 @@ cmake_dependent_option(
cmake_dependent_option(
codex.python
"Build codex python bindings" ON
"NOT ${subproject}" OFF
"NOT ${subproject} OR DEFINED require.codex.python " OFF
)
if ( codex.python )
set( require.ENDFtk.python CACHE BOOL ON )
endif()

########################################################################
# Dependencies
Expand Down Expand Up @@ -99,6 +102,7 @@ if( codex.python )
)

target_link_libraries( codex.python PRIVATE codex )
add_dependencies( codex.python ENDFtk.python )
target_include_directories( codex.python PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/python/src )
target_compile_options( codex.python PRIVATE "-fvisibility=hidden" )
set_target_properties( codex.python PROPERTIES OUTPUT_NAME codex )
Expand All @@ -108,8 +112,11 @@ if( codex.python )
message( STATUS "Building codex's python API" )

list( APPEND CODEX_PYTHONPATH ${CMAKE_CURRENT_BINARY_DIR} )
list( APPEND ENDFTK_PYTHONPATH ${CMAKE_CURRENT_BINARY_DIR}/_deps/endftk-build )

include( cmake/unit_testing_python.cmake )
if( codex.tests )
include( cmake/unit_testing_python.cmake )
endif()

endif()

Expand Down
5 changes: 2 additions & 3 deletions cmake/develop_dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,15 @@ include( FetchContent )

FetchContent_Declare( tools
GIT_REPOSITORY https://github.com/njoy/tools
GIT_TAG v0.2.0
GIT_TAG feature/python-views
GIT_SHALLOW TRUE
)

FetchContent_Declare( ENDFtk
GIT_REPOSITORY https://github.com/njoy/ENDFtk.git
GIT_TAG feature/python-extension
GIT_TAG update/tools-dependency
GIT_SHALLOW TRUE
)
set( ENDFtk.python CACHE INTERNAL BOOL ON )

FetchContent_Declare( Catch2
GIT_REPOSITORY https://github.com/catchorg/Catch2
Expand Down
22 changes: 8 additions & 14 deletions cmake/release_dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,31 +5,25 @@ include( FetchContent )
# Declare project dependencies
#######################################################################

FetchContent_Declare( catch-adapter
GIT_REPOSITORY https://github.com/njoy/catch-adapter
GIT_TAG fb84b82ebf7a4789aa43cea560680cf745c6ee4f
)

FetchContent_Declare( Catch2
GIT_REPOSITORY https://github.com/catchorg/Catch2
GIT_TAG 3f0283de7a9c43200033da996ff9093be3ac84dc # tag: v3.3.2
)

FetchContent_Declare( disco
GIT_REPOSITORY https://github.com/njoy/disco
GIT_TAG 2606933a854bb0269c4ec37143e1236797e27838
)

FetchContent_Declare( eigen
GIT_REPOSITORY https://gitlab.com/libeigen/eigen.git
GIT_TAG d0bfdc1658ca0b4c659fd3702c351d2c2cdc876c # 3.4.1 branch on July 26, 2023
)

FetchContent_Declare( ENDFtk
GIT_REPOSITORY https://github.com/njoy/ENDFtk.git
GIT_TAG 0d3a1df1e7ddbf3ba9277badee4d4b538aadba0b
GIT_TAG d67492b23eae7f9fe9503fc6de89166f37202f49
)

FetchContent_Declare( fast_float
GIT_REPOSITORY https://github.com/fastfloat/fast_float
GIT_TAG f476bc713fda06fbd34dc621b466745a574b3d4c # tag: v6.1.1
)
set( ENDFtk.python CACHE INTERNAL BOOL ON )

FetchContent_Declare( pybind11
GIT_REPOSITORY https://github.com/pybind/pybind11
Expand All @@ -49,17 +43,17 @@ set( SPDLOG_BUILD_PIC CACHE INTERNAL BOOL ON )

FetchContent_Declare( tools
GIT_REPOSITORY https://github.com/njoy/tools
GIT_TAG 25c9273d05601a9644feea6d7539250bf1d1c0dc # tag: v0.2.0
GIT_TAG 14596b303de7413167f4f4c030e2923cabd3f2a3
)

#######################################################################
# Load dependencies
#######################################################################

FetchContent_MakeAvailable(
disco
eigen
ENDFtk
fast_float
range-v3
spdlog
tools
Expand Down
2 changes: 1 addition & 1 deletion cmake/unit_testing_python.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ function( add_python_test name source )
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/python )
set_tests_properties( ${test_name}
PROPERTIES ENVIRONMENT
PYTHONPATH=${CODEX_PYTHONPATH}:$ENV{PYTHONPATH})
PYTHONPATH=${ENDFTK_PYTHONPATH}:${CODEX_PYTHONPATH}:$ENV{PYTHONPATH})

endfunction()

Expand Down

0 comments on commit 5c6c090

Please sign in to comment.