在 Ubuntu 16.04 上安装 Omnet++ 时出错:找不到 osgEarth
Error while installing Omnet++ on Ubuntu 16.04 : Cannot find osgEarth
我按照安装指南安装了所有提到的包。但是,我在 运行 ./configure
时收到此错误消息
checking for osgEarth with CFLAGS=" -fPIC -fno-stack-protector " LIBS=" -losgEarth -losgEarthUtil"... no
configure: error: Cannot find osgEarth 2.7 or later. Set WITH_OSGEARTH=no in configure.user to disable this feature or install an up to date version of osgEarth.
这是我的 config.log 文件的 link :config.log
安装 libgeos-dev
包,然后编辑我的 OMnet++ 源目录中的 configure.user
文件解决了我的问题。
$ sudo apt-get install libgeos-dev
将行 #OSGEARTH_LIBS=
更改为:
OSGEARTH_LIBS=" -losgEarth -losgEarthUtil -lgeos_c "
确保删除开头的#。
现在运行:
$ . setenv
$ ./configure
它应该可以工作..
其他人之前也遇到过这个问题,这里提到的修复解决了他们的问题:
http://gmt.soest.hawaii.edu/boards/1/topics/4621
https://trac.osgeo.org/postgis/changeset/11363
Attila Török 在 omnetpp google 组 (omnetpp@googlegroups.com) 上回答
Cannot find osgEarth 2.7 or later
osgearth 2.7
对于 Ubuntu 16.04 → https://launchpad.net/~ubuntugis/+archive/ubuntu/ppa →
sudo add-apt-repository ppa:ubuntugis/ppa
sudo apt update
sudo apt install libosgearth-dev // you get "2.7"
// All prerequisites :
sudo apt install g++ libxml2-dev libosgearth-dev bison flex clang swig libqt5opengl5-dev qt5-qmake openjdk-8-jre libopenmpi-dev tcl8.5-dev tk8.5-dev
我按照安装指南安装了所有提到的包。但是,我在 运行 ./configure
时收到此错误消息checking for osgEarth with CFLAGS=" -fPIC -fno-stack-protector " LIBS=" -losgEarth -losgEarthUtil"... no
configure: error: Cannot find osgEarth 2.7 or later. Set WITH_OSGEARTH=no in configure.user to disable this feature or install an up to date version of osgEarth.
这是我的 config.log 文件的 link :config.log
安装 libgeos-dev
包,然后编辑我的 OMnet++ 源目录中的 configure.user
文件解决了我的问题。
$ sudo apt-get install libgeos-dev
将行 #OSGEARTH_LIBS=
更改为:
OSGEARTH_LIBS=" -losgEarth -losgEarthUtil -lgeos_c "
确保删除开头的#。
现在运行:
$ . setenv
$ ./configure
它应该可以工作..
其他人之前也遇到过这个问题,这里提到的修复解决了他们的问题:
http://gmt.soest.hawaii.edu/boards/1/topics/4621
https://trac.osgeo.org/postgis/changeset/11363
Attila Török 在 omnetpp google 组 (omnetpp@googlegroups.com) 上回答
Cannot find osgEarth 2.7 or later
osgearth 2.7
对于 Ubuntu 16.04 → https://launchpad.net/~ubuntugis/+archive/ubuntu/ppa →
sudo add-apt-repository ppa:ubuntugis/ppa
sudo apt update
sudo apt install libosgearth-dev // you get "2.7"
// All prerequisites :
sudo apt install g++ libxml2-dev libosgearth-dev bison flex clang swig libqt5opengl5-dev qt5-qmake openjdk-8-jre libopenmpi-dev tcl8.5-dev tk8.5-dev