Quantcast
Channel: Jobs
Viewing all articles
Browse latest Browse all 18427

`GDALAllRegister@0' when linking GDAL to Qt

$
0
0
hello, I’ve been trying desperately to link GDAL library to Qt (5.0.1) ., but didn’t succeed. I keep getting error messages every times I use a gal function. #include "mainwindow.h" #include <QApplication> #include <gdal_priv.h> #include <cpl_conv.h> #include <cpl_string.h>   int main(int argc, char *argv[]) {     QApplication a(argc, argv);     MainWindow w;     GDALAllRegister();           w.show();     return a.exec(); } and my pro file is #------------------------------------------------- # # Project created by QtCreator 2013-04-07T21:45:42 # #-------------------------------------------------   QT       += core gui   greaterThan(QT_MAJOR_VERSION, 4): QT += widgets   TARGET = sans_titre1 TEMPLATE = app     SOURCES += main.cpp\         mainwindow.cpp   HEADERS  += mainwindow.h   FORMS    += mainwindow.ui       INCLUDEPATH += "D:/gdal-1.9.2/include" LIBPATH += -L"D:/gdal-1.9.2/lib/" LIBS += -lgdal_i then : undefined reference to `GDALAllRegister@0’ Please help !

Viewing all articles
Browse latest Browse all 18427

Trending Articles