Last active
April 29, 2020 05:23
-
-
Save bitbd83/379c922c7c6c03a3418c4237d0994c6c to your computer and use it in GitHub Desktop.
BDB cross-compile script for mingw32 to make build for windows.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
MXE_PATH=/mnt/mxe | |
sed -i "s/WinIoCtl.h/winioctl.h/g" src/dbinc/win_db.h | |
mkdir build_mxe | |
cd build_mxe | |
CC=$MXE_PATH/usr/bin/i686-w64-mingw32.static-gcc \ | |
CXX=$MXE_PATH/usr/bin/i686-w64-mingw32.static-g++ \ | |
../dist/configure \ | |
--disable-replication \ | |
--enable-mingw \ | |
--enable-cxx \ | |
--host x86 \ | |
--prefix=$MXE_PATH/usr/i686-w64-mingw32.static | |
make | |
make install | |
#download bdb https://mega.nz/file/8zwHiDTI#0wck67T5fKdrV2AHQI72_CXvbQRl1_xV9surxJwduQY | |
-------------- | |
leveldb | |
TARGET_OS=NATIVE_WINDOWS make -j4 CC=i686-w64-mingw32.static-gcc CXX=i686-w64-mingw32.static-g++ libleveldb.a libmemenv.a |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment