Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
Posts: 1,746
Registered: ‎04-08-2010
My Device: Passport Silver, PRIV
My Carrier: Telekom.de, O2, Vodafone
Accepted Solution

include from library project

hi,

please excuse if this is a stupid question, but all the C++ stuff is really new for my as experiences java developer.

 

I have created a C++ BB Library project mylibproject

with a public folder inside

then I copied into the public folder of this project: my_lib_test.h

 

then I have another normal C++ BB project mytestproject

ricght-click-configure-add-library: added the public folder of mylibproject

 

then in my main.cpp I included

#include <my_lib_test.h>

 

and inside main() {} I could use the library, with content-assist and Open declaration jumps inside my_lib_test.h

 

so all seems to work

 

then selected both projects and -> Build Project...

 

all compiles without an error, but I'm getting an error:

 

/Developer/SDKs/bbndk-10.0.4-beta/host/macosx/x86/usr/bin/ntoarm-ld: cannot find -lmylibproject

 

any idea what could be wrong ?

mytestproject has a project reference to mylibproject

 

thx

 

-------------------------------------------------------------------------------
ekke (independent software architect, rosenheim, germany)

BlackBerry Elite Developer
BlackBerry Platinum Enterprise Partner
International Development native Mobile Business Apps
BlackBerry 10 | Qt Mobile (Android, iOS)
Workshops / Trainings / Bootcamps

blog: http://ekkes-corner.org
mobile-development: http://appbus.org Twitter: @ekkescorner
New Developer
Posts: 21
Registered: ‎05-04-2012
My Device: Playbook
My Carrier: Vodaphone

Re: include from library project

Im not 100% sure,but you might need to compile the library to include it, see what happens when you do

Developer
Posts: 1,746
Registered: ‎04-08-2010
My Device: Passport Silver, PRIV
My Carrier: Telekom.de, O2, Vodafone

Re: include from library project

thx - already done it: built library and  normal project

-------------------------------------------------------------------------------
ekke (independent software architect, rosenheim, germany)

BlackBerry Elite Developer
BlackBerry Platinum Enterprise Partner
International Development native Mobile Business Apps
BlackBerry 10 | Qt Mobile (Android, iOS)
Workshops / Trainings / Bootcamps

blog: http://ekkes-corner.org
mobile-development: http://appbus.org Twitter: @ekkescorner
Developer
Posts: 1,746
Registered: ‎04-08-2010
My Device: Passport Silver, PRIV
My Carrier: Telekom.de, O2, Vodafone

Re: include from library project

uuups .... was my fault

 

inside my library project there were 2 src folders:

/src

/public

 

/src was empty and /public contains xxx.h

 

creating a dummi class inside /src fixed it - now the library was recognized.

 

...many lessons to learn in new environments ;-)

-------------------------------------------------------------------------------
ekke (independent software architect, rosenheim, germany)

BlackBerry Elite Developer
BlackBerry Platinum Enterprise Partner
International Development native Mobile Business Apps
BlackBerry 10 | Qt Mobile (Android, iOS)
Workshops / Trainings / Bootcamps

blog: http://ekkes-corner.org
mobile-development: http://appbus.org Twitter: @ekkescorner