feat: Install validator-keys (#5841)

* feat: Install validator-keys

* output validator-keys with everything else
This commit is contained in:
Michael Legleux
2025-10-14 15:02:38 -07:00
committed by GitHub
parent 34619f2504
commit 97bc94a7f6
2 changed files with 9 additions and 11 deletions

View File

@@ -38,7 +38,7 @@ install(CODE "
set(CMAKE_MODULE_PATH \"${CMAKE_MODULE_PATH}\") set(CMAKE_MODULE_PATH \"${CMAKE_MODULE_PATH}\")
include(create_symbolic_link) include(create_symbolic_link)
create_symbolic_link(xrpl \ create_symbolic_link(xrpl \
\${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_INCLUDEDIR}/ripple) \$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_INCLUDEDIR}/ripple)
") ")
install (EXPORT RippleExports install (EXPORT RippleExports
@@ -72,7 +72,7 @@ if (is_root_project AND TARGET rippled)
set(CMAKE_MODULE_PATH \"${CMAKE_MODULE_PATH}\") set(CMAKE_MODULE_PATH \"${CMAKE_MODULE_PATH}\")
include(create_symbolic_link) include(create_symbolic_link)
create_symbolic_link(rippled${suffix} \ create_symbolic_link(rippled${suffix} \
\${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR}/xrpld${suffix}) \$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_BINDIR}/xrpld${suffix})
") ")
endif () endif ()

View File

@@ -1,4 +1,4 @@
option (validator_keys "Enables building of validator-keys-tool as a separate target (imported via FetchContent)" OFF) option (validator_keys "Enables building of validator-keys tool as a separate target (imported via FetchContent)" OFF)
if (validator_keys) if (validator_keys)
git_branch (current_branch) git_branch (current_branch)
@@ -6,17 +6,15 @@ if (validator_keys)
if (NOT (current_branch STREQUAL "release")) if (NOT (current_branch STREQUAL "release"))
set (current_branch "master") set (current_branch "master")
endif () endif ()
message (STATUS "tracking ValidatorKeys branch: ${current_branch}") message (STATUS "Tracking ValidatorKeys branch: ${current_branch}")
FetchContent_Declare ( FetchContent_Declare (
validator_keys_src validator_keys
GIT_REPOSITORY https://github.com/ripple/validator-keys-tool.git GIT_REPOSITORY https://github.com/ripple/validator-keys-tool.git
GIT_TAG "${current_branch}" GIT_TAG "${current_branch}"
) )
FetchContent_GetProperties (validator_keys_src) FetchContent_MakeAvailable(validator_keys)
if (NOT validator_keys_src_POPULATED) set_target_properties(validator-keys PROPERTIES RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}")
message (STATUS "Pausing to download ValidatorKeys...") install(TARGETS validator-keys RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
FetchContent_Populate (validator_keys_src)
endif ()
add_subdirectory (${validator_keys_src_SOURCE_DIR} ${CMAKE_BINARY_DIR}/validator-keys)
endif () endif ()