Unfortunately, I admit that I'm unable to compile it with the ubuntu way. Hence, I'm changing to visual studio again. Although I still don't get why I get these errors. I have installed the depends.
All the log:
1>------ Build started: Project: libbitcoinconsensus, Configuration: Debug Win32 ------
2>------ Build started: Project: libunivalue, Configuration: Debug Win32 ------
3>------ Build started: Project: libsecp256k1, Configuration: Debug Win32 ------
4>------ Build started: Project: libleveldb, Configuration: Debug Win32 ------
2>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
2>Done building project "libunivalue.vcxproj" -- FAILED.
1>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
1>Done building project "libbitcoinconsensus.vcxproj" -- FAILED.
5>------ Build started: Project: libbitcoin_qt, Configuration: Debug Win32 ------
6>------ Build started: Project: bitcoin-cli, Configuration: Debug Win32 ------
3>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
3>Done building project "libsecp256k1.vcxproj" -- FAILED.
7>------ Build started: Project: testconsensus, Configuration: Debug Win32 ------
6>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_cli\libbitcoin_cli.vcxproj' does not exist.
6>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_crypto\libbitcoin_crypto.vcxproj' does not exist.
6>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_util\libbitcoin_util.vcxproj' does not exist.
6>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
6>Done building project "bitcoin-cli.vcxproj" -- FAILED.
8>------ Build started: Project: bitcoin-tx, Configuration: Debug Win32 ------
5>Performing libbitcoin_qt moc code include generation task, output path .\QtGeneratedFiles\qt.
5>C:\Qt5.9.8_x64_static_vs2019\bin\moc.exe "..\..\src\qt\bitcoinamountfield.cpp" -o .\QtGeneratedFiles\qt\bitcoinamountfield.moc.
4>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
4>Done building project "libleveldb.vcxproj" -- FAILED.
9>------ Build started: Project: bitcoind, Configuration: Debug Win32 ------
5>C:\Qt5.9.8_x64_static_vs2019\bin\moc.exe "..\..\src\qt\intro.cpp" -o .\QtGeneratedFiles\qt\intro.moc.
5>C:\Qt5.9.8_x64_static_vs2019\bin\moc.exe "..\..\src\qt\overviewpage.cpp" -o .\QtGeneratedFiles\qt\overviewpage.moc.
5>C:\Qt5.9.8_x64_static_vs2019\bin\moc.exe "..\..\src\qt\rpcconsole.cpp" -o .\QtGeneratedFiles\qt\rpcconsole.moc.
5>The system cannot find the path specified.
5>C:\bitcoin\build_msvc\libbitcoin_qt\libbitcoin_qt.vcxproj(168,5): error MSB3073: The command "C:\Qt5.9.8_x64_static_vs2019\bin\moc.exe "..\..\src\qt\bitcoinamountfield.cpp" -o .\QtGeneratedFiles\qt\bitcoinamountfield.moc" exited with code 3.
5>Done building project "libbitcoin_qt.vcxproj" -- FAILED.
7>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_util\libbitcoin_util.vcxproj' does not exist.
7>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
7>Done building project "testconsensus.vcxproj" -- FAILED.
9>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_common\libbitcoin_common.vcxproj' does not exist.
9>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_crypto\libbitcoin_crypto.vcxproj' does not exist.
9>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_server\libbitcoin_server.vcxproj' does not exist.
9>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_util\libbitcoin_util.vcxproj' does not exist.
9>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_wallet\libbitcoin_wallet.vcxproj' does not exist.
9>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_zmq\libbitcoin_zmq.vcxproj' does not exist.
9>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
9>Done building project "bitcoind.vcxproj" -- FAILED.
8>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_common\libbitcoin_common.vcxproj' does not exist.
8>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_crypto\libbitcoin_crypto.vcxproj' does not exist.
8>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_util\libbitcoin_util.vcxproj' does not exist.
8>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
8>Done building project "bitcoin-tx.vcxproj" -- FAILED.
10>------ Build started: Project: test_bitcoin, Configuration: Debug Win32 ------
11>------ Build started: Project: bitcoin-wallet, Configuration: Debug Win32 ------
12>------ Build started: Project: bitcoin-qt, Configuration: Debug Win32 ------
13>------ Build started: Project: test_bitcoin-qt, Configuration: Debug Win32 ------
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_cli\libbitcoin_cli.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_common\libbitcoin_common.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_crypto\libbitcoin_crypto.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_server\libbitcoin_server.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_util\libbitcoin_util.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_wallet\libbitcoin_wallet.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_zmq\libbitcoin_zmq.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_wallet_tool\libbitcoin_wallet_tool.vcxproj' does not exist.
11>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
11>Done building project "bitcoin-wallet.vcxproj" -- FAILED.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_cli\libbitcoin_cli.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_common\libbitcoin_common.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_crypto\libbitcoin_crypto.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_server\libbitcoin_server.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_util\libbitcoin_util.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_wallet\libbitcoin_wallet.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_zmq\libbitcoin_zmq.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libtest_util\libtest_util.vcxproj' does not exist.
10>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
10>Done building project "test_bitcoin.vcxproj" -- FAILED.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_cli\libbitcoin_cli.vcxproj' does not exist.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_common\libbitcoin_common.vcxproj' does not exist.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_crypto\libbitcoin_crypto.vcxproj' does not exist.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_server\libbitcoin_server.vcxproj' does not exist.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_util\libbitcoin_util.vcxproj' does not exist.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_wallet\libbitcoin_wallet.vcxproj' does not exist.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets(1823,5): warning : The referenced project '..\libbitcoin_zmq\libbitcoin_zmq.vcxproj' does not exist.
12>C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.Cpp.Platform.targets(57,5): error MSB8020: The build tools for v142 (Platform Toolset = 'v142') cannot be found. To build using the v142 build tools, please install v142 build tools. Alternatively, you may upgrade to the current Visual Studio tools by selecting the Project menu or right-click the solution, and then selecting "Retarget solution".
12>Done building project "bitcoin-qt.vcxproj" -- FAILED.
13>Performing test_bitcoin-qt moc generation task, output path .\QtGeneratedFiles\qt\moc.
13>The system cannot find the path specified.
13>C:\bitcoin\build_msvc\test_bitcoin-qt\test_bitcoin-qt.vcxproj(103,5): error MSB3073: The command "C:\Qt5.9.8_x64_static_vs2019\bin\moc.exe "..\..\src\qt\test\addressbooktests.h" -o .\QtGeneratedFiles\qt\moc\moc_addressbooktests.cpp" exited with code 3.
13>Done building project "test_bitcoin-qt.vcxproj" -- FAILED.
========== Build: 0 succeeded, 13 failed, 0 up-to-date, 0 skipped ==========
I just click build and then build solution.
README.md doesn't tell me to do it, but I consider it implied.
Why is compiling bitcoin core so hard? I'm trying 2 weeks now, and I'm really pissed off...