mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-19 18:45:52 +00:00
Introduces a conanfile.py (and a Conan recipe for RocksDB) to enable building the package with Conan, choosing more recent default versions of dependencies. It removes almost all of the CMake build files related to dependencies, and the configurations for Travis CI and GitLab CI. A new set of cross-platform build instructions are written in BUILD.md. Includes example GitHub Actions workflow for each of Linux, macOS, Windows. * Test on macos-12 We use the <concepts> library which was not added to Apple Clang until version 13.1.6. The default Clang on macos-11 (the sometimes current version of macos-latest) is 13.0.0, and the default Clang on macos-12 is 14.0.0. Closes #4223.
51 lines
1.8 KiB
CMake
51 lines
1.8 KiB
CMake
#[===================================================================[
|
|
install stuff
|
|
#]===================================================================]
|
|
|
|
install (
|
|
TARGETS
|
|
common
|
|
opts
|
|
ripple_syslibs
|
|
ripple_boost
|
|
xrpl_core
|
|
EXPORT RippleExports
|
|
LIBRARY DESTINATION lib
|
|
ARCHIVE DESTINATION lib
|
|
RUNTIME DESTINATION bin
|
|
INCLUDES DESTINATION include)
|
|
|
|
install (EXPORT RippleExports
|
|
FILE RippleTargets.cmake
|
|
NAMESPACE Ripple::
|
|
DESTINATION lib/cmake/ripple)
|
|
include (CMakePackageConfigHelpers)
|
|
write_basic_package_version_file (
|
|
RippleConfigVersion.cmake
|
|
VERSION ${rippled_version}
|
|
COMPATIBILITY SameMajorVersion)
|
|
|
|
if (is_root_project)
|
|
install (TARGETS rippled RUNTIME DESTINATION bin)
|
|
set_target_properties(rippled PROPERTIES INSTALL_RPATH_USE_LINK_PATH ON)
|
|
install (
|
|
FILES
|
|
${CMAKE_CURRENT_SOURCE_DIR}/Builds/CMake/RippleConfig.cmake
|
|
${CMAKE_CURRENT_BINARY_DIR}/RippleConfigVersion.cmake
|
|
DESTINATION lib/cmake/ripple)
|
|
# sample configs should not overwrite existing files
|
|
# install if-not-exists workaround as suggested by
|
|
# https://cmake.org/Bug/view.php?id=12646
|
|
install(CODE "
|
|
macro (copy_if_not_exists SRC DEST NEWNAME)
|
|
if (NOT EXISTS \"\$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/\${DEST}/\${NEWNAME}\")
|
|
file (INSTALL FILE_PERMISSIONS OWNER_READ OWNER_WRITE DESTINATION \"\${CMAKE_INSTALL_PREFIX}/\${DEST}\" FILES \"\${SRC}\" RENAME \"\${NEWNAME}\")
|
|
else ()
|
|
message (\"-- Skipping : \$ENV{DESTDIR}\${CMAKE_INSTALL_PREFIX}/\${DEST}/\${NEWNAME}\")
|
|
endif ()
|
|
endmacro()
|
|
copy_if_not_exists(\"${CMAKE_CURRENT_SOURCE_DIR}/cfg/rippled-example.cfg\" etc rippled.cfg)
|
|
copy_if_not_exists(\"${CMAKE_CURRENT_SOURCE_DIR}/cfg/validators-example.txt\" etc validators.txt)
|
|
")
|
|
endif ()
|