简体   繁体   中英

How to install BerkeleyDB for Mingw Linux compile environment

I'm trying to cross-compile an application on Linux using Mingw and am running into the following error message:

db.h:14:20: fatal error: db_cxx.h: No such file or directory

I understand that this is caused by the Berkeley-DB include files not being present under the Mingw include tree.

My question is: how can I take the Berkeley-DB source files and install them under the Mingw include file tree?

(I'm aware this is an old question - but people might still be searching for a solution to this)

Running Debian 7.6 (wheezy), I checked the file /usr/include/db_cxx.h with the command: dpkg -S /usr/include/db_cxx.h

This gave the following response:

libdb5.1++-dev: /usr/include/db_cxx.h

Then the error message in the question could be fixed by:

sudo apt-get install libdb5.1++-dev

In order to build db-4.8.30.NC with mingw 4.9.2 32bit try this:

../dist/configure --disable-replication --enable-mingw --enable-cxx --prefix=/mingw
make
make install

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM