0

I am trying to setup Local Multi-Node Testnet using the version 2.0.7.

Clone the sysytem contracts from the repo as follows.

      git clone https://github.com/EOSIO/eosio.contracts --branch master --single-branch

Creating wasm and abi files using the following command.

      cd eosio.contracts/contracts/eosio.bios
      eosio-cpp -I include -o eosio.bios.wasm src/eosio.bios.cpp --abigen

But it generates the following compilation error.

    In file included from /home/user/eosio/eosio.contracts/contracts/eosio.bios  /src/eosio.bios.cpp:1:
    include/eosio.bios/eosio.bios.hpp:237:50: error: no member named  'producer_authority' in namespace 'eosio'
         void setprods( const std::vector<eosio::producer_authority>& schedule );
                                      ~~~~~~~^
   /home/user/eosio/eosio.contracts/contracts/eosio.bios/src/eosio.bios.cpp:34:47:  error: no member named 'producer_authority' in namespace 'eosio'
      void bios::setprods( const std::vector<eosio::producer_authority>& schedule ) {
                                   ~~~~~~~^
   /home/user/eosio/eosio.contracts/contracts/eosio.bios/src/eosio.bios.cpp:50:4: error: use of undeclared identifier 'preactivate_feature'
   preactivate_feature( feature_digest );
   ^
     /home/user/eosio/eosio.contracts/contracts/eosio.bios/src/eosio.bios.cpp:54:11: error: use of undeclared identifier 'is_feature_activated'
   check( is_feature_activated( feature_digest ), "protocol feature is not activated" );

    4 errors generated.
    abigen error

Did anyone face this similar issue?Help is appreciated .

1 Answer 1

1

If you want to build a single contract with eosio.cdt you would need to modify the code.

Just use the build-script build.sh (located in the eosio.contracts-directory) to compile all system-contracts at once, without the need to modify any of them.

1
  • I have updated the version of 'eosio.cdt' to 1.7.0 and able to successfully compile the contracts using 'build.sh'
    – cmr
    Commented Oct 16, 2020 at 11:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.