diff options
Diffstat (limited to 'dev-vcs')
-rw-r--r-- | dev-vcs/cvsync/Manifest | 1 | ||||
-rw-r--r-- | dev-vcs/cvsync/cvsync-2014.08.24.014706.ebuild | 82 | ||||
-rw-r--r-- | dev-vcs/cvsync/cvsync-9999.ebuild | 82 | ||||
-rw-r--r-- | dev-vcs/cvsync/metadata.xml | 16 |
4 files changed, 181 insertions, 0 deletions
diff --git a/dev-vcs/cvsync/Manifest b/dev-vcs/cvsync/Manifest new file mode 100644 index 000000000000..f2938246f7bd --- /dev/null +++ b/dev-vcs/cvsync/Manifest @@ -0,0 +1 @@ +DIST cvsync-2014.08.24.014706.tar.xz 94820 SHA256 ddb753a03c2e80e9507cb971a1ff0c682e353eb36737189457d6e8e507a04467 SHA512 8aa05d3e2459a14e6abe48eb13b7130aa0bdba7bc9e3604b8406622541450349c233bf43f11804d3820567f882335e1079a9fb747e1d1b8a5d93325bf4e97158 WHIRLPOOL 23ad6ce402f4b3785b0c365b7cc181bf88ed118316e1217034e477b6637d019aee72b149e1cd6d5a1fc0b27773d021d15e202e67c7e76296a69f92ab45e7bb93 diff --git a/dev-vcs/cvsync/cvsync-2014.08.24.014706.ebuild b/dev-vcs/cvsync/cvsync-2014.08.24.014706.ebuild new file mode 100644 index 000000000000..7013e775230c --- /dev/null +++ b/dev-vcs/cvsync/cvsync-2014.08.24.014706.ebuild @@ -0,0 +1,82 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI="5" + +inherit toolchain-funcs + +if [[ ${PV} == "9999" ]] ; then + EGIT_REPO_URI="https://github.com/cvsync/cvsync.git" + inherit git-2 +else + SRC_URI="mirror://gentoo/${P}.tar.xz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" +fi + +DESCRIPTION="portable CVS repository synchronization utility" +HOMEPAGE="https://github.com/cvsync/cvsync" + +LICENSE="BSD" +SLOT="0" +IUSE="gcrypt mhash +openssl" +REQUIRED_USE="!openssl? ( ^^ ( gcrypt mhash ) )" + +RDEPEND="sys-libs/zlib + openssl? ( dev-libs/openssl:0= ) + !openssl? ( + gcrypt? ( dev-libs/libgcrypt:0= ) + mhash? ( app-crypt/mhash ) + )" +DEPEND="${RDEPEND}" + +S="${WORKDIR}/${PN}" + +maint_pkg_create() { + cd "${S}" + local ver=$(date --date="$(git log -n1 --pretty=format:%ci HEAD)" -u "+%Y.%m.%d.%H%M%S") + local tar="${T}/${PN}-${ver}.tar.xz" + git archive --prefix "${PN}/" HEAD | xz > "${tar}" || die "creating tar failed" + einfo "Packaged tar now available:" + einfo "$(du -b "${tar}")" +} + +src_unpack() { + if [[ ${PV} == "9999" ]] ; then + git-2_src_unpack + maint_pkg_create + else + default + fi +} + +_emake() { + # USE flag settings are enforced by REQUIRED_USE. + local hash=$(usex openssl openssl $(usex gcrypt gcrypt mhash)) + + # Probably want to expand this at some point. + local host_os="Linux" + + emake \ + CC="$(tc-getCC)" \ + ECHO="echo" \ + TEST="test" \ + INSTALL="install" \ + HASH_TYPE="${hash}" \ + HOST_OS="${host_os}" \ + BINOWN="$(id -u)" \ + BINGRP="$(id -g)" \ + BINDIR="\$(PREFIX)/usr/bin" \ + MANDIR="\$(PREFIX)/usr/share/man" \ + "$@" +} + +src_compile() { + _emake PREFIX="${EPREFIX}" +} + +src_install() { + dodir /usr/bin /usr/share/man/man1 + _emake PREFIX="${ED}" install + dodoc samples/*.conf +} diff --git a/dev-vcs/cvsync/cvsync-9999.ebuild b/dev-vcs/cvsync/cvsync-9999.ebuild new file mode 100644 index 000000000000..7013e775230c --- /dev/null +++ b/dev-vcs/cvsync/cvsync-9999.ebuild @@ -0,0 +1,82 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI="5" + +inherit toolchain-funcs + +if [[ ${PV} == "9999" ]] ; then + EGIT_REPO_URI="https://github.com/cvsync/cvsync.git" + inherit git-2 +else + SRC_URI="mirror://gentoo/${P}.tar.xz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" +fi + +DESCRIPTION="portable CVS repository synchronization utility" +HOMEPAGE="https://github.com/cvsync/cvsync" + +LICENSE="BSD" +SLOT="0" +IUSE="gcrypt mhash +openssl" +REQUIRED_USE="!openssl? ( ^^ ( gcrypt mhash ) )" + +RDEPEND="sys-libs/zlib + openssl? ( dev-libs/openssl:0= ) + !openssl? ( + gcrypt? ( dev-libs/libgcrypt:0= ) + mhash? ( app-crypt/mhash ) + )" +DEPEND="${RDEPEND}" + +S="${WORKDIR}/${PN}" + +maint_pkg_create() { + cd "${S}" + local ver=$(date --date="$(git log -n1 --pretty=format:%ci HEAD)" -u "+%Y.%m.%d.%H%M%S") + local tar="${T}/${PN}-${ver}.tar.xz" + git archive --prefix "${PN}/" HEAD | xz > "${tar}" || die "creating tar failed" + einfo "Packaged tar now available:" + einfo "$(du -b "${tar}")" +} + +src_unpack() { + if [[ ${PV} == "9999" ]] ; then + git-2_src_unpack + maint_pkg_create + else + default + fi +} + +_emake() { + # USE flag settings are enforced by REQUIRED_USE. + local hash=$(usex openssl openssl $(usex gcrypt gcrypt mhash)) + + # Probably want to expand this at some point. + local host_os="Linux" + + emake \ + CC="$(tc-getCC)" \ + ECHO="echo" \ + TEST="test" \ + INSTALL="install" \ + HASH_TYPE="${hash}" \ + HOST_OS="${host_os}" \ + BINOWN="$(id -u)" \ + BINGRP="$(id -g)" \ + BINDIR="\$(PREFIX)/usr/bin" \ + MANDIR="\$(PREFIX)/usr/share/man" \ + "$@" +} + +src_compile() { + _emake PREFIX="${EPREFIX}" +} + +src_install() { + dodir /usr/bin /usr/share/man/man1 + _emake PREFIX="${ED}" install + dodoc samples/*.conf +} diff --git a/dev-vcs/cvsync/metadata.xml b/dev-vcs/cvsync/metadata.xml new file mode 100644 index 000000000000..d32f150a3a92 --- /dev/null +++ b/dev-vcs/cvsync/metadata.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer type="person"> + <email>vapier@gentoo.org</email> + <description>feel free to update</description> +</maintainer> +<use> + <flag name="gcrypt">Use <pkg>dev-libs/libgcrypt</pkg> for hash functions.</flag> + <flag name="mhash">Use <pkg>app-crypt/mhash</pkg> for hash functions.</flag> + <flag name="openssl">Use <pkg>dev-libs/openssl</pkg> for hash functions.</flag> +</use> +<upstream> + <remote-id type="github">cvsync/cvsync</remote-id> +</upstream> +</pkgmetadata> |