Eisenwave/voxel-io

Build Error on LInux Fedora gcc 11

arpu opened this issue · 3 comments

arpu commented

Hey,

on testing this vox implementation i hit this Problem on Linux

-- The C compiler identification is GNU 11.0.1
-- The CXX compiler identification is GNU 11.0.1
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
Building voxel-io RELEASE
-- Configuring done
-- Generating don
Scanning dependencies of target voxelio
[  1%] Building CXX object src/CMakeFiles/voxelio.dir/assert.cpp.o
/home/arpu/Work/githubsources/voxel-io/src/assert.cpp: In Funktion »void voxelio::defaultAssertHandler()«:
/home/arpu/Work/githubsources/voxel-io/src/assert.cpp:13:10: Fehler: »terminate« ist kein Element von »std«; meinten Sie »hermite«?
   13 |     std::terminate();
      |          ^~~~~~~~~
      |          hermite
/home/arpu/Work/githubsources/voxel-io/src/assert.cpp:14:1: Warnung: »noreturn«-Funktion kehrt zurück
   14 | }
      | ^
make[2]: *** [src/CMakeFiles/voxelio.dir/build.make:82: src/CMakeFiles/voxelio.dir/assert.cpp.o] Fehler 1
make[1]: *** [CMakeFiles/Makefile2:175: src/CMakeFiles/voxelio.dir/all] Fehler 2
make: *** [Makefile:103: all] Fehler 2
❯ LANG=en
❯ make
[  1%] Building CXX object src/CMakeFiles/voxelio.dir/assert.cpp.o
/home/arpu/Work/githubsources/voxel-io/src/assert.cpp: In function 'void voxelio::defaultAssertHandler()':
/home/arpu/Work/githubsources/voxel-io/src/assert.cpp:13:10: error: 'terminate' is not a member of 'std'; did you mean 'hermite'?
   13 |     std::terminate();
      |          ^~~~~~~~~
      |          hermite
/home/arpu/Work/githubsources/voxel-io/src/assert.cpp:14:1: warning: 'noreturn' function does return
   14 | }
      | ^
make[2]: *** [src/CMakeFiles/voxelio.dir/build.make:82: src/CMakeFiles/voxelio.dir/assert.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:175: src/CMakeFiles/voxelio.dir/all] Error 2
make: *** [Makefile:103: all] Error 2

I have added the missing include. This issue should be resolved now.

arpu commented

Hey,

thx a lot to looking at this!

looks like this is fixed but i get this now

/home/arpu/Work/githubsources/voxel-io/src/3rd_party/miniz_cpp.cpp: In Elementfunktion »void miniz_cpp::zip_file::append_comment()«:
/home/arpu/Work/githubsources/voxel-io/src/3rd_party/miniz_cpp.cpp:606:86: Fehler: »numeric_limits« ist kein Element von »std«
  606 |         auto comment_length = std::min(static_cast<uint16_t>(comment.length()), std::numeric_limits<uint16_t>::max());
      |                                                                                      ^~~~~~~~~~~~~~
/home/arpu/Work/githubsources/voxel-io/src/3rd_party/miniz_cpp.cpp:606:109: Fehler: expected primary-expression before »>« token
  606 |         auto comment_length = std::min(static_cast<uint16_t>(comment.length()), std::numeric_limits<uint16_t>::max());
      |                                                                                                             ^
/home/arpu/Work/githubsources/voxel-io/src/3rd_party/miniz_cpp.cpp:606:112: Fehler: »::max« wurde nicht deklariert; meinten Sie »std::max«?
  606 |         auto comment_length = std::min(static_cast<uint16_t>(comment.length()), std::numeric_limits<uint16_t>::max());
      |                                                                                                                ^~~
      |                                                                                                                std::max
In Datei, eingebunden von /usr/include/c++/11/functional:65,
                 von /home/arpu/Work/githubsources/voxel-io/include/voxelio/3rd_party/miniz_cpp.hpp:11,
                 von /home/arpu/Work/githubsources/voxel-io/src/3rd_party/miniz_cpp.cpp:1:
/usr/include/c++/11/bits/stl_algo.h:3467:5: Anmerkung: »std::max« ist hier deklariert
 3467 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
make[2]: *** [src/3rd_party/CMakeFiles/voxelio-3rd-party.dir/build.make:104: src/3rd_party/CMakeFiles/voxelio-3rd-party.dir/miniz_cpp.cpp.o] Fehler 1
make[1]: *** [CMakeFiles/Makefile2:203: src/3rd_party/CMakeFiles/voxelio-3rd-party.dir/all] Fehler 2
make: *** [Makefile:91: all] Fehler 2

zeuner commented

I saw similar errors, maybe this (#3) works for you?