在 Windows 上使用 SQLite 和 C

在 Windows 上使用 SQLite 和 C

问题描述:

我正在尝试在 Windows Vista 上使用 SQLite 进行数据存储,以 C 语言(在 Dev-Cpp IDE 上)开发一个项目.我正在尝试运行此代码:Sqlite与 C

I am trying to develop a project in C (on Dev-Cpp IDE) using SQLite for data storage, on Windows Vista. I am trying to run this code : Sqlite with C

我将 sqlite3.h 移动到/lib 路径中.但是当我尝试运行该程序时,我收到很多链接器错误,说未定义对 sqlite3_open 的引用"等.

I moved sqlite3.h in the /lib path. But when I am trying to run the program, I get lots of linker errors, saying "undefined reference to sqlite3_open" ,etc.

Google 给了我 Linux 命令,这里不能使用 :( 请有人指导我使用 C 语言使用 sqlite 的整个过程,我对这些东西很陌生.我把 sqlite3.exe 放在哪里??

Google gives me Linux commands, which cant be used here :( Can somone please guide me through the whole process of using sqlite with C , I am very new to such things. Where do I put the sqlite3.exe ??

非常感谢!!

我终于通过以下方式找到了答案:http://source.online.free.fr/Windows_HowToCompileSQLite

I finally figured out my answer through : http://source.online.free.fr/Windows_HowToCompileSQLite

上面的链接创建了一个必须放在/bin 中的 .dll 和一个必须作为选项传递给链接器的 .a 文件!

The above link creates a .dll which has to be put in the /bin, and one .a file which has to be passed as an option to the linker !

谢谢大卫!!