aboutsummaryrefslogtreecommitdiff
path: root/dev-db
diff options
context:
space:
mode:
authorAric Belsito <lluixhi@gmail.com>2017-06-17 15:45:38 -0700
committerAric Belsito <lluixhi@gmail.com>2017-06-17 15:45:38 -0700
commit24556f96e9eb89fc5554a4396a45c51532b7dc95 (patch)
treeb0d7fca4c06aad85636f80fd72d91ec49934a29d /dev-db
parentapp-admin/sudo: sync with upstream (diff)
downloadlibressl-24556f96e9eb89fc5554a4396a45c51532b7dc95.tar.gz
libressl-24556f96e9eb89fc5554a4396a45c51532b7dc95.tar.bz2
libressl-24556f96e9eb89fc5554a4396a45c51532b7dc95.zip
dev-db/sqlcipher: add most recent version
Thinks LibreSSL is OpenSSL 1.1.0+
Diffstat (limited to 'dev-db')
-rw-r--r--dev-db/sqlcipher/Manifest1
-rw-r--r--dev-db/sqlcipher/files/sqlcipher-3.4.1-libressl.patch12
-rw-r--r--dev-db/sqlcipher/metadata.xml11
-rw-r--r--dev-db/sqlcipher/sqlcipher-3.4.1.ebuild58
4 files changed, 82 insertions, 0 deletions
diff --git a/dev-db/sqlcipher/Manifest b/dev-db/sqlcipher/Manifest
new file mode 100644
index 0000000..94c6c17
--- /dev/null
+++ b/dev-db/sqlcipher/Manifest
@@ -0,0 +1 @@
+DIST sqlcipher-3.4.1.tar.gz 13873645 SHA256 4172cc6e5a79d36e178d36bd5cc467a938e08368952659bcd95eccbaf0fa4ad4 SHA512 1c08ccdf438c0de23b1293192c687cb869db1ea904c47da5643c69f3a21f3f6a801fe8e87eb2e660acf0fe977b1f05bf8801b79162c609ffa3711706392c642b WHIRLPOOL 4098712a08ff852521f649e9d3abbb1f5d7a4b4f58fe9cef5495ac75bf993a64ddd04ede6f46c2fbdd823b71315e165bf20d70018993192d2844dcc5ed76f037
diff --git a/dev-db/sqlcipher/files/sqlcipher-3.4.1-libressl.patch b/dev-db/sqlcipher/files/sqlcipher-3.4.1-libressl.patch
new file mode 100644
index 0000000..97824ff
--- /dev/null
+++ b/dev-db/sqlcipher/files/sqlcipher-3.4.1-libressl.patch
@@ -0,0 +1,12 @@
+diff -Naur sqlcipher-3.4.1.orig/src/crypto_openssl.c sqlcipher-3.4.1/src/crypto_openssl.c
+--- sqlcipher-3.4.1.orig/src/crypto_openssl.c 2016-12-28 09:39:09.000000000 -0800
++++ sqlcipher-3.4.1/src/crypto_openssl.c 2017-06-17 15:43:13.970281603 -0700
+@@ -46,7 +46,7 @@
+ static unsigned int openssl_init_count = 0;
+ static sqlite3_mutex* openssl_rand_mutex = NULL;
+
+-#if OPENSSL_VERSION_NUMBER < 0x10100000L
++#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
+ static HMAC_CTX *HMAC_CTX_new(void)
+ {
+ HMAC_CTX *ctx = OPENSSL_malloc(sizeof(*ctx));
diff --git a/dev-db/sqlcipher/metadata.xml b/dev-db/sqlcipher/metadata.xml
new file mode 100644
index 0000000..97d08da
--- /dev/null
+++ b/dev-db/sqlcipher/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>pinkbyte@gentoo.org</email>
+ <name>Sergey Popov</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">sqlcipher/sqlcipher</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-db/sqlcipher/sqlcipher-3.4.1.ebuild b/dev-db/sqlcipher/sqlcipher-3.4.1.ebuild
new file mode 100644
index 0000000..8a312b8
--- /dev/null
+++ b/dev-db/sqlcipher/sqlcipher-3.4.1.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+inherit autotools eutils flag-o-matic multilib-minimal
+
+DESCRIPTION="Full Database Encryption for SQLite"
+HOMEPAGE="https://www.zetetic.net/sqlcipher/"
+SRC_URI="https://github.com/sqlcipher/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+
+IUSE="readline libressl static-libs tcl test"
+
+# Tcl is always needed by buildsystem
+RDEPEND="
+ !libressl? ( dev-libs/openssl:0=[${MULTILIB_USEDEP}] )
+ libressl? ( dev-libs/libressl:0=[${MULTILIB_USEDEP}] )
+ readline? ( sys-libs/readline:0=[${MULTILIB_USEDEP}] )
+ tcl? ( dev-lang/tcl:=[${MULTILIB_USEDEP}] )
+"
+DEPEND="${RDEPEND}
+ dev-lang/tcl:*"
+
+# Testsuite requires compilation with TCL, bug #582584
+REQUIRED_USE="test? ( tcl )"
+
+PATCHES=( "${FILESDIR}"/${P}-libressl.patch )
+
+DOCS=( README.md )
+
+src_prepare() {
+ append-cflags -DSQLITE_HAS_CODEC
+
+ default
+ eautoreconf
+}
+
+multilib_src_configure() {
+ ECONF_SOURCE=${S} \
+ econf \
+ --enable-fts3 \
+ --enable-fts4 \
+ --enable-fts5 \
+ --enable-json1 \
+ --enable-tempstore \
+ $(use_enable readline) \
+ $(use_enable static-libs static) \
+ $(use_enable tcl)
+}
+
+multilib_src_install_all() {
+ prune_libtool_files
+ einstalldocs
+}