Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't build rippled v1.10.0 (liblz4 error) #4462

Closed
gituser opened this issue Mar 15, 2023 · 9 comments
Closed

Can't build rippled v1.10.0 (liblz4 error) #4462

gituser opened this issue Mar 15, 2023 · 9 comments

Comments

@gituser
Copy link

gituser commented Mar 15, 2023

Issue Description

Can't build recent rippled v1.10.0 on Ubuntu 18.04 LTS due to this error:

CMake Error at CMakeLists.txt:76 (find_package):
  By not providing "Findlz4.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "lz4", but
  CMake did not find one.

  Could not find a package configuration file provided by "lz4" with any of
  the following names:

    lz4Config.cmake
    lz4-config.cmake

  Add the installation prefix of "lz4" to CMAKE_PREFIX_PATH or set "lz4_DIR"
  to a directory containing one of the above files.  If "lz4" provides a
  separate development package or SDK, be sure it has been installed.

liblz4 is installed on the system:

$ dpkg -l|grep liblz4
ii  liblz4-1:amd64                        0.0~r131-2ubuntu3.1                        amd64        Fast LZ compression algorithm library - runtime
ii  liblz4-dev:amd64                      0.0~r131-2ubuntu3.1                        amd64        Fast LZ compression algorithm library - development files
ii  liblz4-tool                           0.0~r131-2ubuntu3.1                        amd64        Fast LZ compression algorithm library - tool

Environment

Ubuntu 18.04 LTS (latest)
Boost v1.71
CMake 3.25.2

Previous version of rippled v1.9.4 built just fine on the same environment.

Supporting Files

-- The C compiler identification is Clang 10.0.0
-- The CXX compiler identification is Clang 10.0.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/clang-10 - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/clang++-10 - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found Git: /usr/bin/git (found version "2.39.2") 
-- gch:07f047b1e260e5b937af28e8f8da9c360ea832b9
-- Using 12 cores for ExternalProject builds.
-- rippled version: 1.10.0
-- docker NOT found -- won't be able to build containers for packaging
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Check if compiler accepts -pthread
-- Check if compiler accepts -pthread - yes
-- Found Threads: TRUE  
-- Found Boost: /home/build/boost/boost_1_71_0 (found suitable version "1.71.0", minimum required is "1.70") found components: chrono container context coroutine date_time filesystem program_options regex system thread atomic 
-- Found OpenSSL: /usr/lib/x86_64-linux-gnu/libcrypto.so (found suitable version "1.1.1", minimum required is "1.1.1")  
CMake Error at CMakeLists.txt:76 (find_package):
  By not providing "Findlz4.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "lz4", but
  CMake did not find one.

  Could not find a package configuration file provided by "lz4" with any of
  the following names:

    lz4Config.cmake
    lz4-config.cmake

  Add the installation prefix of "lz4" to CMAKE_PREFIX_PATH or set "lz4_DIR"
  to a directory containing one of the above files.  If "lz4" provides a
  separate development package or SDK, be sure it has been installed.


-- Configuring incomplete, errors occurred!
See also "/home/build/ripple/source/build/release/CMakeFiles/CMakeOutput.log".
See also "/home/build/ripple/source/build/release/CMakeFiles/CMakeError.log".
[-] cmake failed

For some reason Findlz4.cmake along side other CMake helpers disappeared in v1.10.0:

~/ripple/source/Builds/CMake/deps$ ls -al
total 20
drwxrwxr-x 2 build build 4096 Mar 15 14:02 .
drwxrwxr-x 3 build build 4096 Mar 15 14:02 ..
-rw-rw-r-- 1 build build 1479 Mar 15 14:02 Boost.cmake
-rw-rw-r-- 1 build build  727 Mar 15 14:02 Protobuf.cmake
-rw-rw-r-- 1 build build 2596 Mar 15 14:02 gRPC.cmake

In v1.9.4:

~/ripple/source/Builds/CMake/deps$ ls -al
total 236
drwxrwxr-x 2 build build   4096 Mar 15 14:01 .
drwxrwxr-x 3 build build   4096 Mar 15 14:01 ..
-rw-rw-r-- 1 build build   3166 Mar 15 14:01 Boost.cmake
-rw-rw-r-- 1 build build   1065 Mar 15 14:01 Ed25519-donna.cmake
-rw-rw-r-- 1 build build 103688 Mar 15 14:01 FindBoost.cmake
-rw-rw-r-- 1 build build   1524 Mar 15 14:01 Findjemalloc.cmake
-rw-rw-r-- 1 build build    467 Mar 15 14:01 Findlibarchive_pc.cmake
-rw-rw-r-- 1 build build    409 Mar 15 14:01 Findlz4.cmake
-rw-rw-r-- 1 build build    485 Mar 15 14:01 Findsecp256k1.cmake
-rw-rw-r-- 1 build build    453 Mar 15 14:01 Findsnappy.cmake
-rw-rw-r-- 1 build build    325 Mar 15 14:01 Findsoci.cmake
-rw-rw-r-- 1 build build    456 Mar 15 14:01 Findsqlite.cmake
-rw-rw-r-- 1 build build   6082 Mar 15 14:01 Libarchive.cmake
-rw-rw-r-- 1 build build   2334 Mar 15 14:01 Lz4.cmake
-rw-rw-r-- 1 build build   1114 Mar 15 14:01 Nudb.cmake
-rw-rw-r-- 1 build build   1768 Mar 15 14:01 OpenSSL.cmake
-rw-rw-r-- 1 build build   3339 Mar 15 14:01 Postgres.cmake
-rw-rw-r-- 1 build build   6204 Mar 15 14:01 Protobuf.cmake
-rw-rw-r-- 1 build build   6988 Mar 15 14:01 Rocksdb.cmake
-rw-rw-r-- 1 build build   1614 Mar 15 14:01 Secp256k1.cmake
-rw-rw-r-- 1 build build   2495 Mar 15 14:01 Snappy.cmake
-rw-rw-r-- 1 build build   6838 Mar 15 14:01 Soci.cmake
-rw-rw-r-- 1 build build   3256 Mar 15 14:01 Sqlite.cmake
-rw-rw-r-- 1 build build   6358 Mar 15 14:01 cassandra.cmake
-rw-rw-r-- 1 build build    606 Mar 15 14:01 date.cmake
-rw-rw-r-- 1 build build  15780 Mar 15 14:01 gRPC.cmake
@cen1
Copy link

cen1 commented Mar 15, 2023

Using conan seems to work but there is a lot of source compiling of dependencies. Would be nice if this can get a quick hotfix.

@gituser
Copy link
Author

gituser commented Mar 15, 2023

So cmake build is completely removed?
Why break what worked since early versions of rippled.

@cen1
Copy link

cen1 commented Mar 15, 2023

Ofc not, cmake is not removed but it seems they removed all the Find* cmake scripts and now prefer conan for dependency resolution and package management.

@ximinez
Copy link
Collaborator

ximinez commented Mar 15, 2023

Please check out the new build instructions: https://github.com/XRPLF/rippled/blob/develop/BUILD.md

@alloynetworks
Copy link
Contributor

See if this helps you : https://github.com/XRPLF/rippled-portable-builds

@thejohnfreeman
Copy link
Collaborator

@intelliot
Copy link
Collaborator

If https://github.com/XRPLF/rippled/blob/develop/BUILD.md doesn't solve your issue, please open a new one. Include the specific steps that one can take in order to reproduce the problem. Thanks!

@rudy113
Copy link

rudy113 commented Jan 22, 2024

I'm having this same issue when trying build validator-keys-tool (not rippled). Have rippled installed successfully.

command: cmake -DCMAKE_BUILD_TYPE=Release ../..

get this error:
Could` not find a package configuration file provided by "lz4" with any of the following names:
lz4Config.cmake
lz4-config.cmake

@intelliot
Copy link
Collaborator

@rudy113 , I opened a new issue for you: #4894. Please comment there with any additional details or things that you have tried.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants