Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compile error in 5.5.0-bbfae0c and above #11708

Closed
An0n3m0us opened this issue Oct 19, 2021 · 6 comments · Fixed by #11778
Closed

Compile error in 5.5.0-bbfae0c and above #11708

An0n3m0us opened this issue Oct 19, 2021 · 6 comments · Fixed by #11778
Labels
Bug Issues that were confirmed to be a bug

Comments

@An0n3m0us
Copy link
Contributor

Minetest version
5.5.0-c82ec8b (affects 5.5.0-bbfae0c and above)
OS / Hardware

Operating system: Ubuntu 16.04
CPU: i7-3740QM
GCC: Ubuntu 5.4.0-6ubuntu1~16.04.12

Summary

Compiling Minetest crashes with the following log details:

cmake output:
cmake . -DRUN_IN_PLACE=FALSE -DBUILD_SERVER=TRUE

-- *** Will build version 5.5.0-dev ***
-- Using user-provided IrrlichtMt at subdirectory 'lib/irrlichtmt'
-- *** Building IrrlichtMt 1.9.0 ***
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.8") 
-- Found JPEG: /usr/lib/x86_64-linux-gnu/libjpeg.so  
-- Found PNG: /usr/lib/x86_64-linux-gnu/libpng.so (found version "1.2.54") 
-- Looking for _IRR_COMPILE_WITH_OGLES1_
-- Looking for _IRR_COMPILE_WITH_OGLES1_ - not found
-- Looking for _IRR_COMPILE_WITH_OGLES2_
-- Looking for _IRR_COMPILE_WITH_OGLES2_ - not found
-- Looking for _IRR_COMPILE_WITH_OPENGL_
-- Looking for _IRR_COMPILE_WITH_OPENGL_ - found
-- Found OpenGL: /usr/lib/x86_64-linux-gnu/libGL.so  
-- Looking for _IRR_LINUX_X11_XINPUT2_
-- Looking for _IRR_LINUX_X11_XINPUT2_ - not found
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Looking for IceConnectionNumber in ICE
-- Looking for IceConnectionNumber in ICE - found
-- Found X11: /usr/lib/x86_64-linux-gnu/libX11.so
You have called ADD_LIBRARY for library IrrlichtMt without any source files. This typically indicates a problem with your CMakeLists.txt file
-- Using GMP provided by system.
-- Found GMP: /usr/lib/x86_64-linux-gnu/libgmp.so  
-- Using JsonCpp provided by system.
-- Found Json: /usr/lib/x86_64-linux-gnu/libjsoncpp.so  
-- Found LuaJIT: /usr/lib/x86_64-linux-gnu/libluajit-5.1.so  
-- Using LuaJIT provided by system.
-- Found CURL: /usr/lib/x86_64-linux-gnu/libcurl.so  
-- cURL support enabled.
-- Found GettextLib: /usr/include  
-- GetText enabled; locales found: ms;ro;th;zh_TW;jbo;el;be;nn;sv;eu;ar;es;pt;zh_CN;fr;kn;pt_BR;cs;ru;mr;it;he;tt;sr_Latn;kk;lv;tr;gl;gd;sl;fi;ko;ky;id;ca;et;ms_Arab;uk;hu;sw;vi;hi;sk;sr_Cyrl;da;ja;de;dv;fil;eo;nb;pl;lt;bg;nl
-- Found OpenAL: /usr/lib/x86_64-linux-gnu/libopenal.so  
-- Found Vorbis: /usr/include  
-- Sound enabled.
-- Found Freetype: /usr/lib/x86_64-linux-gnu/libfreetype.so  
-- Freetype enabled.
-- Looking for cbreak in /usr/lib/x86_64-linux-gnu/libncursesw.so
-- Looking for cbreak in /usr/lib/x86_64-linux-gnu/libncursesw.so - found
-- Found Ncursesw: /usr/lib/x86_64-linux-gnu/libncursesw.so  
-- ncurses console enabled.
-- PostgreSQL not found!
-- LevelDB backend enabled.
-- Redis not found!
-- Found SQLite3: /usr/lib/x86_64-linux-gnu/libsqlite3.so  
-- Prometheus client disabled.
-- SpatialIndex not found!
-- Looking for ZSTD_initCStream
-- Looking for ZSTD_initCStream - found
-- Found Zstd: /usr/lib/x86_64-linux-gnu/libzstd.so  
-- Looking for clock_gettime in rt
-- Looking for clock_gettime in rt - found
-- Looking for include file endian.h
-- Looking for include file endian.h - found
-- Locale blacklist applied; Locales used: ms;ro;zh_TW;jbo;el;be;nn;sv;eu;es;pt;zh_CN;fr;pt_BR;cs;ru;mr;it;tt;sr_Latn;kk;lv;tr;gl;gd;sl;fi;ko;ky;id;ca;et;uk;hu;sw;vi;sk;sr_Cyrl;da;ja;de;fil;eo;nb;pl;lt;bg;nl
-- Performing Test IS_AARCH64
-- Performing Test IS_AARCH64 - Failed
-- Found Doxygen: /usr/bin/doxygen (found version "1.8.11") 
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/minetest

make output:

[ 73%] Building CXX object src/CMakeFiles/minetestserver.dir/server.cpp.o
In file included from /usr/include/x86_64-linux-gnu/c++/5/bits/c++allocator.h:33:0,
                 from /usr/include/c++/5/bits/allocator.h:46,
                 from /usr/include/c++/5/list:61,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/ext/new_allocator.h: In instantiation of 'void __gnu_cxx::new_allocator<_Tp>::construct(_Up*, _Args&& ...) [with _Up = std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> >; _Args = {unsigned int&, SingleMediaDownloader*&}; _Tp = std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> >]':
/usr/include/c++/5/bits/alloc_traits.h:530:4:   required from 'static void std::allocator_traits<std::allocator<_Tp1> >::construct(std::allocator_traits<std::allocator<_Tp1> >::allocator_type&, _Up*, _Args&& ...) [with _Up = std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> >; _Args = {unsigned int&, SingleMediaDownloader*&}; _Tp = std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> >; std::allocator_traits<std::allocator<_Tp1> >::allocator_type = std::allocator<std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> > >]'
/usr/include/c++/5/bits/vector.tcc:96:30:   required from 'void std::vector<_Tp, _Alloc>::emplace_back(_Args&& ...) [with _Args = {unsigned int&, SingleMediaDownloader*&}; _Tp = std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> >; _Alloc = std::allocator<std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> > >]'
/tmp/minetest/src/network/clientpackethandler.cpp:1563:58:   required from here
/usr/include/c++/5/ext/new_allocator.h:120:4: error: no matching function for call to 'std::pair<unsigned int, std::unique_ptr<SingleMediaDownloader> >::pair(unsigned int&, SingleMediaDownloader*&)'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
    ^
In file included from /usr/include/c++/5/bits/stl_algobase.h:64:0,
                 from /usr/include/c++/5/list:60,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/bits/stl_pair.h:206:9: note: candidate: template<class ... _Args1, long unsigned int ..._Indexes1, class ... _Args2, long unsigned int ..._Indexes2> std::pair<_T1, _T2>::pair(std::tuple<_Args1 ...>&, std::tuple<_Args2 ...>&, std::_Index_tuple<_Indexes1 ...>, std::_Index_tuple<_Indexes2 ...>)
         pair(tuple<_Args1...>&, tuple<_Args2...>&,
         ^
/usr/include/c++/5/bits/stl_pair.h:206:9: note:   template argument deduction/substitution failed:
In file included from /usr/include/x86_64-linux-gnu/c++/5/bits/c++allocator.h:33:0,
                 from /usr/include/c++/5/bits/allocator.h:46,
                 from /usr/include/c++/5/list:61,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/ext/new_allocator.h:120:4: note:   mismatched types 'std::tuple<_Args1 ...>' and 'unsigned int'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
    ^
In file included from /usr/include/c++/5/bits/stl_algobase.h:64:0,
                 from /usr/include/c++/5/list:60,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/bits/stl_pair.h:155:9: note: candidate: template<class ... _Args1, class ... _Args2> std::pair<_T1, _T2>::pair(std::piecewise_construct_t, std::tuple<_Args1 ...>, std::tuple<_Args2 ...>)
         pair(piecewise_construct_t, tuple<_Args1...>, tuple<_Args2...>);
         ^
/usr/include/c++/5/bits/stl_pair.h:155:9: note:   template argument deduction/substitution failed:
In file included from /usr/include/x86_64-linux-gnu/c++/5/bits/c++allocator.h:33:0,
                 from /usr/include/c++/5/bits/allocator.h:46,
                 from /usr/include/c++/5/list:61,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/ext/new_allocator.h:120:4: note:   cannot convert 'std::forward<unsigned int&>((* & __args#0))' (type 'unsigned int') to type 'std::piecewise_construct_t'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
    ^
In file included from /usr/include/c++/5/bits/stl_algobase.h:64:0,
                 from /usr/include/c++/5/list:60,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/bits/stl_pair.h:150:12: note: candidate: template<class _U1, class _U2, class> constexpr std::pair<_T1, _T2>::pair(std::pair<_U1, _U2>&&)
  constexpr pair(pair<_U1, _U2>&& __p)
            ^
/usr/include/c++/5/bits/stl_pair.h:150:12: note:   template argument deduction/substitution failed:
In file included from /usr/include/x86_64-linux-gnu/c++/5/bits/c++allocator.h:33:0,
                 from /usr/include/c++/5/bits/allocator.h:46,
                 from /usr/include/c++/5/list:61,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/ext/new_allocator.h:120:4: note:   mismatched types 'std::pair<_T1, _T2>' and 'unsigned int'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
    ^
In file included from /usr/include/c++/5/bits/stl_algobase.h:64:0,
                 from /usr/include/c++/5/list:60,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/bits/stl_pair.h:144:12: note: candidate: template<class _U1, class _U2, class> constexpr std::pair<_T1, _T2>::pair(_U1&&, _U2&&)
  constexpr pair(_U1&& __x, _U2&& __y)
            ^
/usr/include/c++/5/bits/stl_pair.h:144:12: note:   template argument deduction/substitution failed:
/usr/include/c++/5/bits/stl_pair.h:141:38: error: no type named 'type' in 'struct std::enable_if<false, void>'
       template<class _U1, class _U2, class = typename
                                      ^
/usr/include/c++/5/bits/stl_pair.h:138:12: note: candidate: template<class _U2, class> constexpr std::pair<_T1, _T2>::pair(const _T1&, _U2&&)
  constexpr pair(const _T1& __x, _U2&& __y)
            ^
/usr/include/c++/5/bits/stl_pair.h:138:12: note:   template argument deduction/substitution failed:
/usr/include/c++/5/bits/stl_pair.h:136:27: error: no type named 'type' in 'struct std::enable_if<false, void>'
       template<class _U2, class = typename
                           ^
/usr/include/c++/5/bits/stl_pair.h:133:12: note: candidate: template<class _U1, class> constexpr std::pair<_T1, _T2>::pair(_U1&&, const _T2&)
  constexpr pair(_U1&& __x, const _T2& __y)
            ^
/usr/include/c++/5/bits/stl_pair.h:133:12: note:   template argument deduction/substitution failed:
In file included from /usr/include/x86_64-linux-gnu/c++/5/bits/c++allocator.h:33:0,
                 from /usr/include/c++/5/bits/allocator.h:46,
                 from /usr/include/c++/5/list:61,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/ext/new_allocator.h:120:4: note:   cannot convert 'std::forward<SingleMediaDownloader*&>((* & __args#1))' (type 'SingleMediaDownloader*') to type 'const std::unique_ptr<SingleMediaDownloader>&'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
    ^
In file included from /usr/include/c++/5/bits/stl_algobase.h:64:0,
                 from /usr/include/c++/5/list:60,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/bits/stl_pair.h:128:17: note: candidate: constexpr std::pair<_T1, _T2>::pair(std::pair<_T1, _T2>&&) [with _T1 = unsigned int; _T2 = std::unique_ptr<SingleMediaDownloader>]
       constexpr pair(pair&&) = default;
                 ^
/usr/include/c++/5/bits/stl_pair.h:128:17: note:   candidate expects 1 argument, 2 provided
/usr/include/c++/5/bits/stl_pair.h:124:12: note: candidate: template<class _U1, class _U2, class> constexpr std::pair<_T1, _T2>::pair(const std::pair<_U1, _U2>&)
  constexpr pair(const pair<_U1, _U2>& __p)
            ^
/usr/include/c++/5/bits/stl_pair.h:124:12: note:   template argument deduction/substitution failed:
In file included from /usr/include/x86_64-linux-gnu/c++/5/bits/c++allocator.h:33:0,
                 from /usr/include/c++/5/bits/allocator.h:46,
                 from /usr/include/c++/5/list:61,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/ext/new_allocator.h:120:4: note:   mismatched types 'const std::pair<_T1, _T2>' and 'unsigned int'
  { ::new((void *)__p) _Up(std::forward<_Args>(__args)...); }
    ^
In file included from /usr/include/c++/5/bits/stl_algobase.h:64:0,
                 from /usr/include/c++/5/list:60,
                 from /tmp/minetest/src/environment.h:32,
                 from /tmp/minetest/src/client/clientenvironment.h:22,
                 from /tmp/minetest/src/client/client.h:22,
                 from /tmp/minetest/src/network/clientpackethandler.cpp:20:
/usr/include/c++/5/bits/stl_pair.h:112:26: note: candidate: constexpr std::pair<_T1, _T2>::pair(const _T1&, const _T2&) [with _T1 = unsigned int; _T2 = std::unique_ptr<SingleMediaDownloader>]
       _GLIBCXX_CONSTEXPR pair(const _T1& __a, const _T2& __b)
                          ^
/usr/include/c++/5/bits/stl_pair.h:112:26: note:   no known conversion for argument 2 from 'SingleMediaDownloader*' to 'const std::unique_ptr<SingleMediaDownloader>&'
/usr/include/c++/5/bits/stl_pair.h:108:26: note: candidate: constexpr std::pair<_T1, _T2>::pair() [with _T1 = unsigned int; _T2 = std::unique_ptr<SingleMediaDownloader>]
       _GLIBCXX_CONSTEXPR pair()
                          ^
/usr/include/c++/5/bits/stl_pair.h:108:26: note:   candidate expects 0 arguments, 2 provided
[ 73%] Building CXX object src/CMakeFiles/minetest.dir/network/serverpackethandler.cpp.o
[ 73%] Building CXX object src/CMakeFiles/minetest.dir/network/socket.cpp.o
src/CMakeFiles/minetest.dir/build.make:2558: recipe for target 'src/CMakeFiles/minetest.dir/network/clientpackethandler.cpp.o' failed
make[2]: *** [src/CMakeFiles/minetest.dir/network/clientpackethandler.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[ 73%] Building CXX object src/CMakeFiles/minetestserver.dir/serverenvironment.cpp.o
[ 73%] Building CXX object src/CMakeFiles/minetestserver.dir/serverlist.cpp.o
[ 73%] Building CXX object src/CMakeFiles/minetestserver.dir/settings.cpp.o
[ 73%] Building CXX object src/CMakeFiles/minetestserver.dir/staticobject.cpp.o
[ 73%] Building CXX object src/CMakeFiles/minetestserver.dir/terminal_chat_console.cpp.o
[ 73%] Building CXX object src/CMakeFiles/minetestserver.dir/texture_override.cpp.o
[ 74%] Building CXX object src/CMakeFiles/minetestserver.dir/tileanimation.cpp.o
[ 74%] Building CXX object src/CMakeFiles/minetestserver.dir/tool.cpp.o
[ 74%] Building CXX object src/CMakeFiles/minetestserver.dir/translation.cpp.o
[ 74%] Building CXX object src/CMakeFiles/minetestserver.dir/version.cpp.o
[ 74%] Building CXX object src/CMakeFiles/minetestserver.dir/voxel.cpp.o
CMakeFiles/Makefile2:472: recipe for target 'src/CMakeFiles/minetest.dir/all' failed
make[1]: *** [src/CMakeFiles/minetest.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 74%] Building CXX object src/CMakeFiles/minetestserver.dir/voxelalgorithms.cpp.o
[ 74%] Linking CXX executable ../bin/minetestserver
[ 74%] Built target minetestserver
Makefile:149: recipe for target 'all' failed
make: *** [all] Error 2
Steps to reproduce
  1. Compile Minetest on my old system :P
@An0n3m0us An0n3m0us added the Unconfirmed bug Bug report that has not been confirmed to exist/be reproducible label Oct 19, 2021
@sfan5
Copy link
Member

sfan5 commented Oct 19, 2021

Unless this also happens on other relevant platforms (e.g. a previous C++ related error also affected macOS) I'm inclined to say we just don't support Ubuntu 16.04 (or rather: gcc 5) anymore.

@sfan5 sfan5 added Bug Issues that were confirmed to be a bug and removed Unconfirmed bug Bug report that has not been confirmed to exist/be reproducible labels Oct 19, 2021
@An0n3m0us
Copy link
Contributor Author

Updated GCC to Ubuntu 6.5.0-2ubuntu1~16.04; same error.

@An0n3m0us
Copy link
Contributor Author

Also tested on Ubuntu 7.5.0-3ubuntu1~16.04 yet it still does not work, so I am not sure if this is really an issue with GCC.

@mckaygerhard
Copy link

umm i tried to compile in local instalation of centos and confirmed this but in debian 9 and centos.. may have relation with #11708

@sfan5
Copy link
Member

sfan5 commented Dec 11, 2021

This does not affect Debian 9, we have CI builds running successfully: https://gitlab.com/minetest/minetest/-/jobs/1871388589

@mckaygerhard
Copy link

mckaygerhard commented Dec 13, 2021

This does not affect Debian 9, we have CI builds running successfully: https://gitlab.com/minetest/minetest/-/jobs/1871388589

@sfan5 yes i was pointed that in the issue #11847 only centos and some older versions of feladora raised those problems

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Issues that were confirmed to be a bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants