Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

CMake error include could not find load file #1273

Open
koga73 opened this issue Mar 10, 2022 · 4 comments
Open

CMake error include could not find load file #1273

koga73 opened this issue Mar 10, 2022 · 4 comments

Comments

@koga73
Copy link

koga73 commented Mar 10, 2022

I used eosio-init to generate the demo project on Ubuntu but am unable to compile it. I am using eosio-cpp version 1.8.1

INPUT:

cd build
cmake ..

OUTPUT:

-- The C compiler identification is GNU 7.5.0
-- The CXX compiler identification is GNU 7.5.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
CMake Error at /usr/local/lib/cmake/eosio.cdt/eosio.cdt-config.cmake:8 (include):
  include could not find load file:

    EosioWasmToolchain
Call Stack (most recent call first):
  CMakeLists.txt:4 (find_package)


CMake Error at /usr/local/lib/cmake/eosio.cdt/eosio.cdt-config.cmake:11 (include):
  include could not find load file:

    EosioCDTMacros
Call Stack (most recent call first):
  CMakeLists.txt:4 (find_package)


CMake Warning (dev) in CMakeLists.txt:
  No cmake_minimum_required command is present.  A line of code such as

    cmake_minimum_required(VERSION 3.10)

  should be added at the top of the file.  The version specified may be lower
  if you wish to support older CMake versions for this project.  For more
  information run "cmake --help-policy CMP0000".
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Configuring incomplete, errors occurred!
@praphael
Copy link
Contributor

praphael commented Mar 10, 2022

If you installed cmake after eosio.cdt, it may be unable to locate the necessary cmake modules. You might want to try reinstalling eosio-cdt.

@koga73
Copy link
Author

koga73 commented Apr 8, 2022

The issue turned out that EOSIO_CDT_ROOT was not defined, as a result the cmake script was looking in /tmp/eosio.cdt for the includes. The solution was to add this variable to the cmake command:

cmake .. -DEOSIO_CDT_ROOT=/usr/local

@koga73
Copy link
Author

koga73 commented Apr 11, 2022

Update - after getting past cmake with the added environment variable I now get stuck on the make command. It turns out that it is a problem with the image "wax-1.8.1-2.0.13wax03" - while this older image works perfectly "wax-1.6.1-2.0.13wax03". Hopefully the team will fix this issue in the next docker image.

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

No branches or pull requests

3 participants
@koga73 @praphael and others