WebDAV and Qt4
-
thanx so much!
-
Now another question.
I followed this description:
http://xf.iksaif.net/dev/qwebdav.htmlBut I cant use the line:
@#include <QWebdav>@
instead I am able to use this:
@#include <qwebdav/QWebdav>@but this way the compiler drops the first error for the following line:
@QWebdav webdav = new QWebdav;@
saying:
@error: undefined reference to 'QWebdav::QWebdav(QObject)'@ -
Hi Jazoja,
regarding the include thing:
where did you put the QWebDav includes and libs etc? You have to extend your include paths in the pro file (look at the docu, how to do it).The second error is a linker error i suppose. You do not link to the qwebdav dll. How to do it, depends on the tool chain. On windows, it's:
MSVS tool chain:
@
LIBS += qwebdav.lib
@mingw tool chain:
@
LIBS += -lqwebdav
LIBS += -L<path to webdav .a file>
@ -
It is ubuntu 10.10, but I think I upgrade to 11.04, because I have heard that it has integrated Qt support.
The source files are in a subfolder under home, I made the build and install here, but I didn't specify target folders, everything went automatically.
Now I am trying to find out what the installer (make install) did do.
-
on linux, if you use gcc, it's the same parameters as mingw
-
I use the IDE named "qt creator", I think it uses qmake. (that uses gcc...?)
-
QtCreator is the IDE.
It uses a tool chain on your PC.
On Linux, that is typically gcc. -
I think I managed to solve the problem. :-)
I have copied from here:
@desktop/qwebdav/src/@
to here:
@/usr/include/qt4/QTWebDAV@
the following header files:
@webdav.h
webdav_export.h
webdav_url_info.h@
and the information (?) files:
@QWebdav (QtCreator looks for this file when compiling <QWebdav>)
QWebdavUrlInfos@Now it compiles without errors.
No adding or copying of the library was needed, maybe later...I am a beginner in Qt and linux, thanx for all the help and suggessions, it helped me a lot.
-
@#include <xxxx.h>@
is only searched in standard inlcude paths (those which are added with -I to the compiler options), whereas@#include "xxxx.h"@
is searched in standard include paths and local directories too.See older thread "Include Files":http://developer.qt.nokia.com/forums/viewthread/3051 for discussion.
-
Sorry.
Copying the compiled qwebdav lib files to usr/lib, and adding the line
@unix|win32: LIBS += -lqwebdav@
was also needed.Last time I did the same, but after deleting and removing them, qt compiled successfully again.
-
Ahhh...
I reinstalled linux (deleted Ubuntu and installed Debian).
Installed all the needed packages, and made the automated qwebdav make/install.
Qt Creator didn't find <QWebdav>I made all the needed install steps, but Qt Creator still cannot find <QWebdav>.
I placed the apropriate header and info files to the proper folders. (as I described before)