青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品

牽著老婆滿街逛

嚴(yán)以律己,寬以待人. 三思而后行.
GMail/GTalk: yanglinbo#google.com;
MSN/Email: tx7do#yahoo.com.cn;
QQ: 3 0 3 3 9 6 9 2 0 .

Accessing SQLite databases in C++ using SOCI

轉(zhuǎn)載自:http://jameswynn.com/2009/10/accessing-sqlite-databases-in-c-using-soci/

I recently decided to use SOCI and SQLite at work and found that neither there is not a super straight forward path for setting this up. As of SOCI version 3.0.0 there is no support for Visual Studio 2008, so I had to convert and fix a few bugs resulting from that. There were some path issues as well. Also they don't package the SQLite interface with SOCI so you have to checkout the repo to get access to it. After getting that there are still a few snags, not to mention actually setting up SQLite as a library.

[Updated: 10/13/2009]
After writing this article the SOCI team has resolved some of these issues, so some of these steps are no longer necessary.

Step 1: Setup SQLite

Step 1.1

Download the SQLite 3.6.18 source and library files.

Step 1.2:

Unarchive the SQLite archives into a directory, mine will be c:\usr\sqlite3

Step 1.3:

Create the sqlite3.lib file by using Visual Studio's lib command:

LIB /DEF:sqlite3.def


Step 2: Setup SOCI

Step 2.1:

Download the head of SOCI's git repository

Step 2.2:

Decompress the file into another directory, mine will be c:\usr\soci

Step 2.3:

Soci requires stdint.h but Visual Studio 2008 does not provide it, so simply download pstdint.h and rename it to stdint.h in the soci\src\core directory.

Step 2.4:

Open the directory soci\build and copy msvc80 to msvc90.

Now open the msvc90\dll directory.

Through Visual Studio 2008, open the soci_dll.sln file and allow it to convert it with the default parameters.

Step 2.5: Build SOCI's Core and SQLite3

SOCI's core project should build without errors, but the sqlite project will have several.

Step 2.6: Fixing Build Errors

Now SOCI's core project should build without errors, but the sqlite3 project will definitely fail. It will give two specific errors:

fatal error C1083: Cannot open include file: 'sqlite3.h': No such file or directory

and

error C3163: '_vsnprintf': attributes inconsistent with previous declaration

Both are relatively easy to fix.

Step 2.6.1: Fixing SQLite3 include paths

In Visual Studio, navigate to View->Property Manager, then in the pane that shows up, expand the sqlite3 project, then expand "Debug | Win32" then "soci_dll" then double-click on the "soci" object. Select "User Macros" on the sheet you find there.

Find SQLITE3_INCLUDE_DIR and SQLITE_LIB_DIR and change them to the directory created earlier, "c:\usr\sqlite3"

Step 2.6.2: Fixing _vsnprintf

[Update 10/13/2009]
This step is no longer needed.

Expand the core project and look for soci-platform.h and find a line that says "HAVE_VSNPRINTF"

This is redefining something that VS2008 provides already and confuses the hell out of the compiler. Just comment it out, or change it to look like:

// Define if you have the vsnprintf variants.
#if _MSC_VER < 1500
#    define HAVE_VSNPRINTF 
1
#    define vsnprintf _vsnprintf
#endif

Step 2.7 Building SOCI's sqlite3_test project

This project will be riddled with errors unless you have boost installed. I personally don't use it, so had to comment out large chunks of common-tests.h.  Specifically, comment out the area at the top where it includes the boost headers. Also comment out the contents of test26, test28 and test30.

Also add this line at the bottom of soci-platform.h:

#undef SOCI_USE_BOOST

 

Finished

Now you should have a working copy of SOCI 3.0.0 with SQLite3 support in Visual Studio 2008. Congratulations!


posted on 2009-11-27 13:47 楊粼波 閱讀(1645) 評(píng)論(0)  編輯 收藏 引用


只有注冊(cè)用戶登錄后才能發(fā)表評(píng)論。
網(wǎng)站導(dǎo)航: 博客園   IT新聞   BlogJava   博問(wèn)   Chat2DB   管理


青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品
  • <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            欧美女同视频| 亚洲开发第一视频在线播放| 美女免费视频一区| 韩国av一区| 欧美国产91| 亚洲午夜精品国产| 久久亚洲国产精品一区二区| 亚洲国产导航| 欧美日韩一区二区三区视频| 亚洲欧美激情诱惑| 亚洲日本免费电影| 欧美不卡激情三级在线观看| 亚洲精品国产精品国产自| 欧美激情aⅴ一区二区三区| aaa亚洲精品一二三区| 国产精品视频免费在线观看| 欧美在线999| 亚洲高清久久网| 在线亚洲观看| 亚洲风情在线资源站| 亚洲电影免费| 国产日韩一区| 欧美日韩一区二区免费视频| 国产精品igao视频网网址不卡日韩| 久久久久国产成人精品亚洲午夜| 亚洲精品午夜| 久久精品夜色噜噜亚洲a∨| 亚洲国产综合91精品麻豆| 欧美日韩国产成人| 噜噜噜噜噜久久久久久91| 亚洲欧美日韩中文播放| 亚洲精品视频二区| 亚洲愉拍自拍另类高清精品| 亚洲精品无人区| 亚洲男人av电影| 免费观看成人| 亚洲日本成人网| 欧美在线观看视频一区二区| 欧美不卡在线视频| 国产视频一区在线观看| 夜夜嗨av一区二区三区| 久久深夜福利免费观看| 亚洲一区二区免费视频| 亚洲黄色成人| 亚洲欧美日韩另类精品一区二区三区| 亚洲高清中文字幕| 午夜亚洲激情| 久久精品日产第一区二区| 久久gogo国模裸体人体| 亚洲欧美日韩视频一区| 欧美高清在线一区| 亚洲国产高清自拍| 亚洲主播在线观看| 亚洲高清视频一区| 欧美在线一区二区| 国产精品久久二区| 久久综合成人精品亚洲另类欧美 | 欧美日韩精品免费观看视频| 国产美女精品免费电影| 国产丝袜一区二区| 午夜在线a亚洲v天堂网2018| 性欧美videos另类喷潮| 亚洲国产美国国产综合一区二区 | 欧美在线视频在线播放完整版免费观看| 欧美精品在线观看播放| 亚洲高清色综合| 久久亚洲一区二区| 久久久久久噜噜噜久久久精品| 男女视频一区二区| 亚洲激情影院| 欧美亚洲在线视频| 欧美www视频在线观看| 一区二区三区在线视频播放| 中国成人亚色综合网站| 久久久久成人精品| 久久不射电影网| 欧美视频你懂的| 国产偷国产偷亚洲高清97cao| 亚洲一区在线播放| 欧美mv日韩mv国产网站| 久久久精品国产免大香伊| 免费看精品久久片| 国产精品扒开腿做爽爽爽软件| 在线亚洲美日韩| 亚洲午夜一级| 国产亚洲欧美日韩美女| 99精品99久久久久久宅男| 欧美一区二区视频在线观看2020| 久久这里只有| 久久亚洲国产成人| 国产精品一级在线| 久久久国产精品亚洲一区 | 国内精品久久久久久久影视蜜臀 | 99热免费精品在线观看| 午夜精品理论片| 一区二区三区在线免费观看| 亚洲国内在线| 国产精品一卡| 亚洲国产美女| 国产精品三级视频| 欧美成人精品福利| 国产精品久久久久一区二区三区共| 亚洲人成网站999久久久综合| 国产麻豆视频精品| 久久婷婷亚洲| 欧美精品一区在线| 欧美中文在线观看| 欧美激情一区二区久久久| 尤物九九久久国产精品的分类| 亚洲综合首页| 欧美一区在线视频| 一区二区三区久久| 久久国产综合精品| 亚洲天堂视频在线观看| 久久精品国产77777蜜臀| 亚洲天堂av电影| 久久综合久久美利坚合众国| 亚洲视频香蕉人妖| 蜜臀a∨国产成人精品| 亚洲欧美日本国产有色| 鲁大师成人一区二区三区| 香蕉久久国产| 欧美日韩久久不卡| 亚洲国产精品福利| 在线观看视频一区二区| 亚洲性视频网址| 亚洲一本大道在线| 欧美多人爱爱视频网站| 久久综合狠狠| 国产一区自拍视频| 亚洲欧美日韩视频二区| 亚洲午夜精品视频| 欧美精品一卡| 亚洲激情网站| 最新国产の精品合集bt伙计| 香蕉久久夜色精品| 在线看日韩欧美| 亚洲欧美一区二区三区在线| 一区二区动漫| 欧美日韩伊人| 亚洲美女少妇无套啪啪呻吟| 国产精品v亚洲精品v日韩精品| 欧美激情1区2区| 亚洲精品黄色| 亚洲永久在线| 欧美一级免费视频| 国产亚洲a∨片在线观看| 亚洲午夜精品| 久久久999精品免费| 韩日欧美一区| 久久夜色精品国产亚洲aⅴ| 麻豆精品网站| 国产精品国产三级国产a| 91久久国产综合久久| 亚洲国产日韩精品| 欧美国产在线视频| 亚洲精品四区| 欧美在线观看一区| 韩国三级电影一区二区| 欧美成人性网| 在线一区亚洲| 亚洲精品美女久久7777777| 欧美国产日韩二区| 一区二区高清在线观看| 亚洲高清精品中出| 欧美激情四色 | 亚洲大片免费看| 亚洲精品久久久久久久久久久久| 欧美精品少妇一区二区三区| 亚洲欧美成人一区二区三区| 亚洲电影自拍| 欧美人体xx| 欧美在线视频免费| 亚洲国产日韩在线一区模特| 正在播放欧美一区| 国产一区二区三区丝袜| 欧美激情国产日韩| 午夜免费久久久久| 亚洲国产经典视频| 先锋亚洲精品| 亚洲欧洲一区二区在线播放| 国产精品va在线播放我和闺蜜| 久久精品在线免费观看| 亚洲毛片播放| 欧美99久久| 久久国产一区二区| 一区二区黄色| 国产自产v一区二区三区c| 美女黄色成人网| 性一交一乱一区二区洋洋av| 亚洲国产高清在线观看视频| 久久久久综合网| 性8sex亚洲区入口| 亚洲精品中文字| 在线精品国产欧美| 国产一区二区在线免费观看| 欧美极品影院| 免费日韩一区二区| 久久久91精品国产| 亚洲欧美中文日韩在线|