OK, This is interesting. I applied your changes and it builds fine. With qt creator it still sends a message that it found lua53. But the compiler output for every file built showed a DLUA 0x050100. So it looks like 5.1 was used. Also, the Spice test passed in config tests. On Leap 42.3, which is what I just used, I have lua 5.2 and 5.1 installed. I uninstalled 5.3. I only had develop files for 5.1 though. Not sure how that message echoed lua53 though.
I'm gonna switch to Tumbleweed and check what happens there. That has develop files for lua 5.1 and 5.3.
cartrite
Added after 1 hour 41 minutes:Ok. Tumbleweed did not fair so well with the changes. At first it stopped compiling on one of the files you changed spicerotations.cpp. Here is the terminal output.
Code: Select all
/usr/include/c++/8/bits/range_access.h:68:5: note: candidate: ‘template<class _Container> decltype (__cont.end()) std::end(_Container&)’
end(_Container& __cont) -> decltype(__cont.end())
^~~
/usr/include/c++/8/bits/range_access.h:68:5: note: template argument deduction/substitution failed:
/usr/include/c++/8/bits/range_access.h: In substitution of ‘template<class _Container> decltype (__cont.end()) std::end(_Container&) [with _Container = const std::__cxx11::list<std::__cxx11::basic_string<char> >*]’:
../src/celephem/scriptrotation.cpp:100:35: required from here
/usr/include/c++/8/bits/range_access.h:68:48: error: request for member ‘end’ in ‘__cont’, which is of pointer type ‘const std::__cxx11::list<std::__cxx11::basic_string<char> >*’ (maybe you meant to use ‘->’ ?)
end(_Container& __cont) -> decltype(__cont.end())
~~~~~~~^~~
/usr/include/c++/8/bits/range_access.h:78:5: note: candidate: ‘template<class _Container> decltype (__cont.end()) std::end(const _Container&)’
end(const _Container& __cont) -> decltype(__cont.end())
^~~
/usr/include/c++/8/bits/range_access.h:78:5: note: template argument deduction/substitution failed:
/usr/include/c++/8/bits/range_access.h: In substitution of ‘template<class _Container> decltype (__cont.end()) std::end(const _Container&) [with _Container = const std::__cxx11::list<std::__cxx11::basic_string<char> >*]’:
../src/celephem/scriptrotation.cpp:100:35: required from here
/usr/include/c++/8/bits/range_access.h:78:54: error: request for member ‘end’ in ‘__cont’, which is of pointer type ‘const std::__cxx11::list<std::__cxx11::basic_string<char> >* const’ (maybe you meant to use ‘->’ ?)
end(const _Container& __cont) -> decltype(__cont.end())
~~~~~~~^~~
/usr/include/c++/8/bits/range_access.h:97:5: note: candidate: ‘template<class _Tp, long unsigned int _Nm> _Tp* std::end(_Tp (&)[_Nm])’
end(_Tp (&__arr)[_Nm])
^~~
/usr/include/c++/8/bits/range_access.h:97:5: note: template argument deduction/substitution failed:
../src/celephem/scriptrotation.cpp:100:35: note: mismatched types ‘_Tp [_Nm]’ and ‘const std::__cxx11::list<std::__cxx11::basic_string<char> >*’
for (const auto& kernel : requiredKernels)
^~~~~~~~~~~~~~~
make: *** [Makefile:6624: obj/scriptrotation.o] Error 1
make: *** Waiting for unfinished jobs....
I tried to run it again with the original file and it still exited with an error. Dont think it was the same error but.....
When I removed spice from usr/local it did start failing the spice test again but the compilation stopped for not finding the header file used in main.cpp. Anyhow I tried the original files from master and this is the output I was getting with using lua5.3.
Code: Select all
g++ -c -pipe -std=c++11 -O2 -Wall -W -D_REENTRANT -fPIC -DGIT_COMMIT=\"0bd0b4e1\" -DGLEW_STATIC -DCELX -DHAVE_BYTESWAP_H -DEIGEN_NO_DEBUG -DNDEBUG -DNO_DEBUG -DTHEORA -DVIDEO_SYNC -DCONFIG_DATA_DIR=\"/usr/local/share/Celestia_QT\" -DSPLASH_DIR=\"/usr/local/share/Celestia_QT/splash/\" -DLOCALEDIR=\"/usr/local/share/locale\" -DQT_NO_DEBUG -DQT_OPENGL_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_XML_LIB -DQT_CORE_LIB -I../../Celestia -I. -I../thirdparty/glew/include -I../thirdparty/fmt/include -I../../Celestia -I../src -I../thirdparty/Eigen -isystem /usr/include/libdrm -isystem /usr/include/lua5.3 -isystem /usr/include/libpng16 -isystem /usr/include/qt5 -isystem /usr/include/qt5/QtOpenGL -isystem /usr/include/qt5/QtWidgets -isystem /usr/include/qt5/QtGui -isystem /usr/include/qt5/QtXml -isystem /usr/include/qt5/QtCore -Imoc -isystem /usr/include/libdrm -I. -I/usr/lib64/qt5/mkspecs/linux-g++ -o obj/celx.o ../src/celestia/celx.cpp
../src/celestia/celx.cpp: In constructor ‘LuaState::LuaState()’:
../src/celestia/celx.cpp:467:13: error: ‘lua_open’ was not declared in this scope
state = lua_open();
^~~~~~~~
../src/celestia/celx.cpp:467:13: note: suggested alternative: ‘lua_len’
state = lua_open();
^~~~~~~~
lua_len
../src/celestia/celx.cpp: In function ‘int resumeLuaThread(lua_State*, lua_State*, int)’:
../src/celestia/celx.cpp:612:29: error: invalid conversion from ‘int’ to ‘lua_State*’ [-fpermissive]
status = lua_resume(co, narg);
^~~~
../src/celestia/celx.cpp:612:33: error: too few arguments to function ‘int lua_resume(lua_State*, lua_State*, int)’
status = lua_resume(co, narg);
^
In file included from ../src/celestia/celx.h:26,
from ../src/celestia/celestiacore.h:30,
from ../src/celestia/url.h:22,
from ../src/celestia/celx.cpp:29:
/usr/include/lua5.3/lua.h:291:15: note: declared here
LUA_API int (lua_resume) (lua_State *L, lua_State *from, int narg);
^~~~~~~~~~
../src/celestia/celx.cpp: In member function ‘bool LuaState::charEntered(const char*)’:
../src/celestia/celx.cpp:686:13: error: ‘lua_iolibopen’ was not declared in this scope
lua_iolibopen(costate);
^~~~~~~~~~~~~
../src/celestia/celx.cpp:686:13: note: suggested alternative: ‘lua_len’
lua_iolibopen(costate);
^~~~~~~~~~~~~
lua_len
../src/celestia/celx.cpp: In member function ‘int LuaState::loadScript(std::istream&, const string&)’:
../src/celestia/celx.cpp:919:76: error: too few arguments to function ‘int lua_load(lua_State*, lua_Reader, void*, const char*, const char*)’
int status = lua_load(state, readStreamChunk, &info, streamname.c_str());
^
In file included from ../src/celestia/celx.h:26,
from ../src/celestia/celestiacore.h:30,
from ../src/celestia/url.h:22,
from ../src/celestia/celx.cpp:29:
/usr/include/lua5.3/lua.h:280:16: note: declared here
LUA_API int (lua_load) (lua_State *L, lua_Reader reader, void *dt,
^~~~~~~~
../src/celestia/celx.cpp: In member function ‘void LuaState::requestIO()’:
../src/celestia/celx.cpp:1116:13: error: ‘lua_iolibopen’ was not declared in this scope
lua_iolibopen(costate);
^~~~~~~~~~~~~
../src/celestia/celx.cpp:1116:13: note: suggested alternative: ‘lua_len’
lua_iolibopen(costate);
^~~~~~~~~~~~~
lua_len
../src/celestia/celx.cpp: In member function ‘bool LuaState::init(CelestiaCore*)’:
../src/celestia/celx.cpp:1342:5: error: ‘lua_baselibopen’ was not declared in this scope
lua_baselibopen(state);
^~~~~~~~~~~~~~~
../src/celestia/celx.cpp:1342:5: note: suggested alternative: ‘lua_rawlen’
lua_baselibopen(state);
^~~~~~~~~~~~~~~
lua_rawlen
../src/celestia/celx.cpp:1343:5: error: ‘lua_mathlibopen’ was not declared in this scope
lua_mathlibopen(state);
^~~~~~~~~~~~~~~
../src/celestia/celx.cpp:1343:5: note: suggested alternative: ‘lua_rawlen’
lua_mathlibopen(state);
^~~~~~~~~~~~~~~
lua_rawlen
../src/celestia/celx.cpp:1344:5: error: ‘lua_tablibopen’ was not declared in this scope
lua_tablibopen(state);
^~~~~~~~~~~~~~
../src/celestia/celx.cpp:1344:5: note: suggested alternative: ‘lua_rawlen’
lua_tablibopen(state);
^~~~~~~~~~~~~~
lua_rawlen
../src/celestia/celx.cpp:1345:5: error: ‘lua_strlibopen’ was not declared in this scope
lua_strlibopen(state);
^~~~~~~~~~~~~~
../src/celestia/celx.cpp:1345:5: note: suggested alternative: ‘lua_version’
lua_strlibopen(state);
^~~~~~~~~~~~~~
lua_version
../src/celestia/celx.cpp: In member function ‘void LuaState::setLuaPath(const string&)’:
../src/celestia/celx.cpp:1410:25: error: ‘LUA_GLOBALSINDEX’ was not declared in this scope
lua_settable(state, LUA_GLOBALSINDEX);
^~~~~~~~~~~~~~~~
../src/celestia/celx.cpp:1410:25: note: suggested alternative: ‘LUA_HOOKLINE’
lua_settable(state, LUA_GLOBALSINDEX);
^~~~~~~~~~~~~~~~
LUA_HOOKLINE
Tumbleweed does use a newer compiler gcc8.2. So........ More strict It did build with lua5.1. But now I don't think it had spice support.
cartrite
Added after 1 hour 46 minutes:Sorry, I screwed up. There is another file called scriptrotation in the celephem folder. I populated a file with the fix for spicerotation and called it scriptrotation.
Unpredictable results.
Anyhow I applied the fixes with the right file names and it built fine. What surprised me was it used lua 5.3 and worked this time. So these fixes seem good on 2 of openSUSE's systems. I built it first on a terminal but just to see how qtcreator would work I built it again. It worked. I wanted to add a screenshot. Notice the bottom left and right. The number of issues and warnings
Sorry the warnings on the right had disappeared. There were over 3000. There are 33130 issues though. gcc 8.2.
Most were about issuses with Eigen. On Leap 42.3 which uses a gcc 4.8 compiler there were about 15 warnings. Maybe more but it had 15 through most of the run.
So it looks like these fixes work on this boat.
cartrite
Added after 4 minutes 29 seconds:I'll need to brush up on Spice operations, put this though some trials to see if everything is working right.
Have a good one .
cartrite
VivoBook_ASUSLaptop X712JA_S712JA Intel(R) UHD Graphics 8gb ram. Intel(R) Core(TM) i5-1035G1 CPU @ 1.00GHz, 1190 Mhz, 4 Core(s), 8 Logical Processor(s) 8 GB ram. Running on Windows 11 and OpenSuse 15.4