LuaFormatter icon indicating copy to clipboard operation
LuaFormatter copied to clipboard

LuaFormatter fails to compile

Open s-taylor opened this issue 4 years ago • 1 comments

This is running ubuntu 20.04 on WSL (windows). Same error occurs whether installing via luarocks or compiling manually.

[ 89%] Building CXX object CMakeFiles/lua-format.dir/src/lua-format.cpp.o In file included from /home/staylor/projects/personal/LuaFormatter/src/lua-format.h:6:0, from /home/staylor/projects/personal/LuaFormatter/src/lua-format.cpp:1: /home/staylor/projects/personal/LuaFormatter/src/Config.h:12:15: fatal error: any: No such file or directory compilation terminated. make[2]: *** [CMakeFiles/lua-format.dir/build.make:76: CMakeFiles/lua-format.dir/src/lua-format.cpp.o] Error 1 make[1]: *** [CMakeFiles/Makefile2:90: CMakeFiles/lua-format.dir/all] Error 2 make: *** [Makefile:146: all] Error 2

s-taylor avatar Aug 25 '21 01:08 s-taylor

I'm seeing this too, though different error:

[ 93%] Building CXX object CMakeFiles/lua-format-test.dir/test/test.cpp.o
In file included from /usr/include/signal.h:328,
                 from /tmp/luarocks_luaformatter-scm-1-e1UnhK/LuaFormatter/third_party/Catch2/single_include/catch2/catch.hpp:7937,
                 from /tmp/luarocks_luaformatter-scm-1-e1UnhK/LuaFormatter/test/test.cpp:3:
/tmp/luarocks_luaformatter-scm-1-e1UnhK/LuaFormatter/third_party/Catch2/single_include/catch2/catch.hpp:10717:58: error: call to non-‘constexpr’ function ‘long int sysconf(int)’
10717 |     static constexpr std::size_t sigStackSize = 32768 >= MINSIGSTKSZ ? 32768 : MINSIGSTKSZ;
      |                                                          ^~~~~~~~~~~
In file included from /usr/include/x86_64-linux-gnu/bits/sigstksz.h:24,
                 from /usr/include/signal.h:328,
                 from /tmp/luarocks_luaformatter-scm-1-e1UnhK/LuaFormatter/third_party/Catch2/single_include/catch2/catch.hpp:7937,
                 from /tmp/luarocks_luaformatter-scm-1-e1UnhK/LuaFormatter/test/test.cpp:3:
/usr/include/unistd.h:640:17: note: ‘long int sysconf(int)’ declared here
  640 | extern long int sysconf (int __name) __THROW;
      |                 ^~~~~~~
In file included from /tmp/luarocks_luaformatter-scm-1-e1UnhK/LuaFormatter/test/test.cpp:3:
/tmp/luarocks_luaformatter-scm-1-e1UnhK/LuaFormatter/third_party/Catch2/single_include/catch2/catch.hpp:10776:45: error: size of array ‘altStackMem’ is not an integral constant-expression
10776 |     char FatalConditionHandler::altStackMem[sigStackSize] = {};
      |                                             ^~~~~~~~~~~~
gmake[2]: *** [CMakeFiles/lua-format-test.dir/build.make:173: CMakeFiles/lua-format-test.dir/test/test.cpp.o] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:102: CMakeFiles/lua-format-test.dir/all] Error 2
gmake: *** [Makefile:160: all] Error 2

Error: Build error: Failed building.

This is on Ubuntu 21.10.

jc00ke avatar Dec 27 '21 03:12 jc00ke