【发布时间】:2016-02-17 14:02:47
【问题描述】:
我从我们公司的一位前雇员那里得到了一个项目。
这是一个用 Delphi XE7 编写的 Android 应用程序,使用 Android SDK 19 (4.4) 和 Sqlite3 作为智能手机上的本地数据库。
目前我们在智能手机上有一个工作副本,但我无法在我的电脑上编译/构建它。而且我们需要一个新版本,因为我们公司的逻辑需要改变一些事情。
我总是收到这个致命错误:
"[DCC Fatal Error] Linker error code: 1 ($00000001)"
在这个致命错误之前,我还有一百多个其他错误,看起来都差不多:
[DCC Error] C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\toolchains\arm-linux-androideabi-4.6\prebuilt\windows\bin\arm-linux-androideabi-ld.exe: error: c:\\\\program files (x86)\\\\embarcadero\\\\studio\\\\15.0\\\\lib\\\\Android\\\\Release/libsqlite.a(sqlite3.o): multiple definition of 'sqlite3_aggregate_context'
只有这个错误的最后两个词总是不同的,所以我假设这是 sqlite3 中所有不同的类。
我尝试了很多东西,从在 Xe7、XE8、XE10 中尝试,SDK 管理器中的不同设置,...
我创建了新项目并将文件带到了这个新项目中,但我总是遇到同样的错误。
我的 SDK 管理器设置是:
SDK:
Base Path: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\adt-bundle-windows-x86-20131030\sdk
ZipAlign: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\adt-bundle-windows-x86-20131030\sdk\tools\ZipAlign.exe
Android Location: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\adt-bundle-windows-x86-20131030\sdk\tools\Android.bat
Adb Location: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\adt-bundle-windows-x86-20131030\sdk\platform-tools\Adb.exe
Aapt location: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\adt-bundle-windows-x86-20131030\sdk\build-tools\android-4.4\Aapt.exeµ
SDK Api-level locationC:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\adt-bundle-windows-x86-20131030\sdk\platforms\android-19
NDK:
Base Path: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c
arm-linux-androideabi-ld.exe location: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\toolchains\arm-linux-androideabi-4.6\prebuilt\windows\bin\arm-linux-androideabi-ld.exe
arm-linux-androideabi-strip.exe location: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\toolchains\arm-linux-androideabi-4.6\prebuilt\windows\bin\arm-linux-androideabi-strip.exe
gdbserver location: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\prebuilt\android-arm\gdbserver\gdbserver
NDK Api Location: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\platforms\android-14
C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\platforms\android-14\arch-arm\usr\lib
Delphi NDK Library Path: C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\platforms\android-14\arch-arm\usr\lib;C:\Users\Public\Documents\Embarcadero\Studio\15.0\PlatformSDKs\android-ndk-r9c\sources\cxx-stl\gnu-libstdc++\4.8\libs\armeabi-v7a
Java:
KeyTool Location: C:\Program Files\Java\jdk1.7.0_25\bin\KeyTool.exe
Jarsigner Location: C:\Program Files\Java\jdk1.7.0_25\bin\JarSigner.exe
谁能给我一个线索或可能的解决方案。
提前谢谢蒂莫西
【问题讨论】:
-
如果您阻止所有 SQLite 代码,(模拟它以给出所有固定答案),并删除所有 SQLite 痕迹 - 它可以编译吗? (我不在乎它是否有效,只要编译)。另一个问题:你可以在小项目中创建 SQLite 代码吗?
-
@FabricioAraujo 感谢您的意见。我都试过了。首先,我从我的应用程序开始。我删除了所有 sql'lish.. 我删除的最后一件事是 SQLiteUniProvider。从我这样做的那一刻起,错误消息在编译/构建时消失了。然后我保存它并开始把东西放回去。从提供者回来的那一刻起,麻烦又回来了......我还做了一个非常小的应用程序来测试 Sqlite,这就像一个魅力......你有什么其他要搜索的想法?
标签: android delphi sqlite android-ndk delphi-xe7