Page MenuHomePhabricator

[avalanche] Move the global definitions into their own header
ClosedPublic

Authored by Fabien on Jun 8 2021, 13:11.

Details

Reviewers
PiRK
Group Reviewers
Restricted Project
Maniphest Tasks
Restricted Maniphest Task
Commits
rABC478f68235d39: [avalanche] Move the global definitions into their own header
Summary

Move the declarations that belong to the global namespace into their own
header. This reduce the scope of inclusion when all that is needed is to
check the -enableavalanche option, and will also prevent from
introducing circular dependencies between the avalanche processor and
the network layer.

Ref T1611.

Test Plan
ninja all check

Diff Detail

Event Timeline

Fabien requested review of this revision.Jun 8 2021, 13:11

Tail of the build log:

[400/452] bitcoin: testing coinselector_tests
[401/452] bitcoin: testing blockcheck_tests
[402/452] bitcoin: testing schnorr_tests
[403/452] Building CXX object src/avalanche/test/CMakeFiles/test-avalanche.dir/processor_tests.cpp.o
[404/452] Running utility command for check-bitcoin-checkpoints_tests
[405/452] Running utility command for check-bitcoin-serialize_tests
[406/452] Running utility command for check-bitcoin-schnorr_tests
[407/452] Running utility command for check-bitcoin-blockcheck_tests
[408/452] Running utility command for check-bitcoin-coinselector_tests
[409/452] Running utility command for check-pow-grasberg_tests
[410/452] Running utility command for check-pow-aserti32d_tests
[411/452] bitcoin: testing blockstatus_tests
[412/452] Running pow test suite
PASSED: pow test suite
[413/452] Building CXX object src/qt/test/CMakeFiles/test_bitcoin-qt.dir/uritests.cpp.o
[414/452] Building CXX object src/qt/test/CMakeFiles/test_bitcoin-qt.dir/util.cpp.o
[415/452] Running utility command for check-bitcoin-blockstatus_tests
[416/452] bitcoin: testing validationinterface_tests
[417/452] Building CXX object src/qt/test/CMakeFiles/test_bitcoin-qt.dir/addressbooktests.cpp.o
[418/452] Building CXX object src/qt/test/CMakeFiles/test_bitcoin-qt.dir/wallettests.cpp.o
[419/452] Building CXX object src/qt/test/CMakeFiles/test_bitcoin-qt.dir/__/__/wallet/test/wallet_test_fixture.cpp.o
[420/452] bitcoin: testing cashaddr_tests
[421/452] Running utility command for check-bitcoin-validationinterface_tests
[422/452] Building CXX object src/qt/test/CMakeFiles/test_bitcoin-qt.dir/paymentservertests.cpp.o
[423/452] Running utility command for check-bitcoin-cashaddr_tests
[424/452] bitcoin: testing script_tests
[425/452] Running utility command for check-bitcoin-script_tests
[426/452] Linking CXX executable src/avalanche/test/test-avalanche
[427/452] bitcoin: testing versionbits_tests
[428/452] Running utility command for check-bitcoin-versionbits_tests
[429/452] bitcoin: testing crypto_tests
[430/452] Running utility command for check-bitcoin-crypto_tests
[431/452] avalanche: testing delegation_tests
[432/452] Running utility command for check-avalanche-delegation_tests
[433/452] Linking CXX executable src/qt/test/test_bitcoin-qt
[434/452] avalanche: testing orphanproofpool_tests
[435/452] bitcoin: testing monolith_opcodes_tests
[436/452] Running utility command for check-avalanche-orphanproofpool_tests
[437/452] Running utility command for check-bitcoin-monolith_opcodes_tests
[438/452] avalanche: testing proof_tests
[439/452] Running utility command for check-avalanche-proof_tests
[440/452] avalanche: testing peermanager_tests
[441/452] Running utility command for check-avalanche-peermanager_tests
[442/452] secp256k1: testing secp256k1-exhaustive_tests
[443/452] avalanche: testing processor_tests
FAILED: src/avalanche/test/CMakeFiles/check-avalanche-processor_tests 
cd /work/abc-ci-builds/build-clang/src/avalanche/test && /usr/bin/cmake -E make_directory /work/abc-ci-builds/build-clang/test/junit && /usr/bin/cmake -E make_directory /work/abc-ci-builds/build-clang/test/log && /usr/bin/cmake -E env /work/cmake/utils/log-and-print-on-failure.sh /work/abc-ci-builds/build-clang/test/log/avalanche-processor_tests.log /work/abc-ci-builds/build-clang/src/avalanche/test/test-avalanche --run_test=processor_tests --logger=HRF,message:JUNIT,message,avalanche-processor_tests.xml --catch_system_errors=no
Segmentation fault (core dumped)
[444/452] bitcoin-qt: testing test_bitcoin-qt
[445/452] Running bitcoin-qt test suite
PASSED: bitcoin-qt test suite
[446/452] bitcoin: testing coins_tests
[447/452] Running utility command for check-bitcoin-coins_tests
[448/452] Running bitcoin test suite
PASSED: bitcoin test suite
[449/452] secp256k1: testing secp256k1-tests
[450/452] Running secp256k1 test suite
PASSED: secp256k1 test suite
ninja: build stopped: cannot make progress due to previous errors.
Build build-clang failed with exit code 1

Unrelated spurious processor_tests failure. I managed to reproduce by chance on my machine and I have a core dump to debug on now

This revision is now accepted and ready to land.Jun 8 2021, 15:14