summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2007-12-07 00:34:10 +0000
committerRobin H. Johnson <robbat2@gentoo.org>2007-12-07 00:34:10 +0000
commit26437c4e62ae8313469e3dc9823a8925bddbaf7b (patch)
tree307b07f8339acbc33b22d72f81fc2ada2f271a26 /dev-util/cvs
parent2.1.4_rc8 regression fix for bug #201506 (sandbox violation with packages (diff)
downloadgentoo-2-26437c4e62ae8313469e3dc9823a8925bddbaf7b.tar.gz
gentoo-2-26437c4e62ae8313469e3dc9823a8925bddbaf7b.tar.bz2
gentoo-2-26437c4e62ae8313469e3dc9823a8925bddbaf7b.zip
Clean up .13 ebuild, version bump that upstream put in a different place to previous ones, and clean up a duplicate patch from files.
(Portage version: 2.1.4_rc4)
Diffstat (limited to 'dev-util/cvs')
-rw-r--r--dev-util/cvs/cvs-1.12.13-r1.ebuild28
-rw-r--r--dev-util/cvs/cvs-1.12.13.1.ebuild145
-rw-r--r--dev-util/cvs/files/cvs-1.12.13-cvsbug-tmpfix.patch22
-rw-r--r--dev-util/cvs/files/cvs-1.12.13.1-block-requests.patch101
-rw-r--r--dev-util/cvs/files/digest-cvs-1.12.13.112
5 files changed, 272 insertions, 36 deletions
diff --git a/dev-util/cvs/cvs-1.12.13-r1.ebuild b/dev-util/cvs/cvs-1.12.13-r1.ebuild
index a2c48fa68a33..47bf5abdae5d 100644
--- a/dev-util/cvs/cvs-1.12.13-r1.ebuild
+++ b/dev-util/cvs/cvs-1.12.13-r1.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-util/cvs/cvs-1.12.13-r1.ebuild,v 1.4 2007/09/14 18:19:39 uberlord Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-util/cvs/cvs-1.12.13-r1.ebuild,v 1.5 2007/12/07 00:34:09 robbat2 Exp $
inherit eutils pam
@@ -25,11 +25,11 @@ DEPEND=">=sys-libs/zlib-1.1.4
src_unpack() {
unpack ${P}.tar.bz2
use doc && unpack cederqvist-${PV}.html.tar.bz2
- EPATCH_OPTS="-p1 -d ${S}" epatch ${FILESDIR}/${P}-cvsbug-tmpfix.patch
+ EPATCH_OPTS="-p1 -d ${S}" epatch "${FILESDIR}"/${PN}-1.12.12-cvsbug-tmpfix.patch
epatch ${FILESDIR}/${P}-openat.patch
- EPATCH_OPTS="-p0 -d ${S}" epatch ${FILESDIR}/${P}-zlib.patch
+ EPATCH_OPTS="-p0 -d ${S}" epatch "${FILESDIR}"/${P}-zlib.patch
cd "${S}"
- epatch ${FILESDIR}/${PN}-1.12.12-install-sh.patch
+ epatch "${FILESDIR}"/${PN}-1.12.12-install-sh.patch
# this testcase was not updated
#sed -i.orig -e '/unrecognized keyword.*BogusOption/s,98,73,g' \
# ${S}/src/sanity.sh
@@ -112,15 +112,15 @@ src_test() {
# view, and requires root level ssh changes.
if [ -n "$TEST_REMOTE_AND_PROXY" ]; then
cd ${S}/src
- export TESTDIR="${T}/tests-remote"
- mkdir -p "$TESTDIR"
- make remotecheck || die "Some remote test failed."
- mv -f check.log check.log-remote
-
- cd ${S}/src
- export TESTDIR="${T}/tests-proxy"
- mkdir -p "$TESTDIR"
- make proxycheck || die "Some proxy test failed."
- mv -f check.log check.log-proxy
+ export TESTDIR="${T}/tests-remote"
+ mkdir -p "$TESTDIR"
+ make remotecheck || die "Some remote test failed."
+ mv -f check.log check.log-remote
+
+ cd ${S}/src
+ export TESTDIR="${T}/tests-proxy"
+ mkdir -p "$TESTDIR"
+ make proxycheck || die "Some proxy test failed."
+ mv -f check.log check.log-proxy
fi
}
diff --git a/dev-util/cvs/cvs-1.12.13.1.ebuild b/dev-util/cvs/cvs-1.12.13.1.ebuild
new file mode 100644
index 000000000000..9a721f36719d
--- /dev/null
+++ b/dev-util/cvs/cvs-1.12.13.1.ebuild
@@ -0,0 +1,145 @@
+# Copyright 1999-2007 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-util/cvs/cvs-1.12.13.1.ebuild,v 1.3 2007/12/07 00:34:09 robbat2 Exp $
+
+inherit eutils pam versionator
+
+DESCRIPTION="Concurrent Versions System - source code revision control tools"
+HOMEPAGE="http://www.nongnu.org/cvs/"
+
+DOC_PV="$(get_version_component_range 1-3)"
+FEAT_URIBASE="mirror://gnu/non-gnu/cvs/source/feature/${PV}/"
+DOC_URIBASE="mirror://gnu/non-gnu/cvs/source/feature/${DOC_PV}/"
+SNAP_URIBASE="mirror://gnu/non-gnu/cvs/source/nightly-snapshots/feature/"
+SRC_URI="
+ ${FEAT_URIBASE}/${P}.tar.bz2
+ ${SNAP_URIBASE}/${P}.tar.bz2
+ doc? (
+ ${DOC_URIBASE}/cederqvist-${DOC_PV}.html.tar.bz2
+ ${DOC_URIBASE}/cederqvist-${DOC_PV}.pdf
+ ${DOC_URIBASE}/cederqvist-${DOC_PV}.ps
+ )"
+
+LICENSE="GPL-2 LGPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
+
+IUSE="crypt doc emacs kerberos nls pam server"
+
+DEPEND=">=sys-libs/zlib-1.1.4
+ kerberos? ( virtual/krb5 )
+ pam? ( virtual/pam )"
+
+src_unpack() {
+ unpack ${P}.tar.bz2
+ use doc && unpack cederqvist-${DOC_PV}.html.tar.bz2
+
+ EPATCH_OPTS="-p1 -d ${S}" epatch "${FILESDIR}"/${PN}-1.12.12-cvsbug-tmpfix.patch
+ EPATCH_OPTS="-p1 -d ${S}" epatch "${FILESDIR}"/${PN}-1.12.12-install-sh.patch
+ EPATCH_OPTS="-p1 -d ${S}" epatch "${FILESDIR}"/${PN}-1.12.13.1-block-requests.patch
+ # Applied by upstream:
+ #EPATCH_OPTS="-p1 -d ${S}" epatch ${FILESDIR}/${PN}-1.12.13-openat.patch
+ #EPATCH_OPTS="-p0 -d ${S}" epatch ${FILESDIR}/${PN}-1.12.13-zlib.patch
+
+ cd "${S}"
+ # this testcase was not updated
+ #sed -i.orig -e '/unrecognized keyword.*BogusOption/s,98,73,g' \
+ # ${S}/src/sanity.sh
+ # this one fails when the testpath path contains '.'
+ sed -i.orig \
+ -e '/newfile config3/s,a-z,a-z.,g' \
+ "${S}"/src/sanity.sh
+
+ elog "If you want any CVS server functionality, you MUST emerge with USE=server!"
+}
+
+src_compile() {
+ local myconf
+ # the tests need the server and proxy
+ if has test $FEATURES; then
+ use server || \
+ ewarn "The server and proxy code are enabled as they are required for tests."
+ myconf="--enable-server --enable-proxy"
+ fi
+ econf \
+ --with-external-zlib \
+ --with-tmpdir=/tmp \
+ $(use_enable crypt encryption) \
+ $(use_with kerberos gssapi) \
+ $(use_enable nls) \
+ $(use_enable pam) \
+ $(use_enable server) \
+ $(use_enable server proxy) \
+ ${myconf} \
+ || die
+ emake || die "emake failed"
+}
+
+src_install() {
+ emake install DESTDIR="${D}" || die
+
+ if use server; then
+ insinto /etc/xinetd.d
+ newins "${FILESDIR}"/cvspserver.xinetd.d cvspserver || die "newins failed"
+ fi
+
+ dodoc BUGS ChangeLog* DEVEL* FAQ HACKING \
+ MINOR* NEWS PROJECTS README* TESTS TODO
+
+ if use emacs; then
+ insinto /usr/share/emacs/site-lisp
+ doins cvs-format.el || die "doins failed"
+ fi
+
+ use server && newdoc "${FILESDIR}"/${PN}-1.12.12-cvs-custom.c cvs-custom.c
+
+ if use doc; then
+ dodoc "${DISTDIR}"/cederqvist-${DOC_PV}.pdf
+ dodoc "${DISTDIR}"/cederqvist-${DOC_PV}.ps
+ dohtml -r "${WORKDIR}"/cederqvist-${DOC_PV}.html/
+ cd "${D}"/usr/share/doc/${PF}/html/
+ ln -s cvs.html index.html
+ fi
+
+ newpamd "${FILESDIR}"/cvs.pam-include-1.12.12 cvs
+}
+
+_run_one_test() {
+ mode="$1" ; shift
+ einfo "Starting ${mode} test"
+ cd "${S}"/src
+ export TESTDIR="${T}/tests-${mode}"
+ rm -rf "$TESTDIR" # Clean up from any previous test passes
+ mkdir -p "$TESTDIR"
+ emake -j1 ${mode}check || die "Some ${mode} test failed."
+ mv -f check.log check.log-${mode}
+ einfo "${mode} test completed successfully, log is check.log-${mode}"
+}
+
+src_test() {
+ einfo "If you want to see realtime status, or check out a failure,"
+ einfo "please look at ${S}/src/check.log*"
+
+ if [ "$TEST_REMOTE_AND_PROXY" == "1" ]; then
+ einfo "local, remote, and proxy tests enabled."
+ else
+ einfo "Only testing local mode. Please see ebuild for other modes."
+ fi
+
+ # we only do the local tests by default
+ _run_one_test local
+
+ # if you want to test the remote and proxy modes, things get a little bit
+ # complicated. You need to set up a SSH config file at ~portage/.ssh/config
+ # that allows the portage user to login without any authentication, and also
+ # set up the ~portage/.ssh/known_hosts file for your machine.
+ # We do not do this by default, as it is unsafe from a security point of
+ # view, and requires root level ssh changes.
+ # Note that this also requires having a real shell for the portage user, so make
+ # sure that su -c 'ssh portage@mybox' portage works first!
+ # (It uses the local ip, not loopback)
+ if [ "$TEST_REMOTE_AND_PROXY" == "1" ]; then
+ _run_one_test remote
+ _run_one_test proxy
+ fi
+}
diff --git a/dev-util/cvs/files/cvs-1.12.13-cvsbug-tmpfix.patch b/dev-util/cvs/files/cvs-1.12.13-cvsbug-tmpfix.patch
deleted file mode 100644
index 1286111b95ae..000000000000
--- a/dev-util/cvs/files/cvs-1.12.13-cvsbug-tmpfix.patch
+++ /dev/null
@@ -1,22 +0,0 @@
-Index: cvs-1.12.13/src/cvsbug.in
-===================================================================
---- cvs-1.12.13.orig/src/cvsbug.in
-+++ cvs-1.12.13/src/cvsbug.in
-@@ -109,14 +109,14 @@ elif [ -f /bin/domainname ]; then
- /usr/bin/ypcat passwd 2>/dev/null | cat - /etc/passwd | grep "^$LOGNAME:" |
- cut -f5 -d':' | sed -e 's/,.*//' > $TEMP
- ORIGINATOR="`cat $TEMP`"
-- rm -f $TEMP
-+ > $TEMP
- fi
- fi
-
- if [ "$ORIGINATOR" = "" ]; then
- grep "^$LOGNAME:" /etc/passwd | cut -f5 -d':' | sed -e 's/,.*//' > $TEMP
- ORIGINATOR="`cat $TEMP`"
-- rm -f $TEMP
-+ > $TEMP
- fi
-
- if [ -n "$ORGANIZATION" ]; then
-
diff --git a/dev-util/cvs/files/cvs-1.12.13.1-block-requests.patch b/dev-util/cvs/files/cvs-1.12.13.1-block-requests.patch
new file mode 100644
index 000000000000..216336f34941
--- /dev/null
+++ b/dev-util/cvs/files/cvs-1.12.13.1-block-requests.patch
@@ -0,0 +1,101 @@
+Author: Robin H. Johnson <robbat2@gentoo.org>
+Original-Date: 2006-08-09
+Forward-Port-Date: 2007-12-06
+
+This patch allows a CVS server to deny usage of specific commands, based on
+input in the environment.
+
+Just set the CVS_BLOCK_REQUESTS env var with all of the commands you want,
+seperated by spaces. Eg:
+CVS_BLOCK_REQUESTS="Gzip-stream gzip-file-contents"
+would block ALL usage of compression.
+
+Please see the array 'struct request requests[]' in src/server.c for a full
+list of commands.
+
+Please note that if you block any commands marked as RQ_ESSENTIAL, CVS clients
+may fail! (This includes 'ci'!).
+
+See the companion cvs-custom.c for a wrapper that can enforce the environment variable for pserver setups.
+
+Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
+
+diff -Nuar cvs-1.12.13.1.orig/src/server.c cvs-1.12.13.1/src/server.c
+--- cvs-1.12.13.1.orig/src/server.c 2006-06-21 11:55:21.000000000 -0700
++++ cvs-1.12.13.1/src/server.c 2007-12-06 16:25:38.109309990 -0800
+@@ -6244,6 +6244,49 @@
+ /*
+ * This server request is not ignored by the secondary.
+ */
++
++/* Hack by Robin H. Johnson <robbat2@gentoo.org>.
++ * Allow the server ENV to specify what request types are to be ignored.
++ */
++
++static char blocked_requests[BUFSIZ] = " ";
++
++static void build_blocked_requests() {
++ char *tmp = getenv("CVS_BLOCK_REQUESTS");
++
++ if (tmp != NULL && strlen(tmp) > 0) {
++ // move to our custom buffer
++ strncat(blocked_requests, tmp, sizeof(blocked_requests)-strlen(blocked_requests));
++ //add a space on the end as well for searching
++ strncat(blocked_requests, " ", sizeof(blocked_requests)-strlen(blocked_requests));
++ }
++
++ // now blocked_requests contains the list of every request that we do not
++ // want to serve
++}
++
++// returns 0 if we should serve this request
++// use as if(checker(FOO)) continue;
++static int serve_valid_requests_checker(char *reqname) {
++ char needle[BUFSIZ] = " ";
++ char *tmp;
++
++ if(!blocked_requests || strlen(blocked_requests) < 2)
++ return 0;
++
++ // we want to look for ' 'reqname' '
++ snprintf(needle, sizeof(needle), " %s ", reqname);
++
++ // now do the search
++ tmp = strstr(blocked_requests, needle);
++
++ if (tmp != NULL)
++ return 1;
++
++ return 0;
++
++}
++
+ static void
+ serve_valid_requests (char *arg)
+ {
+@@ -6262,11 +6305,15 @@
+ )
+ return;
+
++ build_blocked_requests();
++
+ buf_output0 (buf_to_net, "Valid-requests");
+ for (rq = requests; rq->name != NULL; rq++)
+ {
+ if (rq->func != NULL)
+ {
++ if(serve_valid_requests_checker(rq->name))
++ continue;
+ buf_append_char (buf_to_net, ' ');
+ buf_output0 (buf_to_net, rq->name);
+ }
+@@ -6706,6 +6753,9 @@
+ * "co".
+ */
+ continue;
++ // Ignore commands that we are supposed to ignore.
++ if(serve_valid_requests_checker(rq->name))
++ continue;
+
+ if (!(rq->flags & RQ_ROOTLESS)
+ && current_parsed_root == NULL)
diff --git a/dev-util/cvs/files/digest-cvs-1.12.13.1 b/dev-util/cvs/files/digest-cvs-1.12.13.1
new file mode 100644
index 000000000000..4aa99e281929
--- /dev/null
+++ b/dev-util/cvs/files/digest-cvs-1.12.13.1
@@ -0,0 +1,12 @@
+MD5 e979c381eefef51833adace57aa609c7 cederqvist-1.12.13.html.tar.bz2 140382
+RMD160 34723707e078e210a2c032e8c98726a7037b05e6 cederqvist-1.12.13.html.tar.bz2 140382
+SHA256 1a9a34e07c00de5102224b48cbc53384992aea197c91c20b6140dd6885b5ae87 cederqvist-1.12.13.html.tar.bz2 140382
+MD5 1a3e7376c485ee38584c3a623c156638 cederqvist-1.12.13.pdf 1297631
+RMD160 8d0520254a964d146d704fe93656415edc146fec cederqvist-1.12.13.pdf 1297631
+SHA256 4f24b2ac3b81c97798cad42cba8ffe6cc65405f13e5a58a4b063aa9fffc4a7bc cederqvist-1.12.13.pdf 1297631
+MD5 c352dc473afb1be9507af7b0e812bed9 cederqvist-1.12.13.ps 1280573
+RMD160 a370346c4ce84e224968181046482f87116a155b cederqvist-1.12.13.ps 1280573
+SHA256 a955722b89155e390635b1220fa67a096c97141d83ac53a7840323c01d13aa91 cederqvist-1.12.13.ps 1280573
+MD5 cfd07b224956daaed53fb3063bece1bf cvs-1.12.13.1.tar.bz2 4075630
+RMD160 7e281fe8f63805c2fa76dad18b2c537e77cea8b2 cvs-1.12.13.1.tar.bz2 4075630
+SHA256 de7f374d8c4ac414c04e8d44ce9a5d3da919825a6a332d747e299dc7a80c2218 cvs-1.12.13.1.tar.bz2 4075630