docker build -t bdb_tools - < Dockerfile
export container=$(docker run -d --rm bdb_tools sleep infinity)
docker cp $container:/out/bdb_tools/bdb_tools.zip ./
docker stop $container
Now you can use all the bdb tools in windows. <3
docker build -t bdb_tools - < Dockerfile
export container=$(docker run -d --rm bdb_tools sleep infinity)
docker cp $container:/out/bdb_tools/bdb_tools.zip ./
docker stop $container
Now you can use all the bdb tools in windows. <3
FROM ubuntu:22.04 | |
WORKDIR /build | |
# Update build system | |
RUN apt-get update && \ | |
apt-get install -y mingw-w64 gcc-mingw-w64 curl libtool build-essential zip | |
# Build bdb | |
RUN curl -L -O http://depends.dogecoincore.org/db-5.3.28.NC.tar.gz && \ | |
echo "76a25560d9e52a198d37a31440fd07632b5f1f8f9f2b6d5438f4bc3e7c9013ef db-5.3.28.NC.tar.gz" |sha256sum -c && \ | |
tar xf db-5.3.28.NC.tar.gz && \ | |
cd db-5.3.28.NC && \ | |
sed -i.old 's/WinIoCtl\.h/winioctl\.h/g' src/dbinc/win_db.h && \ | |
./dist/configure --host=x86_64-w64-mingw32 --disable-shared --disable-replication \ | |
--enable-mingw CC=x86_64-w64-mingw32-gcc AR=x86_64-w64-mingw32-ar \ | |
CFLAGS="-O2" && \ | |
make && \ | |
mkdir -p /out && \ | |
make DESTDIR=/out install | |
# build the archive | |
WORKDIR /out | |
RUN mkdir -p bdb_tools && \ | |
cd bdb_tools && \ | |
cp ../usr/local/BerkeleyDB.5.3/bin/*.exe ./ && \ | |
cp /usr/x86_64-w64-mingw32/lib/libwinpthread-1.dll ./ && \ | |
zip bdb_tools.zip * |