amule uses a lot of deprecated asio functions removed from boost-1.87.0. Find the attached patch. Reproducible: Always Steps to Reproduce: 1. emerge dev-libs/boost-1.87.0 2. emerge net-p2p/amule 3. Actual Results: Build fail Expected Results: Build ok
Created attachment 914103 [details, diff] Replace removed asio functions
Is this reported to upstream already?
Created attachment 914147 [details, diff] Updated patch to work with portage
PR Upstream https://github.com/amule-project/amule/pull/387
(In reply to David Carlos Manuelda from comment #2) > Is this reported to upstream already? Just this morning. ciao
*** Bug 946794 has been marked as a duplicate of this bug. ***
still not fixed? don't know if this is the same bug : /usr/include/boost/bind.hpp:36:1: note: ‘#pragma message: The practice of declaring the Bind placeholders (_1, _2, ...) in the global namespace is deprecated. Please use <boost/bind/bind.hpp> + using namespace boost::placeholders, or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain the current behavior.’ 36 | BOOST_PRAGMA_MESSAGE( | ^~~~~~~~~~~~~~~~~~~~ x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I.. -DUSE_WX_EXTENSIONS -I/usr/lib64/wx/include/gtk3-unicode-3.2-gtk3 -I/usr/include/wx-3.2-gtk3 -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -DNDEBUG -DwxDEBUG_LEVEL=0 -W -Wall -Wshadow -Wundef -march=native -O2 -pipe -std=gnu++14 -c -o libmuleappcore_a-StateMachine.o `test -f 'StateMachine.cpp' || echo './'`StateMachine.cpp LibSocketAsio.cpp:73:8: error: ‘io_service’ does not name a type; did you mean ‘CAsioService’? 73 | static io_service s_io_service; | ^~~~~~~~~~ | CAsioService LibSocketAsio.cpp:621:9: error: ‘io_service’ does not name a type; did you mean ‘CAsioService’? 621 | io_service::strand m_strand; // handle synchronisation in io_service thread pool | ^~~~~~~~~~ | CAsioService LibSocketAsio.cpp: In constructor ‘CAsioSocketImpl::CAsioSocketImpl(CLibSocket*)’: LibSocketAsio.cpp:103:17: error: class ‘CAsioSocketImpl’ does not have any field named ‘m_strand’ 103 | m_strand(s_io_service), | ^~~~~~~~ LibSocketAsio.cpp:103:26: error: ‘s_io_service’ was not declared in this scope 103 | m_strand(s_io_service), | ^~~~~~~~~~~~ LibSocketAsio.cpp: In member function ‘bool CAsioSocketImpl::Connect(const amuleIPV4Address&, bool)’: LibSocketAsio.cpp:161:33: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 161 | m_strand.wrap(boost::bind(& CAsioSocketImpl::HandleConnect, this, placeholders::error))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘uint32 CAsioSocketImpl::Write(const void*, uint32)’: LibSocketAsio.cpp:268:17: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 268 | m_strand.dispatch(boost::bind(& CAsioSocketImpl::DispatchWrite, this, nbytes)); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioSocketImpl::Close()’: LibSocketAsio.cpp:279:39: error: ‘s_io_service’ was not declared in this scope 279 | if (m_sync || s_io_service.stopped()) { | ^~~~~~~~~~~~ LibSocketAsio.cpp:282:33: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 282 | m_strand.dispatch(boost::bind(& CAsioSocketImpl::DispatchClose, this)); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioSocketImpl::Destroy()’: LibSocketAsio.cpp:297:31: error: ‘s_io_service’ was not declared in this scope 297 | if (m_sync || s_io_service.stopped()) { | ^~~~~~~~~~~~ LibSocketAsio.cpp:304:44: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 304 | m_timer.async_wait(m_strand.wrap(boost::bind(& CAsioSocketImpl::HandleDestroy, this))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioSocketImpl::DispatchBackgroundRead()’: LibSocketAsio.cpp:426:25: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 426 | m_strand.wrap(boost::bind(& CAsioSocketImpl::HandleRead, this, placeholders::error))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioSocketImpl::DispatchWrite(uint32)’: LibSocketAsio.cpp:432:25: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 432 | m_strand.wrap(boost::bind(& CAsioSocketImpl::HandleSend, this, placeholders::error, placeholders::bytes_transferred))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioSocketImpl::StartBackgroundRead()’: LibSocketAsio.cpp:541:17: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 541 | m_strand.dispatch(boost::bind(& CAsioSocketImpl::DispatchBackgroundRead, this)); | ^~~~~~~~ | srand LibSocketAsio.cpp: At global scope: LibSocketAsio.cpp:889:9: error: ‘io_service’ does not name a type; did you mean ‘CAsioService’? 889 | io_service::strand m_strand; // handle synchronisation in io_service thread pool | ^~~~~~~~~~ | CAsioService LibSocketAsio.cpp: In constructor ‘CAsioSocketServerImpl::CAsioSocketServerImpl(const amuleIPV4Address&, CLibSocketServer*)’: LibSocketAsio.cpp:782:37: error: ‘s_io_service’ was not declared in this scope 782 | : ip::tcp::acceptor(s_io_service), | ^~~~~~~~~~~~ LibSocketAsio.cpp:785:19: error: class ‘CAsioSocketServerImpl’ does not have any field named ‘m_strand’ 785 | m_strand(s_io_service) | ^~~~~~~~ x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I.. -DUSE_WX_EXTENSIONS -I/usr/lib64/wx/include/gtk3-unicode-3.2-gtk3 -I/usr/include/wx-3.2-gtk3 -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -DNDEBUG -DwxDEBUG_LEVEL=0 -W -Wall -Wshadow -Wundef -march=native -O2 -pipe -std=gnu++14 -c -o libmuleappcore_a-TerminationProcessAmuleweb.o `test -f 'TerminationProcessAmuleweb.cpp' || echo './'`TerminationProcessAmuleweb.cpp LibSocketAsio.cpp: In member function ‘void CAsioSocketServerImpl::StartAccept()’: LibSocketAsio.cpp:858:25: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 858 | m_strand.wrap(boost::bind(& CAsioSocketServerImpl::HandleAccept, this, placeholders::error))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioSocketServerImpl::HandleAccept(const boost::system::error_code&)’: LibSocketAsio.cpp:878:17: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 878 | m_strand.post(boost::bind(& CAsioSocketServerImpl::StartAccept, this)); | ^~~~~~~~ | srand LibSocketAsio.cpp: At global scope: LibSocketAsio.cpp:1165:9: error: ‘io_service’ does not name a type; did you mean ‘CAsioService’? 1165 | io_service::strand m_strand; // handle synchronisation in io_service thread pool | ^~~~~~~~~~ | CAsioService LibSocketAsio.cpp: In constructor ‘CAsioUDPSocketImpl::CAsioUDPSocketImpl(const amuleIPV4Address&, int, CLibUDPSocket*)’: LibSocketAsio.cpp:970:17: error: class ‘CAsioUDPSocketImpl’ does not have any field named ‘m_strand’ 970 | m_strand(s_io_service), | ^~~~~~~~ LibSocketAsio.cpp:970:26: error: ‘s_io_service’ was not declared in this scope 970 | m_strand(s_io_service), | ^~~~~~~~~~~~ LibSocketAsio.cpp: In member function ‘uint32 CAsioUDPSocketImpl::SendTo(const amuleIPV4Address&, const void*, uint32)’: LibSocketAsio.cpp:1024:17: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 1024 | m_strand.dispatch(boost::bind(& CAsioUDPSocketImpl::DispatchSendTo, this, recdata)); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioUDPSocketImpl::Close()’: LibSocketAsio.cpp:1035:21: error: ‘s_io_service’ was not declared in this scope 1035 | if (s_io_service.stopped()) { | ^~~~~~~~~~~~ LibSocketAsio.cpp:1038:25: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 1038 | m_strand.dispatch(boost::bind(& CAsioUDPSocketImpl::DispatchClose, this)); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioUDPSocketImpl::Destroy()’: LibSocketAsio.cpp:1046:21: error: ‘s_io_service’ was not declared in this scope 1046 | if (s_io_service.stopped()) { | ^~~~~~~~~~~~ LibSocketAsio.cpp:1053:44: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 1053 | m_timer.async_wait(m_strand.wrap(boost::bind(& CAsioUDPSocketImpl::HandleDestroy, this))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioUDPSocketImpl::DispatchSendTo(CUDPData*)’: LibSocketAsio.cpp:1083:25: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 1083 | m_strand.wrap(boost::bind(& CAsioUDPSocketImpl::HandleSendTo, this, placeholders::error, placeholders::bytes_transferred, recdata))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘void CAsioUDPSocketImpl::CreateSocket()’: LibSocketAsio.cpp:1145:56: error: ‘s_io_service’ was not declared in this scope 1145 | m_socket = new ip::udp::socket(s_io_service, endpoint); | ^~~~~~~~~~~~ LibSocketAsio.cpp: In member function ‘void CAsioUDPSocketImpl::StartBackgroundRead()’: LibSocketAsio.cpp:1158:25: error: ‘m_strand’ was not declared in this scope; did you mean ‘srand’? 1158 | m_strand.wrap(boost::bind(& CAsioUDPSocketImpl::HandleRead, this, placeholders::error, placeholders::bytes_transferred))); | ^~~~~~~~ | srand LibSocketAsio.cpp: In member function ‘virtual void* CAsioServiceThread::Entry()’: LibSocketAsio.cpp:1257:17: error: ‘io_service’ has not been declared 1257 | io_service::work worker(s_io_service); // keep io_service running | ^~~~~~~~~~ LibSocketAsio.cpp:1258:17: error: ‘s_io_service’ was not declared in this scope 1258 | s_io_service.run(); | ^~~~~~~~~~~~ LibSocketAsio.cpp: In member function ‘void CAsioService::Stop()’: LibSocketAsio.cpp:1287:9: error: ‘s_io_service’ was not declared in this scope 1287 | s_io_service.stop(); | ^~~~~~~~~~~~ LibSocketAsio.cpp: In member function ‘virtual bool amuleIPV4Address::Hostname(const wxString&)’: LibSocketAsio.cpp:1345:46: error: ‘from_string’ is not a member of ‘boost::asio::ip::address_v4’ 1345 | ip::address_v4 adr = ip::address_v4::from_string(sname, ec); | ^~~~~~~~~~~ LibSocketAsio.cpp:1354:31: error: ‘s_io_service’ was not declared in this scope 1354 | ip::tcp::resolver res(s_io_service); | ^~~~~~~~~~~~ LibSocketAsio.cpp:1356:28: error: ‘query’ is not a member of ‘boost::asio::ip::tcp::resolver’ {aka ‘boost::asio::ip::basic_resolver<boost::asio::ip::tcp>’} 1356 | ip::tcp::resolver::query query(ip::tcp::v4(), sname, ""); | ^~~~~ LibSocketAsio.cpp:1357:28: error: ‘iterator’ is not a member of ‘boost::asio::ip::tcp::resolver’ {aka ‘boost::asio::ip::basic_resolver<boost::asio::ip::tcp>’} 1357 | ip::tcp::resolver::iterator endpoint_iterator = res.resolve(query, ec2); | ^~~~~~~~ x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I.. -DUSE_WX_EXTENSIONS -I/usr/lib64/wx/include/gtk3-unicode-3.2-gtk3 -I/usr/include/wx-3.2-gtk3 -D_FILE_OFFSET_BITS=64 -DWXUSINGDLL -D__WXGTK__ -DwxUSE_GUI=0 -I./libs -I./include -DNDEBUG -DwxDEBUG_LEVEL=0 -W -Wall -Wshadow -Wundef -march=native -O2 -pipe -std=gnu++14 -c -o libmuleappcore_a-ThreadScheduler.o `test -f 'ThreadScheduler.cpp' || echo './'`ThreadScheduler.cpp LibSocketAsio.cpp:1362:13: error: ‘endpoint_iterator’ was not declared in this scope 1362 | if (endpoint_iterator == ip::tcp::resolver::iterator()) { | ^~~~~~~~~~~~~~~~~ LibSocketAsio.cpp:1362:53: error: ‘iterator’ is not a member of ‘boost::asio::ip::tcp::resolver’ {aka ‘boost::asio::ip::basic_resolver<boost::asio::ip::tcp>’} 1362 | if (endpoint_iterator == ip::tcp::resolver::iterator()) { | ^~~~~~~~ LibSocketAsio.cpp:1366:29: error: ‘endpoint_iterator’ was not declared in this scope 1366 | m_endpoint->address(endpoint_iterator->endpoint().address()); | ^~~~~~~~~~~~~~~~~
(In reply to Luigi 'Comio' Mantellini from comment #4) > PR Upstream > > https://github.com/amule-project/amule/pull/387 With some push, the PR has been approved on mainstream ;)
(In reply to Luigi 'Comio' Mantellini from comment #4) > PR Upstream > > https://github.com/amule-project/amule/pull/387 Thank you for the patch!
(In reply to Alexander Tsoy from comment #9) > (In reply to Luigi 'Comio' Mantellini from comment #4) > > PR Upstream > > > > https://github.com/amule-project/amule/pull/387 > Thank you for the patch! Alexander, any idea when the PR will be merged? This issue is blocking my usual Gentoo refresh...
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3dd043a7642c15916f1b2b7f18191b2d5cd7114a commit 3dd043a7642c15916f1b2b7f18191b2d5cd7114a Author: Hanno Böck <hanno@gentoo.org> AuthorDate: 2025-01-26 09:55:53 +0000 Commit: Hanno Böck <hanno@gentoo.org> CommitDate: 2025-01-26 09:55:53 +0000 net-p2p/amule: fix build w/ boost-1.87 Closes: https://bugs.gentoo.org/946504 Closes: https://github.com/gentoo/gentoo/pull/40178 Signed-off-by: Alexander Tsoy <alexander@tsoy.me> Signed-off-by: Hanno Böck <hanno@gentoo.org> net-p2p/amule/amule-2.3.3-r4.ebuild | 3 +- net-p2p/amule/files/amule-2.3.3-boost-1.87.patch | 146 +++++++++++++++++++++++ 2 files changed, 148 insertions(+), 1 deletion(-)