net-misc/sks-9999: add mercurial version
authorkristianf <devnull@localhost>
Sat, 2 Nov 2013 23:01:38 +0000 (00:01 +0100)
committerkristianf <devnull@localhost>
Sat, 2 Nov 2013 23:01:38 +0000 (00:01 +0100)
net-misc/sks/Manifest
net-misc/sks/sks-9999.ebuild [new file with mode: 0644]

index 78e078e..d152c57 100644 (file)
@@ -5,3 +5,4 @@ AUX sks-recon.runscript 592 SHA256 85ef9ab277082e6440a300dc3e1f7b94365a892982c07
 AUX sks-recon.service 207 SHA256 990b809a91323f94110a4024ebd4759a3f5c1cac96a1577b39f50ef4b6865e3a SHA512 7fc3c83f3267ef5e2b8b097c0d095cbaa682552df8caa1be47f54ff5639e9f64855f304562aad181800516d7faa8d081c4b225d9c95223cb14c61e8b6d58faa7 WHIRLPOOL 03f7623e12ff84f8affda5214d0b1234b77ce55eb7faad813365e9aa4acae61214b06d6b26e789ffdb1d25db6f5a6c6bbfc5dd2c60c14506f0337272c9e4e96d
 DIST sks-1.1.4.tgz 345249 SHA256 baa79be8c1983544518e8a72ccecacb2837d52ae4015dc7cf364cddb53220c76 SHA512 f83c02c995dd3519cfa221c41ab827b9689bcbf91360d2448f83a5dd8b42e7f15665213c4f048ad678da4093d2ec533b6fcc1f5297933ad5f445143b77e14202 WHIRLPOOL eda6d169998434e5eda58dfdd6d7b0e63a5fc493fd38c65d9ce12a2eb5319523c93be4d5244f7fa9f7a3cb408a12b89cbd357e67096b3c914a2e903635970a50
 EBUILD sks-1.1.4.ebuild 2992 SHA256 8c300cf3d9c6a19e32c7b23f426fcbe9b93f73b6a03b356e94c5253d478b6e89 SHA512 5b4e83f24daa261bcb5446f36e4738329e3996b059a8abfe3e193e12afe2f204570ba3dbdb66a7d0e6e2d938754cc8b0e35e871ced495ba63ba84a2e4560cd57 WHIRLPOOL b1dcbbe72a30cdddb53a4aded8d981e7d7e442eb0b0b851fc0bcd664f2bb22f95f6b7139d2974a1e64f8326d673fa184d613039113c3da2891fa06585b39febd
+EBUILD sks-9999.ebuild 3125 SHA256 4c50b48240b998603fa41c7632e0c21ec7f33a3d09479748bf1f47d7782aaee9 SHA512 52022ca0a340a4b2e6a2a9f57e0b493fe8ce9b9eca74157a21a1972f5a461623a07ccbc7f5057a3299cf43ca17ebfec4f9e974e0395e06be8b98d2f5d9cbd35a WHIRLPOOL f892ba7d6126c6a66381d9a69b9b9bad6ee3bc10383d1eacad7cdce0c1f6cc8247a22d86f055864106d1396c52b1c9e8f06f7ee76bf1304c755e10acb7ddcd37
diff --git a/net-misc/sks/sks-9999.ebuild b/net-misc/sks/sks-9999.ebuild
new file mode 100644 (file)
index 0000000..761396b
--- /dev/null
@@ -0,0 +1,102 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-misc/sks/sks-1.1.2.ebuild,v 1.4 2012/02/07 00:34:06 kingtaco Exp $
+
+EAPI=4
+
+inherit eutils multilib mercurial
+
+DESCRIPTION="SKS Keyserver"
+HOMEPAGE="https://bitbucket.org/skskeyserver/sks-keyserver"
+if [[ ${PV} == "9999" ]]; then
+EHG_REPO_URI="https://bitbucket.org/skskeyserver/sks-keyserver"
+EHG_REVISION="tip"
+else
+SRC_URI="https://bitbucket.org/skskeyserver/sks-keyserver/downloads/${P}.tgz"
+fi;
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="systemd optimize test"
+
+DEPEND="dev-lang/ocaml
+               dev-ml/cryptokit
+               sys-libs/db:5.2"
+RDEPEND="${DEPEND}"
+
+pkg_setup() {
+       ebegin "Creating named group and user"
+       enewgroup sks
+       enewuser sks -1 -1 /var/lib/sks sks
+}
+
+src_prepare() {
+       cp Makefile.local.unused Makefile.local || die
+       sed -i \
+               -e "s:^BDBLIB=.*$:BDBLIB=-L/usr/$(get_libdir):g" \
+               -e "s:^BDBINCLUDE=.*$:BDBINCLUDE=-I/usr/include/db5.2/:g" \
+               -e "s:^LIBDB=.*$:LIBDB=-ldb-5.2:g" \
+               -e "s:^PREFIX=.*$:PREFIX=${D}/usr:g" \
+               -e "s:^MANDIR=.*$:MANDIR=${D}/usr/share/man:g" \
+               Makefile.local || die
+       sed -i \
+               -e 's:^CAMLINCLUDE= -I lib -I bdb$:CAMLINCLUDE= -I lib -I bdb -I +cryptokit:g' \
+               -e 's:-Werror-implicit-function-declaration::g' \
+               Makefile bdb/Makefile || die
+}
+
+src_compile() {
+       emake dep
+       emake -j1 all
+       if use optimize; then
+               emake all.bc
+       fi
+}
+
+src_test() {
+       ./sks unit_test
+}
+
+src_install() {
+       if use optimize; then
+               emake install.bc
+               dosym /usr/bin/sks.bc usr/bin/sks
+               dosym /usr/bin/sks_add_mail.bc usr/bin/sks_add_mail
+       else
+               emake install
+       fi
+
+       dodoc README.md
+
+       newinitd "${FILESDIR}/sks-db.runscript" sks-db
+       newinitd "${FILESDIR}/sks-recon.runscript" sks-recon
+       newconfd "${FILESDIR}/sks-confd" sks
+       use systemd && systemd_dounit "${FILESDIR}/sks-db.service"
+       use systemd && systemd_dounit "${FILESDIR}/sks-recon.service"
+
+       mkdir -p $D/var/lib/sks/web.typical
+       cp $S/sampleConfig/DB_CONFIG $D/var/lib/sks/DB_CONFIG.typical
+       cp $S/sampleConfig/sksconf.typical $D/var/lib/sks/sksconf.typical
+       cp $S/sampleWeb/HTML5/* $D/var/lib/sks/web.typical/
+
+       keepdir /var/lib/sks
+}
+
+pkg_postinst() {
+       einfo "To get sks running, first build the database,"
+       einfo "start the databse, import atleast one key, then"
+       einfo "run a cleandb. See the sks man page for more"
+       einfo "information"
+       einfo "Typical DB_CONFIG file and sksconf has been installed"
+       einfo "in /var/lib/sks and can be used as templates by renaming"
+       einfo "to remove the .typical extension. The DB_CONFIG file has"
+       einfo "to be in place before doing the database build, or the BDB"
+       einfo "environment has to be manually cleared from both KDB and PTree"
+       einfo "using db4.8_recover -h and db4.8_checkpoint -1h"
+       einfo "Additionally a sample web interface has been installed as"
+       einfo "web.typical in /var/lib/sks that can be used by renaming it to web"
+       einfo "Important: It is strongly recommended to set up SKS behind a"
+       einfo "reverse proxy. Instructions on properly configuring SKS can be"
+       einfo "found at https://bitbucket.org/skskeyserver/sks-keyserver/wiki/Peering"
+}
+