适用于C ++的Mac OSX sqlite API [英] Mac OSX sqlite api for C++

查看:105
本文介绍了适用于C ++的Mac OSX sqlite API的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在Mac上移植C#程序,并且我正在执行的组件具有操作数据库的功能.添加删除/更新记录等. 在原始程序中,有一个s3db文件,该文件已发货,并且该程序使用System.Data.SQLite.dll与数据库进行交互.

I am porting a C# program on mac and the component I am doing has the feature to manipulate database. adding removing / updating records etc. In the original program there is a s3db file that gets shipped and the program uses System.Data.SQLite.dll to interact with database.

由于我正在研究macox,并且对它还很陌生,所以所有后端都是用C/C ++编写的,所以我不确定mac可以为sqllite提供什么功能,

Since I am working on macox and I am pretty new to it, all the back end is being written in C/C++ I am not sure what mac has to offer for sqllite,

所以我的问题是: Mac的sqlite支持API是否有构建?还是我需要使用单独的sqlite C/C ++ lib或mac已经提供了我可以使用的功能? 可以在Mac OS X上发布s3db还是可以在Mac中创建数据库的任何现有内置方式?

So my question is: Is there a build in support api in mac for sqlite ? or Do I need to use a separate sqlite C/C++ lib or mac already gives something that I can use ? Is it ok to ship s3db on mac osx or any existing built in way to create dbs in mac?

谢谢

推荐答案

Mac OS X附带了sqlite 3:

Mac OS X comes with sqlite 3:

$ ls -l /usr/lib/*sqlite*
lrwxr-xr-x  1 root  wheel       16 Aug 25 10:22 /usr/lib/libsqlite3.0.dylib@ -> libsqlite3.dylib
-rwxr-xr-x  1 root  wheel  2216304 Sep 18 19:16 /usr/lib/libsqlite3.dylib*
lrwxr-xr-x  1 root  wheel       27 Aug 25 10:29 /usr/lib/sqlite3@ -> /System/Library/Tcl/sqlite3


$ ls -l /usr/include/*sqlite*
-rw-r--r--  1 root  wheel  336911 Oct 23 10:24 /usr/include/sqlite3.h
-rw-r--r--  1 root  wheel   24158 Oct 23 10:24 /usr/include/sqlite3ext.h

这篇关于适用于C ++的Mac OSX sqlite API的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆