mirror of
https://github.com/ton-blockchain/ton
synced 2025-03-09 15:40:10 +00:00
Various changes in TVM, github builds and tests (#793)
* Bugfixes in TVM and node * Upgrade to C++17 * Improve GitHub builds * Fix existing tests and partially integrate them into builds --------- Co-authored-by: neodiX42 <namlem@gmail.com> Co-authored-by: EmelyanenkoK <emelyanenko.kirill@gmail.com>
This commit is contained in:
parent
89700cb2aa
commit
5847897b37
122 changed files with 2889 additions and 4100 deletions
|
@ -13,7 +13,7 @@ echo `pwd`
|
|||
|
||||
git clone https://github.com/openssl/openssl.git
|
||||
cd openssl
|
||||
git checkout OpenSSL_1_1_1j
|
||||
git checkout checkout openssl-3.1.4
|
||||
./config
|
||||
make -j16
|
||||
OPENSSL_DIR=`pwd`
|
||||
|
|
32
.github/workflows/macos-11.7-compile.yml
vendored
32
.github/workflows/macos-11.7-compile.yml
vendored
|
@ -12,24 +12,33 @@ jobs:
|
|||
uses: actions/checkout@v3
|
||||
with:
|
||||
submodules: 'recursive'
|
||||
- name: Compile OpenSSL
|
||||
|
||||
- name: Compile Secp256k1
|
||||
run: |
|
||||
export NONINTERACTIVE=1
|
||||
brew install ninja secp256k1 libsodium libmicrohttpd pkg-config automake libtool
|
||||
git clone https://github.com/openssl/openssl openssl_1_1_1
|
||||
cd openssl_1_1_1
|
||||
git checkout OpenSSL_1_1_1-stable
|
||||
./Configure darwin64-x86_64-cc -static -mmacosx-version-min=11.7
|
||||
make build_libs -j4
|
||||
git clone https://github.com/libbitcoin/secp256k1.git
|
||||
cd secp256k1
|
||||
./autogen.sh
|
||||
./configure --enable-module-recovery
|
||||
make
|
||||
make install
|
||||
|
||||
- name: Build all
|
||||
run: |
|
||||
brew unlink openssl@3
|
||||
brew unlink openssl@1.1
|
||||
brew install openssl@3
|
||||
brew unlink openssl@3 && brew link --overwrite openssl@3
|
||||
rootPath=`pwd`
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -GNinja -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=$rootPath/openssl_1_1_1/include -DOPENSSL_CRYPTO_LIBRARY=$rootPath/openssl_1_1_1/libcrypto.a -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=11.7 -DCMAKE_CXX_FLAGS="-stdlib=libc++" -DCMAKE_BUILD_TYPE=Release ..
|
||||
ninja storage-daemon storage-daemon-cli blockchain-explorer fift func tonlib tonlibjson tonlib-cli validator-engine lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy adnl-proxy create-state create-hardfork tlbc emulator
|
||||
cmake -GNinja -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=11.7 -DCMAKE_CXX_FLAGS="-stdlib=libc++" -DCMAKE_BUILD_TYPE=Release ..
|
||||
|
||||
ninja storage-daemon storage-daemon-cli blockchain-explorer fift func tonlib tonlibjson tonlib-cli validator-engine \
|
||||
lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server \
|
||||
http-proxy rldp-http-proxy adnl-proxy create-state create-hardfork tlbc emulator \
|
||||
test-ed25519 test-ed25519-crypto test-bigint test-vm test-fift test-cells test-smartcont test-net test-tdactor \
|
||||
test-tdutils test-tonlib-offline test-adnl test-dht test-rldp test-rldp2 test-catchain test-fec test-tddb test-db test-validator-session-state
|
||||
|
||||
- name: Strip binaries
|
||||
run: |
|
||||
|
@ -51,6 +60,11 @@ jobs:
|
|||
strip build/utils/json2tlo
|
||||
strip build/adnl/adnl-proxy
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd build
|
||||
ctest --output-on-failure -E "test-catchain|test-actors"
|
||||
|
||||
- name: Find & copy binaries
|
||||
run: |
|
||||
mkdir artifacts
|
||||
|
|
29
.github/workflows/macos-12.6-compile.yml
vendored
29
.github/workflows/macos-12.6-compile.yml
vendored
|
@ -12,18 +12,11 @@ jobs:
|
|||
uses: actions/checkout@v3
|
||||
with:
|
||||
submodules: 'recursive'
|
||||
- name: Compile OpenSSL
|
||||
run: |
|
||||
export NONINTERACTIVE=1
|
||||
brew install ninja secp256k1 libsodium libmicrohttpd pkg-config automake libtool
|
||||
git clone https://github.com/openssl/openssl openssl_1_1_1
|
||||
cd openssl_1_1_1
|
||||
git checkout OpenSSL_1_1_1-stable
|
||||
./Configure darwin64-x86_64-cc -static -mmacosx-version-min=12.6
|
||||
make build_libs -j4
|
||||
|
||||
- name: Compile Secp256k1
|
||||
run: |
|
||||
export NONINTERACTIVE=1
|
||||
brew install ninja secp256k1 libsodium libmicrohttpd pkg-config automake libtool
|
||||
git clone https://github.com/libbitcoin/secp256k1.git
|
||||
cd secp256k1
|
||||
./autogen.sh
|
||||
|
@ -33,12 +26,19 @@ jobs:
|
|||
|
||||
- name: Build all
|
||||
run: |
|
||||
brew unlink openssl@3
|
||||
brew unlink openssl@1.1
|
||||
brew install openssl@3
|
||||
brew unlink openssl@3 && brew link --overwrite openssl@3
|
||||
rootPath=`pwd`
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -GNinja -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=$rootPath/openssl_1_1_1/include -DOPENSSL_CRYPTO_LIBRARY=$rootPath/openssl_1_1_1/libcrypto.a -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=12.6 -DCMAKE_CXX_FLAGS="-stdlib=libc++" -DCMAKE_BUILD_TYPE=Release ..
|
||||
ninja storage-daemon storage-daemon-cli blockchain-explorer fift func tonlib tonlibjson tonlib-cli validator-engine lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy adnl-proxy create-state create-hardfork tlbc emulator
|
||||
cmake -GNinja -DCMAKE_OSX_DEPLOYMENT_TARGET:STRING=12.6 -DCMAKE_CXX_FLAGS="-stdlib=libc++" -DCMAKE_BUILD_TYPE=Release ..
|
||||
|
||||
ninja storage-daemon storage-daemon-cli blockchain-explorer fift func tonlib tonlibjson tonlib-cli \
|
||||
validator-engine lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server \
|
||||
http-proxy rldp-http-proxy adnl-proxy create-state create-hardfork tlbc emulator \
|
||||
test-ed25519 test-ed25519-crypto test-bigint test-vm test-fift test-cells test-smartcont test-net test-tdactor \
|
||||
test-tdutils test-tonlib-offline test-adnl test-dht test-rldp test-rldp2 test-catchain test-fec test-tddb test-db test-validator-session-state
|
||||
|
||||
- name: Strip binaries
|
||||
run: |
|
||||
|
@ -60,6 +60,11 @@ jobs:
|
|||
strip build/utils/json2tlo
|
||||
strip build/adnl/adnl-proxy
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd build
|
||||
ctest --output-on-failure -E "test-catchain|test-actors"
|
||||
|
||||
- name: Find & copy binaries
|
||||
run: |
|
||||
mkdir artifacts
|
||||
|
|
2
.github/workflows/ton-x86-64-linux.yml
vendored
2
.github/workflows/ton-x86-64-linux.yml
vendored
|
@ -15,7 +15,7 @@ jobs:
|
|||
with:
|
||||
submodules: 'recursive'
|
||||
|
||||
- uses: cachix/install-nix-action@v18
|
||||
- uses: cachix/install-nix-action@v23
|
||||
with:
|
||||
extra_nix_config: |
|
||||
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
|
||||
|
|
2
.github/workflows/ton-x86-64-macos.yml
vendored
2
.github/workflows/ton-x86-64-macos.yml
vendored
|
@ -11,7 +11,7 @@ jobs:
|
|||
with:
|
||||
submodules: 'recursive'
|
||||
|
||||
- uses: cachix/install-nix-action@v22
|
||||
- uses: cachix/install-nix-action@v23
|
||||
with:
|
||||
extra_nix_config: |
|
||||
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
|
||||
|
|
20
.github/workflows/ubuntu-22.04-compile.yml
vendored
20
.github/workflows/ubuntu-22.04-compile.yml
vendored
|
@ -28,9 +28,9 @@ jobs:
|
|||
export CXX=$(which clang++)
|
||||
export CCACHE_DISABLE=1
|
||||
|
||||
git clone https://github.com/openssl/openssl openssl_1_1_1
|
||||
cd openssl_1_1_1
|
||||
git checkout OpenSSL_1_1_1-stable
|
||||
git clone https://github.com/openssl/openssl openssl_3
|
||||
cd openssl_3
|
||||
git checkout openssl-3.1.4
|
||||
./config
|
||||
make build_libs -j4
|
||||
|
||||
|
@ -39,13 +39,23 @@ jobs:
|
|||
mkdir build
|
||||
cd build
|
||||
|
||||
cmake -GNinja -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=$rootPath/openssl_1_1_1/include -DOPENSSL_CRYPTO_LIBRARY=$rootPath/openssl_1_1_1/libcrypto.a -DCMAKE_BUILD_TYPE=Release -DPORTABLE=1 -DTON_ARCH= ..
|
||||
ninja storage-daemon storage-daemon-cli fift func tonlib tonlibjson tonlib-cli validator-engine lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy adnl-proxy create-state emulator
|
||||
cmake -GNinja -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=$rootPath/openssl_3/include -DOPENSSL_CRYPTO_LIBRARY=$rootPath/openssl_3/libcrypto.a -DCMAKE_BUILD_TYPE=Release -DPORTABLE=1 -DTON_ARCH= ..
|
||||
|
||||
ninja storage-daemon storage-daemon-cli fift func tonlib tonlibjson tonlib-cli validator-engine lite-client \
|
||||
pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy \
|
||||
adnl-proxy create-state emulator \
|
||||
test-ed25519 test-ed25519-crypto test-bigint test-vm test-fift test-cells test-smartcont test-net test-tdactor \
|
||||
test-tdutils test-tonlib-offline test-adnl test-dht test-rldp test-rldp2 test-catchain test-fec test-tddb test-db test-validator-session-state
|
||||
|
||||
- name: Strip binaries
|
||||
run: |
|
||||
strip -g build/storage/storage-daemon/storage-daemon build/storage/storage-daemon/storage-daemon-cli build/crypto/fift build/crypto/tlbc build/crypto/func build/crypto/create-state build/validator-engine-console/validator-engine-console build/tonlib/tonlib-cli build/tonlib/libtonlibjson.so.0.5 build/http/http-proxy build/rldp-http-proxy/rldp-http-proxy build/dht-server/dht-server build/lite-client/lite-client build/validator-engine/validator-engine build/utils/generate-random-id build/utils/json2tlo build/adnl/adnl-proxy build/emulator/libemulator.*
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd build
|
||||
ctest --output-on-failure -E "test-catchain|test-actors"
|
||||
|
||||
- name: Find & copy binaries
|
||||
run: |
|
||||
mkdir artifacts
|
||||
|
|
21
.github/workflows/ubuntu-compile.yml
vendored
21
.github/workflows/ubuntu-compile.yml
vendored
|
@ -34,22 +34,31 @@ jobs:
|
|||
mkdir build-${{ matrix.os }}
|
||||
cd build-${{ matrix.os }}
|
||||
|
||||
git clone https://github.com/openssl/openssl openssl_1_1_1
|
||||
cd openssl_1_1_1
|
||||
git checkout OpenSSL_1_1_1-stable
|
||||
git clone https://github.com/openssl/openssl openssl_3
|
||||
cd openssl_3
|
||||
git checkout openssl-3.1.4
|
||||
./config
|
||||
make build_libs -j4
|
||||
|
||||
cd ..
|
||||
buildPath=`pwd`
|
||||
rootPath=`pwd`
|
||||
|
||||
cmake -GNinja -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=$buildPath/openssl_1_1_1/include -DOPENSSL_CRYPTO_LIBRARY=$buildPath/openssl_1_1_1/libcrypto.a -DCMAKE_BUILD_TYPE=Release -DPORTABLE=1 -DTON_ARCH= ..
|
||||
ninja storage-daemon storage-daemon-cli fift func tonlib tonlibjson tonlib-cli validator-engine lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy adnl-proxy create-state create-hardfork emulator
|
||||
cmake -GNinja -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=$rootPath/openssl_3/include -DOPENSSL_CRYPTO_LIBRARY=$rootPath/openssl_3/libcrypto.a -DCMAKE_BUILD_TYPE=Release -DPORTABLE=1 -DTON_ARCH= ..
|
||||
ninja storage-daemon storage-daemon-cli fift func tonlib tonlibjson tonlib-cli validator-engine lite-client \
|
||||
pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy adnl-proxy \
|
||||
create-state create-hardfork emulator \
|
||||
test-ed25519 test-ed25519-crypto test-bigint test-vm test-fift test-cells test-smartcont test-net test-tdactor \
|
||||
test-tdutils test-tonlib-offline test-adnl test-dht test-rldp test-rldp2 test-catchain test-fec test-tddb test-db test-validator-session-state
|
||||
|
||||
- name: Strip binaries
|
||||
run: |
|
||||
strip -g build-${{ matrix.os }}/storage/storage-daemon/storage-daemon build-${{ matrix.os }}/storage/storage-daemon/storage-daemon-cli build-${{ matrix.os }}/crypto/fift build-${{ matrix.os }}/crypto/tlbc build-${{ matrix.os }}/crypto/func build-${{ matrix.os }}/crypto/create-state build-${{ matrix.os }}/validator-engine-console/validator-engine-console build-${{ matrix.os }}/tonlib/tonlib-cli build-${{ matrix.os }}/tonlib/libtonlibjson.so.0.5 build-${{ matrix.os }}/http/http-proxy build-${{ matrix.os }}/rldp-http-proxy/rldp-http-proxy build-${{ matrix.os }}/dht-server/dht-server build-${{ matrix.os }}/lite-client/lite-client build-${{ matrix.os }}/validator-engine/validator-engine build-${{ matrix.os }}/utils/generate-random-id build-${{ matrix.os }}/utils/json2tlo build-${{ matrix.os }}/adnl/adnl-proxy build-${{ matrix.os }}/emulator/libemulator.*
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd build-${{ matrix.os }}
|
||||
ctest --output-on-failure -E "test-catchain|test-actors"
|
||||
|
||||
- name: Find & copy binaries
|
||||
run: |
|
||||
mkdir artifacts-${{ matrix.os }}
|
||||
|
|
15
.github/workflows/win-2019-compile.yml
vendored
15
.github/workflows/win-2019-compile.yml
vendored
|
@ -49,10 +49,10 @@ jobs:
|
|||
curl -Lo libsodium-1.0.18-stable-msvc.zip https://download.libsodium.org/libsodium/releases/libsodium-1.0.18-stable-msvc.zip
|
||||
unzip libsodium-1.0.18-stable-msvc.zip
|
||||
|
||||
- name: Install pre-compiled OpenSSL Win64
|
||||
- name: Install pre-compiled OpenSSL 3 Win64
|
||||
run: |
|
||||
curl -Lo openssl-1.1.1j.zip https://github.com/neodiX42/precompiled-openssl-win64/raw/main/openssl-1.1.1j.zip
|
||||
jar xf openssl-1.1.1j.zip
|
||||
curl -Lo openssl-3.1.4.zip https://github.com/neodiX42/precompiled-openssl-win64/raw/main/openssl-3.1.4.zip
|
||||
unzip openssl-3.1.4.zip
|
||||
|
||||
- name: Install pre-compiled libmicrohttpd Win64
|
||||
run: |
|
||||
|
@ -72,8 +72,13 @@ jobs:
|
|||
echo %SODIUM_DIR%
|
||||
mkdir build
|
||||
cd build
|
||||
cmake -DCMAKE_BUILD_TYPE=Release -DSODIUM_USE_STATIC_LIBS=1 -DSECP256K1_INCLUDE_DIR=%root%\secp256k1\include -DSECP256K1_LIBRARY=%root%\secp256k1\bin\x64\Release\v142\static\secp256k1.lib -DREADLINE_INCLUDE_DIR=%root%\readline-5.0-1-lib\include\readline -DREADLINE_LIBRARY=%root%\readline-5.0-1-lib\lib\readline.lib -DPORTABLE=1 -DZLIB_FOUND=1 -DMHD_FOUND=1 -DMHD_LIBRARY=%root%\libmicrohttpd-0.9.77-w32-bin\x86_64\VS2019\Release-static\libmicrohttpd.lib -DMHD_INCLUDE_DIR=%root%\libmicrohttpd-0.9.77-w32-bin\x86_64\VS2019\Release-static -DZLIB_INCLUDE_DIR=%root%\zlib -DZLIB_LIBRARY=%root%\zlib\contrib\vstudio\vc14\x64\ZlibStatReleaseWithoutAsm\zlibstat.lib -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=%root%/openssl-1.1.1j/include -DOPENSSL_CRYPTO_LIBRARY=%root%/openssl-1.1.1j/lib/libcrypto_static.lib -DCMAKE_CXX_FLAGS="/DTD_WINDOWS=1 /EHsc /bigobj /W0" ..
|
||||
cmake --build . --target storage-daemon storage-daemon-cli blockchain-explorer fift func tonlib tonlibjson tonlib-cli validator-engine lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy adnl-proxy create-state create-hardfork emulator --config Release
|
||||
cmake -DSODIUM_USE_STATIC_LIBS=1 -DSECP256K1_INCLUDE_DIR=%root%\secp256k1\include -DSECP256K1_LIBRARY=%root%\secp256k1\bin\x64\Release\v142\static\secp256k1.lib -DREADLINE_INCLUDE_DIR=%root%\readline-5.0-1-lib\include\readline -DREADLINE_LIBRARY=%root%\readline-5.0-1-lib\lib\readline.lib -DPORTABLE=1 -DZLIB_FOUND=1 -DMHD_FOUND=1 -DMHD_LIBRARY=%root%\libmicrohttpd-0.9.77-w32-bin\x86_64\VS2019\Release-static\libmicrohttpd.lib -DMHD_INCLUDE_DIR=%root%\libmicrohttpd-0.9.77-w32-bin\x86_64\VS2019\Release-static -DZLIB_INCLUDE_DIR=%root%\zlib -DZLIB_LIBRARY=%root%\zlib\contrib\vstudio\vc14\x64\ZlibStatReleaseWithoutAsm\zlibstat.lib -DOPENSSL_FOUND=1 -DOPENSSL_INCLUDE_DIR=%root%/openssl-3.1.4/x64/include -DOPENSSL_CRYPTO_LIBRARY=%root%/openssl-3.1.4/x64/lib/libcrypto_static.lib -DCMAKE_CXX_FLAGS="/DTD_WINDOWS=1 /EHsc /bigobj /W0" ..
|
||||
cmake --build . --config Release --target storage-daemon storage-daemon-cli blockchain-explorer fift func tonlib tonlibjson tonlib-cli validator-engine lite-client pow-miner validator-engine-console generate-random-id json2tlo dht-server http-proxy rldp-http-proxy adnl-proxy create-state create-hardfork emulator test-ed25519 test-ed25519-crypto test-bigint test-vm test-fift test-cells test-smartcont test-net test-tdactor test-tdutils test-tonlib-offline test-adnl test-dht test-rldp test-rldp2 test-catchain test-fec test-tddb test-db test-validator-session-state
|
||||
|
||||
- name: Run tests
|
||||
run: |
|
||||
cd build
|
||||
ctest -C Release --output-on-failure -E "test-catchain|test-actors|test-validator-session-state"
|
||||
|
||||
- name: Show executables
|
||||
run: |
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue