add package sqlcipher

This commit is contained in:
Boris Nagaev 2017-10-10 19:35:07 +11:00 committed by Tony Theodore
parent ede8628ec0
commit e766e79170
2 changed files with 64 additions and 0 deletions

View File

@ -0,0 +1,25 @@
This file is part of MXE. See LICENSE.md for licensing information.
Contains ad hoc patches for cross building.
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Your Name <you@example.com>
Date: Wed, 27 Sep 2017 15:26:44 +0000
Subject: [PATCH] fix dependency
Source:
https://github.com/Alexpux/MINGW-packages/blob/f083f27fb163b68673d5ac649fae353f44b49c7d/mingw-w64-sqlcipher/01-fix_dep.diff
diff --git a/Makefile.in b/Makefile.in
index 1111111..2222222 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1074,7 +1074,7 @@ FTS5_SRC = \
$(TOP)/ext/fts5/fts5_varint.c \
$(TOP)/ext/fts5/fts5_vocab.c \
-fts5parse.c: $(TOP)/ext/fts5/fts5parse.y lemon
+fts5parse.c: $(TOP)/ext/fts5/fts5parse.y lemon$(BEXE)
cp $(TOP)/ext/fts5/fts5parse.y .
rm -f fts5parse.h
./lemon$(BEXE) $(OPTS) fts5parse.y

39
src/sqlcipher.mk Normal file
View File

@ -0,0 +1,39 @@
# This file is part of MXE. See LICENSE.md for licensing information.
PKG := sqlcipher
$(PKG)_WEBSITE := https://www.zetetic.net/sqlcipher/
$(PKG)_DESCR := SQLite extension that provides 256 bit AES encryption of database files
$(PKG)_IGNORE :=
$(PKG)_VERSION := 3.4.1
$(PKG)_CHECKSUM := 4172cc6e5a79d36e178d36bd5cc467a938e08368952659bcd95eccbaf0fa4ad4
$(PKG)_GH_CONF := sqlcipher/sqlcipher, v
$(PKG)_DEPS := gcc openssl readline
define $(PKG)_BUILD
# build and install the library
cd '$(BUILD_DIR)' && $(SOURCE_DIR)/configure \
"LIBS=$$($(TARGET)-pkg-config --libs libcrypto)" \
"CFLAGS=-DSQLITE_HAS_CODEC" \
--enable-tempstore=yes \
--disable-tcl \
--disable-editline \
--enable-readline \
--with-readline \
$(MXE_CONFIGURE_OPTS)
$(MAKE) -C '$(BUILD_DIR)' -j '$(JOBS)'
$(MAKE) -C '$(BUILD_DIR)' -j 1 install $(MXE_DISABLE_CRUFT)
# # create pkg-config files
# $(INSTALL) -d '$(PREFIX)/$(TARGET)/lib/pkgconfig'
# (echo 'Name: $(PKG)'; \
# echo 'Version: $($(PKG)_VERSION)'; \
# echo 'Description: SQLite extension that provides 256 bit AES encryption of database files'; \
# echo 'Libs: -lsqlcipher';) \
# > '$(PREFIX)/$(TARGET)/lib/pkgconfig/$(PKG).pc'
#
# # compile test
# '$(TARGET)-gcc' \
# -W -Wall -Werror -ansi -pedantic \
# '$(TEST_FILE)' -o '$(PREFIX)/$(TARGET)/bin/test-$(PKG).exe' \
# `'$(TARGET)-pkg-config' $(PKG) --cflags --libs`
endef