0

我是 QT 编程新手

这就是我所做的,我将照片从 photoshop 导出到 QT,然后创建新的 QT QUICK PROJECT ( ANDROID ) 并打开我之前从 photoshop 导出的 QT DESIGNER FILE

通过 ministro 运行,但我的这个错误发生了

> 
Starting remote process ...
D/dalvikvm( 2148): Not late-enabling CheckJNI (already on)
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
D/dalvikvm( 2148): GC_FOR_ALLOC freed 45K, 3% free 9074K/9347K, paused 133ms
I/dalvikvm-heap( 2148): Grow heap (frag case) to 10.393MB for 1536016-byte allocation
I/dalvikvm( 2148): threadid=3: reacting to signal 3
D/dalvikvm( 2148): GC_CONCURRENT freed <1K, 3% free 10573K/10887K, paused 6ms+134ms
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
D/dalvikvm( 2148): GC_FOR_ALLOC freed 0K, 3% free 10573K/10887K, paused 49ms
I/dalvikvm-heap( 2148): Grow heap (frag case) to 13.688MB for 3456016-byte allocation
I/dalvikvm( 2148): threadid=3: reacting to signal 3
D/dalvikvm( 2148): GC_CONCURRENT freed 0K, 3% free 13948K/14279K, paused 8ms+7ms
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
D/gralloc_goldfish( 2148): Emulator without GPU emulation detected.
I/dalvikvm( 2148): threadid=3: reacting to signal 3
I/dalvikvm( 2148): Wrote stack traces to '/data/anr/traces.txt'
D/dalvikvm( 2148): DexOpt: --- BEGIN 'QtIndustrius-14.jar' (bootstrap=0) ---
D/dalvikvm( 2148): DexOpt: --- END 'QtIndustrius-14.jar' (success) ---
D/dalvikvm( 2148): DEX prep '/data/data/org.kde.necessitas.ministro/files/qt/jar/QtIndustrius-14.jar': unzip in 159ms, rewrite 749ms
D/dalvikvm( 2148): Trying to load lib /data/data/org.kde.necessitas.ministro/files/qt/lib/libQtCore.so 0x412a98f0
D/dalvikvm( 2148): Added shared lib /data/data/org.kde.necessitas.ministro/files/qt/lib/libQtCore.so 0x412a98f0
D/dalvikvm( 2148): No JNI_OnLoad found in /data/data/org.kde.necessitas.ministro/files/qt/lib/libQtCore.so 0x412a98f0, skipping init
D/dalvikvm( 2148): Trying to load lib /data/data/org.kde.necessitas.ministro/files/qt/lib/libQtGui.so 0x412a98f0
D/dalvikvm( 2148): Added shared lib /data/data/org.kde.necessitas.ministro/files/qt/lib/libQtGui.so 0x412a98f0
D/dalvikvm( 2148): No JNI_OnLoad found in /data/data/org.kde.necessitas.ministro/files/qt/lib/libQtGui.so 0x412a98f0, skipping init
D/dalvikvm( 2148): Trying to load lib /data/data/org.kde.necessitas.ministro/files/qt/plugins/platforms/android/libandroid-9.so 0x412a98f0
D/dalvikvm( 2148): Added shared lib /data/data/org.kde.necessitas.ministro/files/qt/plugins/platforms/android/libandroid-9.so 0x412a98f0
I/Qt ( 2148): qt start
D/dalvikvm( 2148): Trying to load lib /data/data/org.kde.necessitas.example.HOME/lib/libHOME.so 0x412a98f0
W/System.err( 2148): java.lang.reflect.InvocationTargetException
W/System.err( 2148): at java.lang.reflect.Method.invokeNative(Native Method)
W/System.err( 2148): at java.lang.reflect.Method.invoke(Method.java:511)
W/System.err( 2148): at org.kde.necessitas.origo.QtActivity.loadApplication(QtActivity.java:144)
W/System.err( 2148): at org.kde.necessitas.origo.QtActivity.access$200(QtActivity.java:77)
W/System.err( 2148): at org.kde.necessitas.origo.QtActivity$3$1$1.run(QtActivity.java:201)
W/System.err( 2148): at android.os.Handler.handleCallback(Handler.java:605)
W/System.err( 2148): at android.os.Handler.dispatchMessage(Handler.java:92)
W/System.err( 2148): at android.os.Looper.loop(Looper.java:137)
W/System.err( 2148): at android.app.ActivityThread.main(ActivityThread.java:4424)
W/System.err( 2148): at java.lang.reflect.Method.invokeNative(Native Method)
W/System.err( 2148): at java.lang.reflect.Method.invoke(Method.java:511)
W/System.err( 2148): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784)
W/System.err( 2148): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551)
W/System.err( 2148): at dalvik.system.NativeStart.main(Native Method)
W/System.err( 2148): Caused by: java.lang.UnsatisfiedLinkError: Cannot load library: link_image[1936]: 36 could not load needed library 'libQtDeclarative.so' for 'libHOME.so' (load_library[1091]: Library 'libQtDeclarative.so' not found)
W/System.err( 2148): at java.lang.Runtime.load(Runtime.java:340)
W/System.err( 2148): at java.lang.System.load(System.java:521)
W/System.err( 2148): at org.kde.necessitas.industrius.QtNative.loadBundledLibraries(QtNative.java:125)
W/System.err( 2148): at org.kde.necessitas.industrius.QtActivityDelegate.loadApplication(QtActivityDelegate.java:245)
W/System.err( 2148): ... 14 more
> Blockquote

我认为是因为这个

36 无法为“libHOME.so”加载所需的库“libQtDeclarative.so”(load_library[1091]:未找到库“libQtDeclarative.so”)

我使用 ARMV5 安卓模拟器

请有人帮助我。谢谢!

4

1 回答 1

1

几个问题:您是否在 Necessitas 中选择了 Qt Quick Application?查看输出,似乎它没有将声明性模块与应用程序打包在一起。

您可以尝试进入运行设置选项卡,扩展下拉菜单并导航到包区域。确保包含 QDeclarative。默认情况下它应该这样做,但是在不确切知道它是如何设置的情况下,很难猜测它为什么会这样做。

关键点,在运行设置的“包配置”区域,您将看到一个名为库的选项卡。确保包含 QDeclarative。

此外,请确保在 .pro 文件中声明了声明性模块

希望这可以帮助

于 2012-08-24T03:23:41.903 回答