ludomotico wrote in Mon Dec 22, 2014 12:18 pm:If I understood correctly, you are REMOVING some gdal lines. I hardly see how removing random lines could enhance the simulator, be very careful about that.
Not, You did not. Reread topic from beginning to comprehend why some changes are needed with rebuilding gdal from scratch. Actually it could not work with preinstalled gdal correctly, too.
ludomotico wrote in Mon Dec 22, 2014 12:18 pm:As Hooray says, there is no need to recompile gdal and the one provided by your distribution is probably ok.
Look at previous message addition to check out that's needed.
By the way, compilation attempt at Fedora fails much more earlier, at
osgearth compilation. Maybe it could be better just to try other distribution deeply.
Well, after rechecking, at Fedora it fails with erros of
- Code: Select all
[ 20%] Built target FGAdminUI
Linking CXX executable fgelev
Linking CXX executable fgpanel
/usr/bin/ld: warning: libosgEarthFeatures.so.0, needed by /opt/FgOsgEarth/OsgEarth/lib64/libosgEarthAnnotation.so, not found (try using -rpath or -rpath-link)
...
/opt/FgOsgEarth/OsgEarth/lib64/libosgEarthUtil.so: undefined reference to `osgText::Text::accept(osg::Drawable::ConstAttributeFunctor&) const'
collect2: error: ld returned 1 exit status
make[2]: *** [utils/fgpanel/fgpanel] Error 1
make[1]: *** [utils/fgpanel/CMakeFiles/fgpanel.dir/all] Error 2
type.
It seems that could compile osg or
osgearth without something that later needed at fg compilation, and it could occur at each distro. Plus mistake warnings looks pretty wrong. That library which it could not find, libosgEarthFeatures.so.0, it lays near first one, libosgEarthAnnotation.so, which says it could not see it.
Nah, and I could add that I have older version of fg compiled from scratch at this distribution working, and this compiled way I am trying to compile that one exactly. So problems are
osgearth build specific for sure.
Well, that mistake solved by something as that:
- Code: Select all
export LD_LIBRARY_PATH=/opt/FgOsgEarth/OpenSceneGraph/lib64:/opt/FgOsgEarth/OsgEarth/lib64:/opt/FgOsgEarth/simgear/lib:/opt/FgOsgEarth/plib/lib:$LD_LIBRARY_PATH[/quote]
prior fg making. Heh, it already sounds as "news from battlefield".
At preinstalled gdal it gives:
[quote]Linking CXX executable fgfs
/usr/bin/ld: CMakeFiles/fgfs.dir/__/Viewer/OsgEarthHeightField.cxx.o: undefined reference to symbol 'VSIFree'
/usr/bin/ld: note: 'VSIFree' is defined in DSO /lib64/libgdal.so.1 so try adding it to the linker command line
/lib64/libgdal.so.1: could not read symbols: Invalid operation
collect2: error: ld returned 1 exit status
make[2]: *** [src/Main/fgfs] Error 1
make[1]: *** [src/Main/CMakeFiles/fgfs.dir/all] Error 2
ldd on that one gives
- Code: Select all
ldd /lib64/libgdal.so.1
linux-vdso.so.1 => (0x00007fff761f0000)
libarmadillo.so.4 => /lib64/libarmadillo.so.4 (0x0000003325a00000)
libpoppler.so.43 => /lib64/libpoppler.so.43 (0x0000003325000000)
libfreexl.so.1 => /lib64/libfreexl.so.1 (0x0000003321a00000)
libgeos_c.so.1 => /lib64/libgeos_c.so.1 (0x0000003323400000)
libwebp.so.4 => /lib64/libwebp.so.4 (0x0000003f1c600000)
libodbc.so.2 => /lib64/libodbc.so.2 (0x000000331de00000)
libodbcinst.so.2 => /lib64/libodbcinst.so.2 (0x000000331da00000)
libexpat.so.1 => /lib64/libexpat.so.1 (0x0000003ef6000000)
libxerces-c-3.1.so => /lib64/libxerces-c-3.1.so (0x0000003322200000)
libjasper.so.1 => /lib64/libjasper.so.1 (0x0000003efe000000)
libnetcdf.so.7 => /lib64/libnetcdf.so.7 (0x000000331d200000)
libhdf5.so.8 => /lib64/libhdf5.so.8 (0x000000331c600000)
libgif.so.4 => /lib64/libgif.so.4 (0x0000003532600000)
libjpeg.so.62 => /lib64/libjpeg.so.62 (0x0000003f06400000)
libgeotiff.so.1.2 => /lib64/libgeotiff.so.1.2 (0x000000331c200000)
libtiff.so.5 => /lib64/libtiff.so.5 (0x000000331ba00000)
libgta.so.0 => /lib64/libgta.so.0 (0x0000003320400000)
libpng16.so.16 => /lib64/libpng16.so.16 (0x0000003ef4c00000)
libcfitsio.so.1 => /lib64/libcfitsio.so.1 (0x000000331f000000)
libpq.so.5 => /lib64/libpq.so.5 (0x000000331f800000)
liblzma.so.5 => /lib64/liblzma.so.5 (0x0000003ef1400000)
librt.so.1 => /lib64/librt.so.1 (0x0000003ef1c00000)
libdapclient.so.3 => /lib64/libdapclient.so.3 (0x000000331d600000)
libdapserver.so.7 => /lib64/libdapserver.so.7 (0x0000003323000000)
libdap.so.11 => /lib64/libdap.so.11 (0x000000331f400000)
libspatialite.so.5 => /lib64/libspatialite.so.5 (0x0000003322800000)
libpcre.so.1 => /lib64/libpcre.so.1 (0x0000003ef2000000)
libcurl.so.4 => /lib64/libcurl.so.4 (0x000000352d400000)
libCharLS.so.1 => /lib64/libCharLS.so.1 (0x0000003324c00000)
libxml2.so.2 => /lib64/libxml2.so.2 (0x0000003702c00000)
libmysqlclient.so.18 => /usr/lib64/mysql/libmysqlclient.so.18 (0x0000003320c00000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x0000003ef0400000)
libz.so.1 => /lib64/libz.so.1 (0x0000003ef1000000)
libssl.so.10 => /lib64/libssl.so.10 (0x0000003a69000000)
libcrypto.so.10 => /lib64/libcrypto.so.10 (0x0000003a6d800000)
libdl.so.2 => /lib64/libdl.so.2 (0x0000003ef0800000)
libstdc++.so.6 => /lib64/libstdc++.so.6 (0x0000003ef5000000)
libm.so.6 => /lib64/libm.so.6 (0x0000003ef0c00000)
libc.so.6 => /lib64/libc.so.6 (0x0000003ef0000000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x0000003ef1800000)
libblas.so.3 => /lib64/libblas.so.3 (0x0000003320000000)
liblapack.so.3 => /usr/lib64/atlas/liblapack.so.3 (0x000000331e200000)
libcblas.so.3 => /usr/lib64/atlas/libcblas.so.3 (0x000000331ec00000)
libclapack.so.3 => /usr/lib64/atlas/libclapack.so.3 (0x0000003325600000)
libarpack.so.2 => /lib64/libarpack.so.2 (0x000000331fc00000)
/lib64/ld-linux-x86-64.so.2 (0x0000003eefc00000)
liblcms2.so.2 => /lib64/liblcms2.so.2 (0x0000003f0c400000)
libopenjpeg.so.1 => /lib64/libopenjpeg.so.1 (0x0000003703400000)
libfontconfig.so.1 => /lib64/libfontconfig.so.1 (0x0000003ef7800000)
libfreetype.so.6 => /lib64/libfreetype.so.6 (0x0000003ef5800000)
libgeos-3.4.2.so => /lib64/libgeos-3.4.2.so (0x0000003324800000)
libltdl.so.7 => /lib64/libltdl.so.7 (0x0000003f0b000000)
libnsl.so.1 => /lib64/libnsl.so.1 (0x0000003f12a00000)
libhdf5_hl.so.8 => /lib64/libhdf5_hl.so.8 (0x000000331ce00000)
libSM.so.6 => /lib64/libSM.so.6 (0x000000352c000000)
libICE.so.6 => /lib64/libICE.so.6 (0x0000003f09800000)
libX11.so.6 => /lib64/libX11.so.6 (0x0000003ef4800000)
libproj.so.0 => /lib64/libproj.so.0 (0x0000003a6d400000)
libjbig.so.2.0 => /lib64/libjbig.so.2.0 (0x000000331be00000)
libbz2.so.1 => /lib64/libbz2.so.1 (0x0000003f09400000)
libkrb5.so.3 => /lib64/libkrb5.so.3 (0x0000003f03000000)
libcom_err.so.2 => /lib64/libcom_err.so.2 (0x0000003efc800000)
libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x0000003f02000000)
libldap_r-2.4.so.2 => /lib64/libldap_r-2.4.so.2 (0x0000003320800000)
libuuid.so.1 => /usr/lib64/libuuid.so.1 (0x0000003528400000)
libsqlite3.so.0 => /lib64/libsqlite3.so.0 (0x000000352c400000)
libidn.so.11 => /lib64/libidn.so.11 (0x0000003f0ec00000)
libssh2.so.1 => /lib64/libssh2.so.1 (0x00000037c0800000)
libssl3.so => /lib64/libssl3.so (0x0000003705400000)
libsmime3.so => /lib64/libsmime3.so (0x0000003705c00000)
libnss3.so => /lib64/libnss3.so (0x0000003704c00000)
libnssutil3.so => /lib64/libnssutil3.so (0x0000003704800000)
libplds4.so => /lib64/libplds4.so (0x0000003f05800000)
libplc4.so => /lib64/libplc4.so (0x0000003f07800000)
libnspr4.so => /lib64/libnspr4.so (0x0000003f05c00000)
libk5crypto.so.3 => /lib64/libk5crypto.so.3 (0x0000003f01c00000)
liblber-2.4.so.2 => /lib64/liblber-2.4.so.2 (0x0000003f13e00000)
libldap-2.4.so.2 => /lib64/libldap-2.4.so.2 (0x0000003708800000)
libgfortran.so.3 => /lib64/libgfortran.so.3 (0x0000003ef3400000)
libf77blas.so.3 => /usr/lib64/atlas/libf77blas.so.3 (0x0000003321e00000)
libatlas.so.3 => /usr/lib64/atlas/libatlas.so.3 (0x0000003321200000)
libquadmath.so.0 => /lib64/libquadmath.so.0 (0x0000003ef3000000)
libxcb.so.1 => /lib64/libxcb.so.1 (0x0000003ef4400000)
libkrb5support.so.0 => /lib64/libkrb5support.so.0 (0x0000003f02400000)
libkeyutils.so.1 => /lib64/libkeyutils.so.1 (0x0000003efd400000)
libresolv.so.2 => /lib64/libresolv.so.2 (0x0000003ef2c00000)
libsasl2.so.3 => /lib64/libsasl2.so.3 (0x0000003707400000)
libXau.so.6 => /lib64/libXau.so.6 (0x0000003ef4000000)
libselinux.so.1 => /lib64/libselinux.so.1 (0x0000003ef2400000)
libcrypt.so.1 => /lib64/libcrypt.so.1 (0x0000003705800000)
libfreebl3.so => /lib64/libfreebl3.so (0x0000003705000000)
To me it seems more or less normal. Only standard preinstalled libraries in list. It shoud work, but it wont. So, at two distros, with different jumps around, similar result - fail. I wll try last attempt, with gdal compiling from source, if that one would not work then it's up to someone else to try it. One weekend is more than enough to spare at things as that. And, anyway, that way would be more or less ok with testing, but could not work with release. People just could not make it.
Ok, at Ubuntu is exactly same mistake with VSIFree, but at manually installed /opt/FlightGear/gdal/lib/libgdal.so.1 . Gdal version is 1.11. I did maually checked all ldd results - all are existed.
I made my best - "-gdal" addition to CMAKE_EXE_LINKER_FLAGS, and even adding all its dependencies declared by CONFIG_DEP_LIBS at its config, does not change a thing. Last option is to add by -L and -I any library and include paths presented, but I doubt it could help. Broken task.
So, as already two haven't it continuosly, in three or four differet vatiants, I gotta admit that
we actually don't have it. If any we is existed at all there.
What I find pointing is that errors is different with different gdal vesrions compiled at same environment.
You know, "something works for someone" is temporary state. Finally it turns out working for everybody, anybody, - ones You do not like too - or not working at all. And it's question of choice actually.
Ok, made it. Only solution that worked, main part of it, is manual adding of /opt/FlightGear/gdal/lib/libgdal.so or so, direct link to libgdal.so , into ..flightgear/src/Main/CMakeFiles/fgfs.dir/link.txt and ..flightgear/src/Main/CMakeFiles/fgfs.dir/relink.txt , prior any libosgearth lines, after cmake and prior make.
And other nasty hack is adding of things as '-L/opt/FgOsgEarth/OpenSceneGraph/lib64 -L/opt/FgOsgEarth/
OsgEarth/lib64 -L/opt/FgOsgEarth/simgear/lib -L/opt/FgOsgEarth/plib/lib -L/usr/lib -L/lib64 -L/usr/lib/x86_64-linux-gnu -L/lib/x86_64-linux-gnu/' in flags.make file there, ignoring "DO NOT EDIT!" demands. Honey, if You want someone follow Your rules, make it way making following it resultative - if You could, in which I doubt really.
That only one way which worked - that .. thing seems to ignore any flags and variables, and even in cmake files itself. Could recheck it at Fedora later bit..yeah, same .. . Only that one in addition needs in adding of things as '-Wl,-rpath,/opt/FgOsgEarth/OpenSceneGraph/lib64:/opt/FgOsgEarth/
OsgEarth/lib64' in some relink.txt files.
It's kinda as make present to someone, put in some box, closed on lock, without keys presenting. Wonder if Your life give to You presents that way - You should learned it somewhere previously.
Heh, wonder if changing my messages could solve any problem.
Waste of time: too unprofitable for work, too exhausting for hobby.