ton-blockchain / ton

Main TON monorepo
Other
3.05k stars 962 forks source link

Building failed (tlb_generate_block.dir/build.make:62) #35

Closed Obadah-H closed 2 years ago

Obadah-H commented 5 years ago

Building ton gives an error. Commands I'm using to build:

    git submodule update --init --recursive
    mkdir build && cd build
    cmake -DCMAKE_BUILD_TYPE=Release ..
    cmake --build .

The last command gives the following output:

    [  0%] Built target crc32c_arm64
    [  0%] Built target crc32c_sse42
    [  0%] Built target crc32c
    [  0%] Built target absl_dynamic_annotations
    [  0%] Built target absl_log_severity
    [  0%] Built target absl_spinlock_wait
    [  1%] Built target absl_raw_logging_internal
    [  2%] Built target absl_base
    [  2%] Built target absl_malloc_internal
    [  2%] Built target absl_throw_delegate
    [  2%] Built target absl_bad_optional_access
    [  2%] Built target absl_civil_time
    [  2%] Built target absl_debugging_internal
    [  4%] Built target absl_demangle_internal
    [  4%] Built target absl_symbolize
    [  4%] Built target absl_stacktrace
    [  5%] Built target absl_int128
    [  5%] Built target absl_strings_internal
    [  6%] Built target absl_strings
    [  6%] Built target absl_graphcycles_internal
    [  8%] Built target absl_time_zone
    [  9%] Built target absl_time
    [ 11%] Built target absl_synchronization
    [ 11%] Built target absl_hashtablez_sampler
    [ 11%] Built target absl_raw_hash_set
    [ 11%] Built target absl_city
    [ 11%] Built target absl_bad_variant_access
    [ 11%] Built target absl_hash
    [ 18%] Built target tdutils
    [ 23%] Built target ton_crypto
    [ 23%] Built target common
    [ 23%] Built target tdactor
    [ 25%] Built target tdtl
    [ 25%] Built target generate_common
    [ 25%] Generate common tl source files
    [ 25%] Built target tl_generate_common
    [ 25%] Built target tl_api
    [ 25%] Built target keyring
    [ 25%] Built target build_version
    [ 51%] Built target rocksdb
    [ 51%] Built target tdnet
    [ 52%] Built target tddb
    [ 52%] Built target tl-utils
    [ 52%] Built target keys
    [ 54%] Built target adnl
    [ 55%] Built target dht
    [ 58%] Built target tdfec
    [ 58%] Built target fec
    [ 58%] Built target overlay
    [ 59%] Built target catchain
    [ 61%] Built target rldp
    [ 62%] Built target validatorsession
    [ 62%] Built target test-validator-session-state
    [ 62%] Built target adnltest
    [ 62%] Built target test-rldp
    [ 62%] Built target test-hello-world
    [ 62%] Built target test-fec
    [ 62%] Built target test-dht
    [ 62%] Built target src_parser
    [ 62%] Built target tlbc
    [ 62%] Generate block tlb source files
    block.tlb:1:15: error: constructor name lowercase identifier expected
      unit$_ = Unit;
                    ^

    crypto/CMakeFiles/tlb_generate_block.dir/build.make:62: recipe for target '../crypto/block/block-auto.cpp' failed
    make[2]: *** [../crypto/block/block-auto.cpp] Error 1
    CMakeFiles/Makefile2:7727: recipe for target 'crypto/CMakeFiles/tlb_generate_block.dir/all' failed
    make[1]: *** [crypto/CMakeFiles/tlb_generate_block.dir/all] Error 2
    Makefile:140: recipe for target 'all' failed
    make: *** [all] Error 2
logvik commented 5 years ago

try to use g++-7 for C and CXX compilers. It works for me on Ubuntu 14.04

Obadah-H commented 5 years ago

I'm using g++-7 and it's the default one. I'm running Ubuntu 18.04

logvik commented 5 years ago

You can try to use it -> https://github.com/akme/ton-node/blob/master/Dockerfile

Obadah-H commented 5 years ago

Thanks for this solution, my problem is solved. I'll keep this thread open as this solution doesn't solve the BUILDING error.

ton-blockchain commented 5 years ago

Do you use an operating system with CP/M-compatible line breaks?

Obadah-H commented 5 years ago

Yep - I wrote that I'm using Ubuntu 18.04

EmelyanenkoK commented 2 years ago

Please check workflows as compilation guide.