aboutsummaryrefslogtreecommitdiff
path: root/paludis/repositories/e/ebuild/utils
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-07-26 00:13:55 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-07-26 00:13:55 +0000
commitf67fadb68e2c2d36d55508e9339b881d4a72ccf0 (patch)
tree8b92283a9fdf9781d677221fa757a618aa6b7988 /paludis/repositories/e/ebuild/utils
parentd18402718e4c0d08c7f214490a17ad84322c9b25 (diff)
downloadpaludis-f67fadb68e2c2d36d55508e9339b881d4a72ccf0.tar.gz
paludis-f67fadb68e2c2d36d55508e9339b881d4a72ccf0.tar.xz
Change how die works. Stricter emake, dodoc in exheres-0
Diffstat (limited to 'paludis/repositories/e/ebuild/utils')
-rw-r--r--paludis/repositories/e/ebuild/utils/Makefile.am4
-rw-r--r--paludis/repositories/e/ebuild/utils/exheres-0/Makefile.am4
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/exheres-0/banned_in_eapi_exheres-03
-rw-r--r--paludis/repositories/e/ebuild/utils/exheres-0/dodoc64
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/exheres-0/emake29
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/exheres-0/unpack (renamed from paludis/repositories/e/ebuild/utils/exheres-0/dounpack)4
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/unpack (renamed from paludis/repositories/e/ebuild/utils/dounpack)1
7 files changed, 105 insertions, 4 deletions
diff --git a/paludis/repositories/e/ebuild/utils/Makefile.am b/paludis/repositories/e/ebuild/utils/Makefile.am
index 681d0c319..7d14c878d 100644
--- a/paludis/repositories/e/ebuild/utils/Makefile.am
+++ b/paludis/repositories/e/ebuild/utils/Makefile.am
@@ -25,7 +25,6 @@ libexecprog_SCRIPTS = \
dosbin \
dosed \
dosym \
- dounpack \
emake \
fowners \
fperms \
@@ -50,7 +49,8 @@ libexecprog_SCRIPTS = \
prepallinfo \
prepinfo \
prepdocs \
- prepalldocs
+ prepalldocs \
+ unpack
AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
diff --git a/paludis/repositories/e/ebuild/utils/exheres-0/Makefile.am b/paludis/repositories/e/ebuild/utils/exheres-0/Makefile.am
index 7e5db94b8..5384da288 100644
--- a/paludis/repositories/e/ebuild/utils/exheres-0/Makefile.am
+++ b/paludis/repositories/e/ebuild/utils/exheres-0/Makefile.am
@@ -4,6 +4,7 @@ SUBDIRS = .
libexecprogdir = $(libexecdir)/paludis/utils/exheres-0
libexecprog_SCRIPTS = \
+ dodoc \
dohard \
dosed \
donewins \
@@ -16,7 +17,8 @@ libexecprog_SCRIPTS = \
prepinfo \
prepdocs \
prepalldocs \
- dounpack \
+ unpack \
+ emake \
banned_in_eapi_exheres-0
AM_CXXFLAGS = -I$(top_srcdir) @PALUDIS_CXXFLAGS@
diff --git a/paludis/repositories/e/ebuild/utils/exheres-0/banned_in_eapi_exheres-0 b/paludis/repositories/e/ebuild/utils/exheres-0/banned_in_eapi_exheres-0
index 937c70cd9..214501172 100755
--- a/paludis/repositories/e/ebuild/utils/exheres-0/banned_in_eapi_exheres-0
+++ b/paludis/repositories/e/ebuild/utils/exheres-0/banned_in_eapi_exheres-0
@@ -21,5 +21,8 @@ COLOUR_RED=$'\e[31;01m'
COLOUR_NORMAL=$'\e[0m'
echo "${COLOUR_RED}!!! Ebuild bug: '$(basename ${0} )' banned in EAPI exheres-0${COLOUR_NORMAL}"
+echo "$(basename ${0} ): making ebuild PID ${EBUILD_KILL_PID} exit with error" 1>&2
+kill -s SIGUSR1 "${EBUILD_KILL_PID}"
+
exit 123
diff --git a/paludis/repositories/e/ebuild/utils/exheres-0/dodoc b/paludis/repositories/e/ebuild/utils/exheres-0/dodoc
new file mode 100644
index 000000000..b1cb87612
--- /dev/null
+++ b/paludis/repositories/e/ebuild/utils/exheres-0/dodoc
@@ -0,0 +1,64 @@
+#!/bin/bash
+# vim: set sw=4 sts=4 et :
+
+# Copyright (c) 2006 Stephen Bennett <spb@gentoo.org>
+# Copyright (c) 2007 Ciaran McCreesh <ciaranm@ciaranm.org>
+#
+# Based in part upon dodoc from Portage, which is Copyright 1995-2005
+# Gentoo Foundation and distributed under the terms of the GNU General
+# Public License v2.
+#
+# This file is part of the Paludis package manager. Paludis is free software;
+# you can redistribute it and/or modify it under the terms of the GNU General
+# Public License as published by the Free Software Foundation; either version
+# 2 of the License, or (at your option) any later version.
+#
+# Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
+# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+# details.
+#
+# You should have received a copy of the GNU General Public License along with
+# this program; if not, write to the Free Software Foundation, Inc., 59 Temple
+# Place, Suite 330, Boston, MA 02111-1307 USA
+
+if [[ ! -d ${D} ]]; then
+ echo "${0}: \${D} not valid; aborting" >&2
+ exit 247
+ echo "$(basename ${0} ): making ebuild PID ${EBUILD_KILL_PID} exit with error" 1>&2
+ kill -s SIGUSR1 "${EBUILD_KILL_PID}"
+fi
+
+if [[ $# -lt 1 ]]; then
+ echo "${0}: at least one argument needed" >&2
+ echo "$(basename ${0} ): making ebuild PID ${EBUILD_KILL_PID} exit with error" 1>&2
+ kill -s SIGUSR1 "${EBUILD_KILL_PID}"
+ exit 1
+fi
+
+dir="${D}usr/share/doc/${PF}/${DOCDESTTREE}"
+if [[ ! -d "${dir}" ]]; then
+ if ! install -d "${dir}" ; then
+ echo "$(basename ${0} ): making ebuild PID ${EBUILD_KILL_PID} exit with error" 1>&2
+ kill -s SIGUSR1 "${EBUILD_KILL_PID}"
+ exit 3
+ fi
+fi
+
+ret=0
+
+for x in "$@"; do
+ if [[ -s "${x}" ]]; then
+ install -m0644 "${x}" "${dir}"
+ elif [[ ! -e "${x}" ]]; then
+ echo "${0}: ${x} does not exist" >&2
+ ret=2
+ fi
+done
+
+if [[ 0 != "${ret}" ]] ; then
+ echo "$(basename ${0} ): making ebuild PID ${EBUILD_KILL_PID} exit with error" 1>&2
+ kill -s SIGUSR1 "${EBUILD_KILL_PID}"
+fi
+exit ${ret}
+
diff --git a/paludis/repositories/e/ebuild/utils/exheres-0/emake b/paludis/repositories/e/ebuild/utils/exheres-0/emake
new file mode 100755
index 000000000..a3afc82bd
--- /dev/null
+++ b/paludis/repositories/e/ebuild/utils/exheres-0/emake
@@ -0,0 +1,29 @@
+#!/bin/bash
+# vim: set sw=4 sts=4 et :
+
+# Copyright (c) 2006, 2007 Ciaran McCreesh <ciaranm@ciaranm.org>
+#
+# This file is part of the Paludis package manager. Paludis is free software;
+# you can redistribute it and/or modify it under the terms of the GNU General
+# Public License as published by the Free Software Foundation; either version
+# 2 of the License, or (at your option) any later version.
+#
+# Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
+# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+# FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+# details.
+#
+# You should have received a copy of the GNU General Public License along with
+# this program; if not, write to the Free Software Foundation, Inc., 59 Temple
+# Place, Suite 330, Boston, MA 02111-1307 USA
+
+echo ${EMAKE_WRAPPER} ${MAKE:-make} ${MAKEOPTS} ${EXTRA_EMAKE} "$@" 1>&2
+${EMAKE_WRAPPER} ${MAKE:-make} ${MAKEOPTS} ${EXTRA_EMAKE} "$@"
+ret=$?
+if [[ 0 != $ret ]] ; then
+ echo "emake returned error $ret" 1>&2
+ echo "$(basename ${0} ): making ebuild PID ${EBUILD_KILL_PID} exit with error" 1>&2
+ kill -s SIGUSR1 "${EBUILD_KILL_PID}"
+fi
+
+exit $ret
diff --git a/paludis/repositories/e/ebuild/utils/exheres-0/dounpack b/paludis/repositories/e/ebuild/utils/exheres-0/unpack
index 6ca7817e7..52ff686d7 100755
--- a/paludis/repositories/e/ebuild/utils/exheres-0/dounpack
+++ b/paludis/repositories/e/ebuild/utils/exheres-0/unpack
@@ -23,7 +23,9 @@
die()
{
- echo "dounpack: error: $@" 1>&2
+ echo "unpack: error: $@" 1>&2
+ echo "unpack: making ebuild PID ${EBUILD_KILL_PID} exit with error" 1>&2
+ kill -s SIGUSR1 "${EBUILD_KILL_PID}"
exit 123
}
diff --git a/paludis/repositories/e/ebuild/utils/dounpack b/paludis/repositories/e/ebuild/utils/unpack
index 8de948caf..1b1937c45 100755
--- a/paludis/repositories/e/ebuild/utils/dounpack
+++ b/paludis/repositories/e/ebuild/utils/unpack
@@ -24,6 +24,7 @@
die()
{
echo "dounpack: error: $@" 1>&2
+ kill -s SIGUSR1 "${EBUILD_KILL_PID}"
exit 123
}