gpt4 book ai didi

sqlite - 使用 SQLite-WinRT 包装器构建问题

转载 作者:IT王子 更新时间:2023-10-29 06:22:48 25 4
gpt4 key购买 nike

在添加 SQLite-WinRT 数据库包装器后,我无法让我的应用程序为 ARM 目标构建。我可以用一个简单的测试应用重现这个,如下所示:

(这是在 Visual Studio 2013 中完成的。)

  1. 创建一个空的 Windows 8.1 通用应用 (WinRT)
  2. 下载 Windows Phone 8.1 的 SQLiteWindows 运行时 (Windows 8.1) 的 SQLite 使用 工具/扩展和更新。将它们添加到各自项目的引用文献中。
  3. 使用 NuGet,将 SQLite-WinRT 包添加到每个项目。
  4. 为 x86(本地机器或手机模拟器)构建 -> 没问题。
  5. 为 ARM(手机设备)构建 -> 构建错误如下所示(独立于调试或发布构建)。

There was a mismatch between the processor architecture of the project being built "ARM" and the processor architecture, "x86", of the implementation file "C:\Users\jr\Documents\Visual Studio 2015\Projects\sqlite-test\packages\Sqlite-Winrt.3.8.7.1\lib\wpa81\SQLiteWinRT.dll" for "C:\Users\jr\Documents\Visual Studio 2015\Projects\sqlite-test\packages\Sqlite-Winrt.3.8.7.1\lib\wpa81\SQLiteWinRT.winmd". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and implementation file, or choose a winmd file with an implementation file that has a processor architecture which matches the targeted processor architecture of your project.

我发布了一个小测试项目here (Windows Phone 8.1 空项目,添加 SQLite,通过 NuGet 添加 SQLite-WinRT)。

最佳答案

转到项目属性打开构建选项卡并将目标平台设置为 ARM enter image description here

编辑您已添加 WinRt sqlite。它是在 x86 上构建的,当你想在 ARM 进程架构上构建它时,它无法构建你需要删除 WinRTSQlite dll,你的项目才能正常工作。这是 Code

希望对你有帮助

关于sqlite - 使用 SQLite-WinRT 包装器构建问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32145931/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com