View Single Post
Posts: 111 | Thanked: 339 times | Joined on Jul 2011
Could you help me out a bit.

I made a helloworld project with SFOS Qt Creator and I did the following:

- i extracted files from libopenldap-devel-2.4.40-10.7.2.jolla.armv7hl.rpm
- copied files lib*.a and lib*.la from libopenldap-devel to lib directory under the helloworld qt project
- copied files *.h from libopenldap-devel to include directory under the dummy qt project

I added to project .pro file:
INCLUDEPATH += include
DEPENDPATH += include
LIBS += -Llib -llber -lldap

I added to the project cpp file:
#include <ldap.h>
#include <lber.h>

and in the main {} i added:

LDAP *ldap;

And compile gives me:

g++ -Wl,-O1 -Wl,-rpath,/usr/share/HelloWorld/lib -o HelloWorld HelloWorld.o -Llib -llber -lldap -pie -rdynamic -lsailfishapp -lmdeclarativecache5 -lQt5Quick -lQt5Gui -lQt5Qml -lQt5Network -lQt5Core -lGLESv2 -lpthread

RPM build errors:
/opt/cross/bin/armv7hl-meego-linux-gnueabi-ld: cannot find -llber
/opt/cross/bin/armv7hl-meego-linux-gnueabi-ld: cannot find -lldap
collect2: error: ld returned 1 exit status

That g++ command line does not look like there's any includes to my lib and include subdirectories. Any help appreciated.

The Following 2 Users Say Thank You to pexi For This Useful Post: