summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-crypt/coolkey')
-rw-r--r--app-crypt/coolkey/Manifest1
-rw-r--r--app-crypt/coolkey/coolkey-1.1.0-r7.ebuild81
2 files changed, 82 insertions, 0 deletions
diff --git a/app-crypt/coolkey/Manifest b/app-crypt/coolkey/Manifest
index 41cc6c66ddf7..9fa753c3e28e 100644
--- a/app-crypt/coolkey/Manifest
+++ b/app-crypt/coolkey/Manifest
@@ -1,2 +1,3 @@
DIST coolkey-1.1.0-patches-002.tar.gz 20574 SHA256 42767673025f7410bc1169231f7759abe4de69d8fa204fc8acfbe228b543129a SHA512 94050979f04f24924331b8a7c38b60de207d32b964caa39714aefd9f616ab7dd4e58b51e2c49fdb63b4dec1acce0c7245ae0a025ef76d457162b7200193dc663 WHIRLPOOL 55fee8ff261b8b3b8e16af05c1a6e7b4acd8eacaa0c73f5dd7bdf4918929097918be0f1ec2feaa5385d991d2a472672c7306dee60f4d61d313b2c47ec691f66a
+DIST coolkey-1.1.0-patches-003.tar.gz 21263 SHA256 af04f104a2ababe5b4cc7cd9e870918c24b2baa2599ddfe7a8eb0114b63428e0 SHA512 25a5fac68ca041fcf9e927d134d0179fa286e6de75019e7bbf205edeaf73222d9fb9fd3861a8f6e0d933d1a09229e3e727278c3a9b3cc63390ef07774c46390d WHIRLPOOL c272e01c61ec66c2f06b75370ffca33c067b0fbfea16284b8696484dd80b161ec86688a9b4af5ae433e9582ebc914bc10ee4d387dc920e989a93b514ce881746
DIST coolkey-1.1.0.tar.gz 432808 SHA256 8448e3abb81bffc593c96b577dcfbc05b40e8684188456c31be15fae73d730f7 SHA512 4b61de9b40abcf620fbb519d5e3cf1e93ebdd0470854cb63a597fc91e0182998217353014327f7bc4f255d22515d8ea2b08d36b3a831f5f09134fdcd418bc08b WHIRLPOOL 60408f606a5cf5d9ec1ba3938a96a6f938c8d9f4b7ace2677ff35ce125104995675bf0decae92575e82dfc1a2eeaa26c4197ad174a4d3901250c43d906976c24
diff --git a/app-crypt/coolkey/coolkey-1.1.0-r7.ebuild b/app-crypt/coolkey/coolkey-1.1.0-r7.ebuild
new file mode 100644
index 000000000000..66640df4e55d
--- /dev/null
+++ b/app-crypt/coolkey/coolkey-1.1.0-r7.ebuild
@@ -0,0 +1,81 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=6
+
+inherit eutils
+
+PATCHVER="003"
+
+DESCRIPTION="Linux Driver support for the CoolKey and CAC products"
+HOMEPAGE="https://directory.fedora.redhat.com/wiki/CoolKey"
+SRC_URI="https://directory.fedora.redhat.com/download/coolkey/${P}.tar.gz
+ mirror://gentoo/${P}-patches-${PATCHVER}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~sparc ~x86"
+IUSE="debug"
+
+RDEPEND=">=sys-apps/pcsc-lite-1.6.4
+ dev-libs/nss[utils]
+ sys-libs/zlib"
+
+DEPEND="${RDEPEND}
+ >=app-crypt/ccid-1.4.0
+ virtual/pkgconfig"
+
+PATCHES=(
+ "${WORKDIR}/${PN}-patches"
+)
+
+pkg_setup() {
+ pk="pk11install"
+ dbdir="/etc/pki/nssdb"
+ ck_mod_name="CoolKey PKCS #11 Module"
+
+ if ! [[ -x $dbdir ]]; then
+ ewarn "No /etc/pki/nssdb found; check under \$HOME/.pki and"
+ ewarn "follow the suggested commands using the correct path."
+ fi
+}
+
+src_configure() {
+ econf \
+ --enable-pk11install \
+ $(use_enable debug)
+}
+
+src_compile() {
+ emake CFLAGS+="-fno-strict-aliasing" -j1
+}
+
+pkg_postinst() {
+ if [[ -x $dbdir ]]; then
+ if ! $(modutil -rawlist -dbdir $dbdir | grep libcoolkeypk11); then
+ elog "You still need to install libcoolkey in your PKCS11 library:"
+ elog "$pk -p $dbdir 'name=$ck_mod_name library=libcoolkeypk11.so'"
+
+ fi
+ else
+ elog ""
+ elog "You still need to setup your PKCS11 library, or at least"
+ elog "find where it is (perhaps \$HOME/.pki/nssdb). Once you"
+ elog "find it, use 'modutil -rawlist -dbdir \$db' to look for"
+ elog "libcoolkeypk11.so, and if not found, add it using:"
+ elog ""
+ elog "$pk -p \$db 'name=$ck_mod_name library=libcoolkeypk11.so'"
+ elog ""
+ elog "where \$db is the full path to your pki/nssdb directory."
+ elog ""
+ fi
+}
+
+pkg_postrm() {
+ if [[ -x $dbdir ]]; then
+ if $(modutil -rawlist -dbdir $dbdir | grep libcoolkeypk11); then
+ elog "You should remove libcoolkey from your PKCS11 library."
+ fi
+ fi
+}