arobenko / embxx

embxx - Embedded C++ Library
GNU General Public License v3.0
261 stars 34 forks source link

Can't build embxx with msys2 g++-7.3.0 #15

Open slyshykO opened 6 years ago

slyshykO commented 6 years ago

Errors: FAILED: module/io/test/CMakeFiles/io.WriteQueueTest.dir/WriteQueueTestRunner.cpp.obj D:\bin\msys64\mingw32\bin\g++.exe -I../../ -I../../external/cxxtest -isystem D:/bin/msys64/mingw32/include -Wall -Wextra -Werror -Wcast-align -Wcast-qual -Wmissing-include-dirs -Wlogical-op -Wstrict-null-sentinel -Wredundant-decls -Wno-unknown-pragmas -Wundef -Wunused -Wshadow -fdiagnostics-show-option -Woverloaded-virtual -Wno-unused-local-typedefs -Wctor-dtor-privacy -Wnoexcept -O3 -DNDEBUG -std=c++11 -MD -MT module/io/test/CMakeFiles/io.WriteQueueTest.dir/WriteQueueTestRunner.cpp.obj -MF module\io\test\CMakeFiles\io.WriteQueueTest.dir\WriteQueueTestRunner.cpp.obj.d -o module/io/test/CMakeFiles/io.WriteQueueTest.dir/WriteQueueTestRunner.cpp.obj -c module/io/test/WriteQueueTestRunner.cpp In file included from D:\projects\cpplibs\embxx\module\io\test\WriteQueue.th:21:0, from module/io/test/WriteQueueTestRunner.cpp:23: ../../embxx/io/WriteQueue.h: In member function 'void embxx::io::WriteQueue<TDriver, TSize, THandler>::cancelAllWrites()': ../../embxx/io/WriteQueue.h:308:16: error: return-statement with a value, in function returning 'void' [-fpermissive] return false; ^~~~~

FAILED: module/util/test/CMakeFiles/util.AllocatorsTest.dir/AllocatorsTestRunner.cpp.obj D:\bin\msys64\mingw32\bin\g++.exe -I../../ -I../../external/cxxtest -isystem D:/bin/msys64/mingw32/include -Wall -Wextra -Werror -Wcast-align -Wcast-qual -Wmissing-include-dirs -Wlogical-op -Wstrict-null-sentinel -Wredundant-decls -Wno-unknown-pragmas -Wundef -Wunused -Wshadow -fdiagnostics-show-option -Woverloaded-virtual -Wno-unused-local-typedefs -Wctor-dtor-privacy -Wnoexcept -O3 -DNDEBUG -std=c++11 -MD -MT module/util/test/CMakeFiles/util.AllocatorsTest.dir/AllocatorsTestRunner.cpp.obj -MF module\util\test\CMakeFiles\util.AllocatorsTest.dir\AllocatorsTestRunner.cpp.obj.d -o module/util/test/CMakeFiles/util.AllocatorsTest.dir/AllocatorsTestRunner.cpp.obj -c module/util/test/AllocatorsTestRunner.cpp In file included from D:\projects\cpplibs\embxx\module\util\test\Allocators.th:18:0, from module/util/test/AllocatorsTestRunner.cpp:23: ../../embxx/util/Allocators.h: In member function 'decltype (embxx::util::SpecificInPlaceAllocator::Allocator().alloc((forward)(args)...)) embxx::util::SpecificInPlaceAllocator::alloc(TArgs&& ...)': ../../embxx/util/Allocators.h:283:37: error: expected primary-expression before '>' token return allocator.alloc(std::forward(args)...); ^ ../../embxx/util/Allocators.h:283:67: error: expected binary operator before ')' token return allocator.alloc(std::forward(args)...); ^

slyshykO commented 6 years ago

Maybe that is not all issues. It was shown before build stopped.

arobenko commented 6 years ago

I just pushed a fix to "hotfixes" branch. Please try it and let me know whether it works for you.

slyshykO commented 6 years ago

Sorry, but still not work. Error in Allocators.h remains. Added few new errors: D:\projects\cpplibs\embxx\module\util\test\EventLoop.th:250:18: error: but 'EventLoopTestSuite::test5()::<lambda()>' does not throw; perhaps it should be declared 'noexcept' [-Werror=noexcept] [&ready]() ^

If it required I can send full build log.

slyshykO commented 6 years ago

Tested under Ubuntu 16.04:

arobenko commented 6 years ago

Sorry, I haven't really touched this project for 4-5 years and I don't know when I will come around to test latest compilers and fix all the problems. If you wish you can try to fix them yourself and submit a pull request.

slyshykO commented 6 years ago

Ok, I'll try.