Build from next PFD and ModelView not working
« on: May 08, 2016, 12:19:52 pm »
I have a bit of a problem running GCS that I build from next.

The build itself goes trough ok, but when I tried to run the GCS, I would get an error on the first picture.
I click out of it and everything except PFD and ModelWiew gadgets works.
I managed to get around that error by upgrading libstdc++6 and now I get an error shown on the second picture.
Clicking trough that message produces same results as before.

I'm running out of ideas on what should I try to get around that, so are there any from people that actually know what they're doing?

My system is running LinuxMint17 64Bit.

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Build from next PFD and ModelView not working
« Reply #1 on: May 08, 2016, 02:26:31 pm »
You got this error because the pre-build OSG binaries you installed using "make osg_install" do not fit your system.

So you need to take the long way by compiling your own Osg* binaries with
Code: [Select]
make all_osgand next after a long time compiling,  copy/uncompress manually the two archives you got finally into ./build/3rdparty/install/ to the ./tools dir.


Or do the same as here:
https://librepilot.atlassian.net/wiki/display/LPDOC/Linux+-+Building+and+Packaging#Linux-BuildingandPackaging-Linux32(i686)-Qt5.6issue
Using all packages from the system, only tested with i386 but should works the same for x86_64.


Re: Build from next PFD and ModelView not working
« Reply #2 on: May 08, 2016, 07:48:49 pm »
Thanks for the tip.

I tried make all_osg.

It seems that osg-3.5.1 builds correctly, but osgearth-2.7 craps out saying:

Code: [Select]
Building osgEarth 3rdparty/osgearth into build/3rdparty/osgearth-2.7-linux-x64-qt-5.6.0
-- The C compiler identification is GNU 4.8.5
-- The CXX compiler identification is GNU 4.8.5
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Looking for include file pthread.h
-- Looking for include file pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE 
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so
-- Looking for XOpenDisplay in /usr/lib/x86_64-linux-gnu/libX11.so;/usr/lib/x86_64-linux-gnu/libXext.so - found
-- Looking for gethostbyname
-- Looking for gethostbyname - found
-- Looking for connect
-- Looking for connect - found
-- Looking for remove
-- Looking for remove - found
-- Looking for shmat
-- Looking for shmat - found
-- Found X11: /usr/lib/x86_64-linux-gnu/libX11.so
-- Found OpenGL: /usr/lib/libGL.so 
-- Found ZLIB: /usr/lib/x86_64-linux-gnu/libz.so (found version "1.2.8")
-- Could NOT find PROTOBUF (missing:  PROTOBUF_LIBRARY PROTOBUF_INCLUDE_DIR)
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.26")
-- Plugins will be installed under osgPlugins-3.5.1 directory.
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
CURL_INCLUDE_DIR
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarth
CURL_LIBRARY
    linked by target "osgEarth" in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarth
GDAL_INCLUDE_DIR
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarth
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthAnnotation
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthFeatures
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthUtil
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/feature_tfs
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/gdal
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/feature_wfs
   used as include directory in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/feature_ogr
GDAL_LIBRARY
    linked by target "osgEarth" in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarth
    linked by target "osgEarthAnnotation" in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthAnnotation
    linked by target "osgdb_osgearth_feature_tfs" in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/feature_tfs
    linked by target "osgdb_osgearth_gdal" in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/gdal
    linked by target "osgdb_osgearth_feature_wfs" in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/feature_wfs
    linked by target "osgdb_osgearth_feature_ogr" in directory /home/andraz/Librepilot/3rdparty/osgearth/src/osgEarthDrivers/feature_ogr

-- Configuring incomplete, errors occurred!
See also "/home/andraz/Librepilot/build/3rdparty/osgearth-2.7-linux-x64-qt-5.6.0/CMakeFiles/CMakeOutput.log".
See also "/home/andraz/Librepilot/build/3rdparty/osgearth-2.7-linux-x64-qt-5.6.0/CMakeFiles/CMakeError.log".
make: *** [osgearth] Error 1

I attached the CMakeError.log file which might contain info about why it's failing.
The content of that log seem to show what failed but I'm still way off from understanding what, so... help!!  :(

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Build from next PFD and ModelView not working
« Reply #3 on: May 08, 2016, 08:02:20 pm »
Missing dependencies, read the errors:

install gdal-dev, curl-dev, protobuf. Retry

Re: Build from next PFD and ModelView not working
« Reply #4 on: May 08, 2016, 11:10:36 pm »
Good news, I got it working without something catching on fire :D

Learning every day...
Of course, someone had to point out the obvious thing, that my thick skull failed to absorb.

Anyway, thanks for your help mate, my build environment seems to be now fully operational :D

f5soh

  • *****
  • 4572
    • LibrePilot
Re: Build from next PFD and ModelView not working
« Reply #5 on: May 08, 2016, 11:57:33 pm »
Great :)

Sometimes you can do a 'git pull' to reflect recent changes from next branch and rebuild when you want.