Is is possible to build the Flysight Viewer on Linux?

76 views
Skip to first unread message

Esa-Matti Suuronen

unread,
Jun 24, 2015, 4:58:01 PM6/24/15
to flysig...@googlegroups.com
Or is the code so platform depended that there's no chance of building it on Linux?

Esa 

Michael Cooper

unread,
Jun 24, 2015, 6:46:51 PM6/24/15
to flysig...@googlegroups.com

Hi Esa—

 

It shouldn’t be hard to port it to Linux. The only platform-dependent aspect that comes to mind is libvlc, but of course that’s available for Linux as well. If any changes are necessary, they will most likely be in “FlySightViewer.pro”:

 

win32 {

    LIBS        += -L../lib

    INCLUDEPATH += ../include

}

else {

    LIBS        += -L/usr/local/lib

    INCLUDEPATH += /usr/local/include

}

 

If libvlc installs to /usr/local on Linux, then it should compile without changes, I think.

 

I don’t have a Linux box handy to test, but would love to hear what you learn!

 

Michael

--
You received this message because you are subscribed to the Google Groups "FlySight Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flysight-dev...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Esa-Matti Suuronen

unread,
Jun 25, 2015, 5:36:51 AM6/25/15
to flysig...@googlegroups.com
Oh, sweet! It did build without changes!

I used Ubuntu Trusty, Qt Creator from the default repositories and qt-vlc from the http://vlc-qt.tano.si PPA repository.

Here's roughly what I did

add-apt-repository ppa:ntadej/tano
apt-get update
apt-get install qtcreator libvlc-dev libvlccore7 libvlccore-dev libvlc-dev libvlc5 libqt5webkit5-dev libvlc-qt-core1 libvlc-qt-widgets1 libvlc-qt-dbg libvlc-qt-dev

and opened FlySightViewer.pro with Qt Creator and just hit build project.

Esa



Nadi B

unread,
Jul 18, 2015, 1:49:58 PM7/18/15
to flysig...@googlegroups.com
Heia ESA,
could you send me the linux version you compiled? or put it available somewhere? I use currently Ubuntu 14.04. 
Thanks! 
Nadi, Norway

Malcolm Schongalla

unread,
Apr 30, 2017, 12:18:10 PM4/30/17
to FlySight Developers
Hi- Just found this old threat while trying to compile the flysight viewer in Linux Mint 17 with qt5.

I have been generally successful with the preparatory steps outlined in the github readme file, including compiling wwWidgets.  But I am having trouble getting the flighsight-viewer-qt source to compile.

qmake runs OK. But, after running make in folder ~/flysight-viewer-qt, I get several error messages that generally look like this:


genome.cpp: In constructor ‘Genome::Genome(const Genome&, const Genome&, int)’:
genome.cpp:30:25: error: no matching function for call to ‘Genome::append(QVector<double>)’
     append(p1.mid(0, j1));
                         ^
genome.cpp:30:25: note: candidate is:
In file included from /usr/include/qt5/QtCore/QVector:1:0,
                 from genome.h:4,
                 from genome.cpp:1:
/usr/include/qt5/QtCore/qvector.h:558:6: note: void QVector<T>::append(const T&) [with T = double]
 void QVector<T>::append(const T &t)
      ^
/usr/include/qt5/QtCore/qvector.h:558:6: note:   no known conversion for argument 1 from ‘QVector<double>’ to ‘const double&’


This error is reported for every call to the function append() in genome.cpp, but I left out the rest of the compiler output for brevity.

Not being familiar with the code base, and generally not being familiar with any coding paradigms developed since 1990, I'm struggling to wrap my head around the errors, beyond apparently being some kind of declaration mismatch or missing header file.  I tried tweaking FlySightViewer.pro as Michael suggested, including playing around witht INCLUDEPATH and LIB variables specific to my machine (i.e., /usr/lib and /usr/include)

Any thoughts on what I should try, to resolve this error?
Thanks,
Malcolm

Michael Cooper

unread,
Apr 30, 2017, 12:21:17 PM4/30/17
to flysig...@googlegroups.com
Hi Malcolm--

One other person has reported as similar issue. I think the problem may be due to the specific version of Qt which you have installed. You can find what version of Qt you're using with the following command:

qmake --version

Please let me know the result and we'll go from there.

Michael

--
You received this message because you are subscribed to the Google Groups "FlySight Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flysight-devs+unsubscribe@googlegroups.com.

Malcolm Schongalla

unread,
Apr 30, 2017, 2:55:47 PM4/30/17
to FlySight Developers

Thanks for your reply.

$ qmake --version
QMake version 3.0
Using Qt version 5.2.1 in /usr/lib/x86_64-linux-gnu


What version is the code built for?

Michael Cooper

unread,
Apr 30, 2017, 4:40:33 PM4/30/17
to flysig...@googlegroups.com
That might be the problem. The code is built around Qt 5.5. The following line in the build instructions selects Qt 5.x:

export QT_SELECT=qt5

However, I'm not sure how to get more specific than that. Perhaps someone with more Linux/Qt experience can say?

Michael

--
Message has been deleted

Malcolm Schongalla

unread,
Apr 30, 2017, 8:51:29 PM4/30/17
to FlySight Developers

me
 (Malcolm Schongalla change
8:44 PM (less than a minute ago)
Hey! Got it working :)

The problem appears to be that I was using Qt 5.2, but the code is built for Qt 5.5.  Unfortunately, the Ubuntu/Mint repositories are stuck at version 5.2, so the necessary version needs to be installed manually.  The repository version puts the Qt 5.2 relevant files into /usr/lib/x86_64-linux-gnu and /usr/include on a Mint 17 installation, and that's where make defaults to looking for the outdated libraries and headers.

Here's what I did.

0. I had already tried setting the environment variable, QT_SELECT=qt5, but that alone got me nowhere (qmake ver 3. is not a problem)
1. I downloaded Qt 5.5 from https://www.qt.io/download-open-source/, they had version 5.8.stable at the time of this post but I used 5.5. I used their linux installer utility to install it to ~/Qt

2. Redirected the compiler to the new Qt 5.5 files.  One could edit the .pro file to add the lines:
    LIBS += -L/home/$USER/Qt/5.5/gcc_64/lib
    INCLUDEPATH += /home/$USER/Qt/5.5/gcc_64/include
    INCLUDEPATH += /home/$USER/Qt/5.5/gcc_64/include/QtCore
(Actually, what I did was edit the Makefile directly, but editing the .pro file in this fashion would have the same net result.  And I used the actual user name in place of $USER but that should get the point across)

3. Ran make successfully.  The compiler threw out a litany of warnings but I don't know if that is inherent to the FlySightViewer code, or if it's just a side-effect of having to struggle to reference the right libraries and headers.

So far, after cursory usage, I have only found one or two bugs. For instance, File->Import Tracks, the open file dialogue can't screen in .CSV files, but it can identify .csv files.  I assume that's a trivial fix.  If I find anything major I'll try to identify it here.

An advantage of doing it this way, is if I wanted to keep my filesystem clean, it is easy to just purge the ~/Qt folder once I'm done compiling.  And it will keep the integrity of the repository installed version.  Hopefully the repo maintainers will update their packages soon.

It's great to have a working viewer on linux finally... it was one of the last things I kept a Windows partition around for lol

Malcolm
Auto Generated Inline Image 1

Michael Cooper

unread,
May 2, 2017, 2:05:12 PM5/2/17
to flysig...@googlegroups.com
Thanks for sharing, Malcolm! I will pass this information along.

There are quite a few warnings in the FlySight Viewer code at the moment--mostly things like unused variables or variables that may not be initialized if a certain control path is followed. I suspect that these are related, e.g., to an issue we have when a video is loaded before data on macOS, so I'm slowly picking through them. However, for the most part I don't think they will affect functionality.

Qt 5.6 and later have moved from WebKit to WebEngine. At the moment, I'm using WebKit to render the map view. Unfortunately, one significant difference between WebKit and WebEngine seems to be that the latter runs commands asynchronously, so I would need to change from "blocking" code to a callback-based system. Rather than tackle that project, for the moment I'm just working with Qt 5.5.

Michael

--

Malcolm Schongalla

unread,
May 19, 2017, 10:14:30 PM5/19/17
to FlySight Developers
I've been meddling with the code a bit on my machine:

1. I fixed a bug which caused the program to crash, at least in linux.  If you attempted to "Undo Zoom" or "Redo Zoom" before loading any tracks, it apparently resulted in unpredictable behavior and exited.  I disabled these actions until an initial zoom range is set for the first time, i.e. by loading a track.  Redundantly, I also put a check in the functions on_action[Undo/Redo]Zoom_triggered() to make sure the applicable stack wasn't empty before pop'ing it. Either fix by itself prevented the crash.

2. I added a third menu slot action, "Tools->Reset Zoom." I debated various methods* and ultimately went with a method that lets you "undo" the reset, by utilizing the otherwise-declared-but-unused variables, mRangeLower and mRangeUpper (in mainwindow.h), for storing & recalling the original zoom range.

*As opposed to, for example, just calling initRange() again, and resetting the undo/redo stacks in the process.  Alternately one could also just crawl up the undo stack, so to speak.  I dunno, I'm not really a "coder" so I don't know if any one technique is preferred. :)

3. Added a Help->About dialog, only because I am learning Qt and OOP and I figured I should probably learn how to do something like that :)

4. Eliminated a few irrelevant compiler warnings generated by mainwindow.cpp & mainwindow.h

Anyway, I have no clue what I'm doing and probably should not be allowed to touch a compiler, but it was fun to nerd out for a while.  If this is useful to anybody but myself, let me know :)

Malcolm Schongalla

unread,
May 19, 2017, 10:24:14 PM5/19/17
to FlySight Developers
Oh, and:

5. File->Import Tracks now recognizes ".CSV" as well as ".csv" extensions (but I did not bother with mixed-case examples).  Handy because files imported from Windows file systems seem to always be .CSV which were not originally filtered in.

Michael Cooper

unread,
May 20, 2017, 10:34:18 AM5/20/17
to flysig...@googlegroups.com
Hi Malcolm--

Thanks for passing these along. There are a few bug similar to your (1) which I've been meaning to track down for a while. For example, if you import a video before importing a track, there are issues related to the fact that the ranges have not yet been initialized.

Your (5) is a very good idea. I would have thought, actually, that the FlySight itself also stored as ".CSV" and might cause issues on a Linux system. Is this not the case?

Michael

On Fri, May 19, 2017 at 8:24 PM, Malcolm Schongalla <malcolm.s...@gmail.com> wrote:
Oh, and:

5. File->Import Tracks now recognizes ".CSV" as well as ".csv" extensions (but I did not bother with mixed-case examples).  Handy because files imported from Windows file systems seem to always be .CSV which were not originally filtered in.

--

Malcolm Schongalla

unread,
May 20, 2017, 11:33:15 AM5/20/17
to FlySight Developers
My pleasure!

1) I don't have any video to accompany my tracks, so I hadn't gotten around to exploring that realm, yet.  But I will try to shoot some video this summer and delve into that process.  If there are other crash bugs on your mind, I could take a look at those too. (I just experimented, and the first random video I tried loading--alongside an unrelated track--caused a crash:) )

regarding 5) now that you mention it, I do vaguely recall the flysight storing its files with capital letters, and that being a minor issue too.  I'm traveling at the moment, and all I had to work with was a folder of saved tracks on an NTFS partition, so it wasn't fresh on my mind.  But, that was the same issue basically.
Reply all
Reply to author
Forward
0 new messages