I am getting a KStars build error on my ODroid N2 running on Ubuntu 18.04. As the upgrade path to 20.04 doesn't seem to work, I would appreciate knowing if there is a solution before installing 20.04 from scratch. The build works fine on my ODroid running 20.04.
Thanks for any help.
Here is the KStars build error message:
[4%] Building CXX object kstars/CMakeFiles/KStarsLib.dir/ekos/ekoslive/message.cpp.o
/home/observatoire/Projects/kstars/kstars/ekos/ekoslive/message.cpp: In member function 'void EkosLive::Message::processOptionsCommands(const QString&, const QJsonObject&)':
/home/observatoire/Projects/kstars/kstars/ekos/ekoslive/message.cpp:1315:51: error: no match for 'operator[]' (operand types are 'const QJsonValue' and 'const char [5]')
Options::self()->setProperty(oneOption["name"].toString().toLatin1(), oneOption["value"].toVariant());
^
/home/observatoire/Projects/kstars/kstars/ekos/ekoslive/message.cpp:1315:92: error: no match for 'operator[]' (operand types are 'const QJsonValue' and 'const char [6]')
Options::self()->setProperty(oneOption["name"].toString().toLatin1(), oneOption["value"].toVariant());
^
/home/observatoire/Projects/kstars/kstars/ekos/ekoslive/message.cpp:1324:40: error: no match for 'operator[]' (operand types are 'const QJsonValue' and 'const char [5]')
const auto name = oneOption["name"].toString();
^
At global scope:
cc1plus: warning: unrecognized command line option '-Wno-stringop-truncation'
kstars/CMakeFiles/KStarsLib.dir/build.make:3979: recipe for target 'kstars/CMakeFiles/KStarsLib.dir/ekos/ekoslive/message.cpp.o' failed
make[2]: *** [kstars/CMakeFiles/KStarsLib.dir/ekos/ekoslive/message.cpp.o] Error 1
Hi Gilles,
I don't remember seeing that issue, so I can't really help. It seems like a build environment issue.
I had problems trying to update my Odroid-N2 from 18.04 to 20.04 when I upgraded (quite a while ago) and eventually started with a fresh install later on. It helped a bit to have the astrometry index files / images / etc. on an attached external SSD.
I also tried 21.04 but that will have to wait for a hardkenel release (IMHO).
Thanks for your reply Jerry,
I am building the whole suite using your great script and things are usually going very well but this one puzzles me. Seems related to some json library or header files but the dependencies seem to be OK and I don't know where to look.
IIRC I succeeded in building an earlier (before recent merges) KStars 3.6 but now something may be different that causes this issue.
Maybe a fresh install of Ubuntu 20.04 is the answer after all. But I will wait a few days, hoping for a solution/workaround.
OK! Found out that the change that causes the problem comes from a merge done 2 days ago (19 June) on the 'kstars/ekos/ekoslive/message.cpp' file, that, from what I understand, requires Qt 5.10 and above; Qt 5.9.5 is the one installed on my Ubuntu 18.04 LTS system.
I wonder if there is an easy way to build kstars from 3 days ago as a temporary solution, until I commit to installing 20.04 LTS!?
Thanks for your reply, it was very helpful in figuring out how to build earlier versions from GIT.
I had also forgotten to mention that I was trying to build 3.6 beta, not stable, as I wanted to used the new polar alignment assistant using plate solve. But with your help I could build the earlier commit of 3.6 beta that did not cause the issue I was having.