Using user created libraries in a project



  • Hi,
    Created a sample library project using project1, Created project1 library is added into project2 using "add library" functionality and deployed in android mobile. But program is getting crashed.
    Is there any special method to adding libraries for android environment.


  • Lifetime Qt Champion

    Hi,

    "crashed" is a bit vague. How did it crash ? Was the library not found or do you have a bug in it ?



  • In project2, i created LIB folder and placed libproject1.so, added into .pro file using add external library.
    When it is running in android its unable to find lib path i think.
    For same process in other OS with Linux i used to place my libraries in /usr/lib/.
    Where should it be placed in Android. Is it part of .APK file?


  • Lifetime Qt Champion

    It should be part of the APK.

    Since it's a project specific library, you should rather put in some place fixed in the build folder rather than on your system. It would simplify development and debugging.

    For android, the library needs to be part of the package. If it's not detected automatically for you, you'll have to add it by hand. Go in the Project panel to modify the configuration as needed.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.