Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
268 views
in Technique[技术] by (71.8m points)

android - Error in dropboxSync: findlibrary returned null

Error log:

03-25 09:46:59.022: I/com.dropbox.sync.android.CoreAccountManager(2217): Prepared cache dir '/data/data/com.company.testapp/app_DropboxSyncCache/my-dropxbox-key'.
03-25 09:46:59.022: W/dalvikvm(2217): Exception Ljava/lang/UnsatisfiedLinkError; thrown while initializing Lcom/dropbox/sync/android/NativeHttp;
03-25 09:46:59.022: W/dalvikvm(2217): Exception Ljava/lang/ExceptionInInitializerError; thrown while initializing Lcom/dropbox/sync/android/NativeLib;
03-25 09:46:59.034: D/Updater(2217): java.lang.ExceptionInInitializerError
03-25 09:46:59.034: D/Updater(2217):    at com.dropbox.sync.android.CoreAccountManager.initNativeLib(CoreAccountManager.java:107)
03-25 09:46:59.034: D/Updater(2217):    at com.dropbox.sync.android.CoreAccountManager.<init>(CoreAccountManager.java:87)
03-25 09:46:59.034: D/Updater(2217):    at com.dropbox.sync.android.DbxAccountManager.getInstance(DbxAccountManager.java:112)
03-25 09:46:59.034: D/Updater(2217):    at com.dropbox.sync.android.DbxAccountManager.getInstance(DbxAccountManager.java:99)
03-25 09:46:59.034: D/Updater(2217):    at com.company.testapp.ui.LoginActivity.notificationPosted(LoginActivity.java:1100)
03-25 09:46:59.034: D/Updater(2217):    at com.company.testapp.io.NotificationCenter.postNotification(NotificationCenter.java:79)
03-25 09:46:59.034: D/Updater(2217):    at com.company.testapp.io.Updater.processFinishedOperation(Updater.java:4044)
03-25 09:46:59.034: D/Updater(2217):    at com.company.testapp.io.Updater.operationSuccess(Updater.java:3115)
03-25 09:46:59.034: D/Updater(2217):    at com.company.testapp.io.Updater.access$5(Updater.java:3046)
03-25 09:46:59.034: D/Updater(2217):    at com.company.testapp.io.Updater$1.run(Updater.java:2999)
03-25 09:46:59.034: D/Updater(2217):    at android.os.Handler.handleCallback(Handler.java:615)
03-25 09:46:59.034: D/Updater(2217):    at android.os.Handler.dispatchMessage(Handler.java:92)
03-25 09:46:59.034: D/Updater(2217):    at android.os.Looper.loop(Looper.java:137)
03-25 09:46:59.034: D/Updater(2217):    at android.app.ActivityThread.main(ActivityThread.java:4745)
03-25 09:46:59.034: D/Updater(2217):    at java.lang.reflect.Method.invokeNative(Native Method)
03-25 09:46:59.034: D/Updater(2217):    at java.lang.reflect.Method.invoke(Method.java:511)
03-25 09:46:59.034: D/Updater(2217):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:786)
03-25 09:46:59.034: D/Updater(2217):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
03-25 09:46:59.034: D/Updater(2217):    at dalvik.system.NativeStart.main(Native Method)
03-25 09:46:59.034: D/Updater(2217): Caused by: java.lang.ExceptionInInitializerError
03-25 09:46:59.034: D/Updater(2217):    at com.dropbox.sync.android.NativeLib.<init>(NativeLib.java:33)
03-25 09:46:59.034: D/Updater(2217):    at com.dropbox.sync.android.NativeLib.<clinit>(NativeLib.java:11)
03-25 09:46:59.034: D/Updater(2217):    ... 19 more
03-25 09:46:59.034: D/Updater(2217): Caused by: java.lang.UnsatisfiedLinkError: Couldnt load DropboxSync: findLibrary returned null
03-25 09:46:59.034: D/Updater(2217):    at java.lang.Runtime.loadLibrary(Runtime.java:365)
03-25 09:46:59.034: D/Updater(2217):    at java.lang.System.loadLibrary(System.java:535)
03-25 09:46:59.034: D/Updater(2217):    at com.dropbox.sync.android.NativeHttp.<clinit>(NativeHttp.java:364)
03-25 09:46:59.034: D/Updater(2217):    ... 21 more

Call to the function:

DbxAccountManager mDbxAcctMgr = DbxAccountManager.getInstance(this.getApplicationContext(), Constants.DROPBOX_APP_KEY, Constants.DROPBOX_APP_SECRET); //error is here
toolbox.setmDbxAcctMgr(mDbxAcctMgr);

I got the library v13, dropboxsync-sdk in the project, and all the permissions and stuff on the manifest. Any idea about this?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

I got the problem. I didnt had the armeabi libraries. Adding it to the libs folder fixed my problem.

From d3mon 's answer: After adding .so to libs folder: right click on project -> Properties -> Java Build Path -> "Libraries" tab -> unfold "Android Private Libraries" and edit "Native Library Location". Point to your "libs" folder.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...