moneroexamples / onion-monero-blockchain-explorer

Onion Monero Blockchain Explorer
https://xmrchain.net
BSD 3-Clause "New" or "Revised" License
371 stars 269 forks source link

Error when tring to build against Monero master branch. #312

Closed minerjed closed 5 months ago

minerjed commented 7 months ago

Tring to build the explorer but keep running into the following error.

/home/xcash/onion-monero-blockchain-explorer/src/MicroCore.cpp: In constructor ‘xmreg::MicroCore::MicroCore()’: /home/xcash/onion-monero-blockchain-explorer/src/MicroCore.cpp:23:9: error: ‘cryptonote::tx_memory_pool::tx_memory_pool(cryptonote::Blockchain&)’ is private within this context 23 | m_mempool(m_blockchain_storage), | ^~~~~~~ In file included from /home/xcash/onion-monero-blockchain-explorer/src/monero_headers.h:24, from /home/xcash/onion-monero-blockchain-explorer/src/MicroCore.h:10, from /home/xcash/onion-monero-blockchain-explorer/src/MicroCore.cpp:5: /home/xcash/monero/src/cryptonote_core/tx_pool.h:489:5: note: declared private here 489 | tx_memory_pool(Blockchain& bchs); | ^~~~~~ /home/xcash/onion-monero-blockchain-explorer/src/MicroCore.cpp:24:9: error: ‘cryptonote::Blockchain::Blockchain(cryptonote::tx_memory_pool&)’ is private within this context 24 | m_blockchain_storage(m_mempool) | ^~~~~~~ In file included from /home/xcash/onion-monero-blockchain-explorer/src/monero_headers.h:25, from /home/xcash/onion-monero-blockchain-explorer/src/MicroCore.h:10, from /home/xcash/onion-monero-blockchain-explorer/src/MicroCore.cpp:5: /home/xcash/monero/src/cryptonote_core/blockchain.h:1236:5: note: declared private here 1236 | Blockchain(tx_memory_pool& tx_pool); | ^~~~~~ make[2]: [src/CMakeFiles/myxrm.dir/build.make:76: src/CMakeFiles/myxrm.dir/MicroCore.cpp.o] Error 1 make[1]: [CMakeFiles/Makefile2:248: src/CMakeFiles/myxrm.dir/all] Error 2 make: *** [Makefile:91: all] Error 2

I am using the master branch or Monero and the devl branch of onion-monero-blockchain-explorer. I am on ubuntu 22.04.

minerjed commented 7 months ago

Looks like this is the change that broke it. #8924

moneroexamples commented 7 months ago

Does the issue still persist? Also are you building devel branch of the explorer against master of Monero?

minerjed commented 7 months ago

Yes, was building against master branch. I backed out pr #8924 in Monero to make it work.

moneroexamples commented 6 months ago

I tested the build and had no issues, thus I can't replicate the problem. Please double check that you are compiling devel branch of the explorer against master branch of Monero.

Cyrix126 commented 5 months ago

Hello, I had the same issue but indeed devel to master monero is working when master to master is not.

moneroexamples commented 5 months ago

Yes, usually master to master will not work, as they follow different branches of monero.