Reply to topic

error: cannot find -lmarblewidget

Martin5017
Registered Member
Posts
1
Karma
0
OS

error: cannot find -lmarblewidget

Tue May 10, 2016 5:55 am
OS: Ubunutu 14.04 (running in VirtualBox on Windows 7)
Qt 5.5.0

I installed marble according to the guide on https://techbase.kde.org/Marble/QtCreator
1. Clone from marble repo git://anongit.kde.org/marble
2. Run CMAKE from within Qt Creator with arguments: -DCMAKE_INSTALL_PREFIX=../marble-export -DQTONLY=TRUE -DCMAKE_BUILD_TYPE=Debug
3. Run make install from Qt Creator (with sudo)

Then I added the following lines to my .pro file:
Code: Select all
   
LIBS += -L/usr/local/lib \
    -lmarblewidget


and I put the following code in the main.cpp file:

Code: Select all
#include <QApplication>
#include <marble/MarbleWidget.h>

int main(int argc, char *argv[])
{
   QApplication app(argc, argv);

   // Load Marble using OpenStreetMap in Mercator projection
   Marble::MarbleWidget *mapWidget = new Marble::MarbleWidget;
   mapWidget->setProjection(Marble::Mercator);
   mapWidget->setMapThemeId("earth/openstreetmap/openstreetmap.dgml");

   mapWidget->setWindowTitle("Hello Marble!");
   mapWidget->show();

   return app.exec();
}


but when I build I get the error message "cannot find -lmarblewidget"

Is there an include path that I should specify?
What should be in "/usr/local/lib"?
User avatar Earthwings
KDE Developer
Posts
172
Karma
1
OS
Please try with marblewidget-qt5 instead of marblewidget. We renamed it at some point so Qt4 and Qt5 installations could co-exist.

 
Reply to topic

Bookmarks



Who is online

Registered users: Baidu [Spider], Bing [Bot], boudewijn, chris-on-neon, claydoh, Don B. Cilly, farid, funkyskywalker, Google [Bot], jbouter, jdvm, kde-jriddell, koffeinfriedhof, plistov, sh-zam, Sogou [Bot], srgmro33, tagerritsen, tiguchi