diff options
author | Justin Bronder <jsbronder@gentoo.org> | 2010-11-18 16:20:44 +0000 |
---|---|---|
committer | Justin Bronder <jsbronder@gentoo.org> | 2010-11-18 16:20:44 +0000 |
commit | 1891abb02d9925312d72d6b0070a02d72c657c0b (patch) | |
tree | 0906b70f4cee0ec8d7ac03df072424a49a435875 /sys-cluster | |
parent | Fix typo. Thanks to Andrey Yurchuk <ayurchuk@minuteware.net> (diff) | |
download | gentoo-2-1891abb02d9925312d72d6b0070a02d72c657c0b.tar.gz gentoo-2-1891abb02d9925312d72d6b0070a02d72c657c0b.tar.bz2 gentoo-2-1891abb02d9925312d72d6b0070a02d72c657c0b.zip |
Add missing deps for building the drmaa docs along with other minor fixes (#345463). Thanks to Kacper Kowalik <xarthisius@gentoo.org> who did most of the work.
(Portage version: 2.1.9.24/cvs/Linux x86_64)
Diffstat (limited to 'sys-cluster')
5 files changed, 186 insertions, 9 deletions
diff --git a/sys-cluster/torque/ChangeLog b/sys-cluster/torque/ChangeLog index 93eb47c84336..b2a84c4f6e9d 100644 --- a/sys-cluster/torque/ChangeLog +++ b/sys-cluster/torque/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for sys-cluster/torque # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-cluster/torque/ChangeLog,v 1.99 2010/11/14 22:58:28 jsbronder Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-cluster/torque/ChangeLog,v 1.100 2010/11/18 16:20:44 jsbronder Exp $ + + 18 Nov 2010; Justin Bronder <jsbronder@gentoo.org> + +files/0001-fix-parallel-doc-install.patch, + +files/0002-fix-implicit-declaration-warnings.patch, + +files/0003-disable-automagic-doc-building.patch, torque-2.3.13.ebuild: + Add missing deps for building the drmaa docs along with other minor fixes + (#345463). Thanks to Kacper Kowalik <xarthisius@gentoo.org> who did most + of the work. 14 Nov 2010; Justin Bronder <jsbronder@gentoo.org> -torque-2.3.12.ebuild: cleanup diff --git a/sys-cluster/torque/files/0001-fix-parallel-doc-install.patch b/sys-cluster/torque/files/0001-fix-parallel-doc-install.patch new file mode 100644 index 000000000000..8505787062ab --- /dev/null +++ b/sys-cluster/torque/files/0001-fix-parallel-doc-install.patch @@ -0,0 +1,35 @@ +From d29ba6daadde49d4e2325b415f2fe614bd2cbad1 Mon Sep 17 00:00:00 2001 +From: Kacper Kowalik <xarthisius@gentoo.org> +Date: Tue, 16 Nov 2010 16:23:14 -0500 +Subject: [PATCH 1/4] fix parallel doc install + +man7/pbs_resources_irix5.7 was defined twice. + +Thanks to Kacper Kowalik <xarthisius@gentoo.org> +--- + doc/Makefile.am | 2 -- + 1 files changed, 0 insertions(+), 2 deletions(-) + +diff --git a/doc/Makefile.am b/doc/Makefile.am +index 797b4d6..d4b474c 100644 +--- a/doc/Makefile.am ++++ b/doc/Makefile.am +@@ -33,7 +33,6 @@ EXTRA_DIST = man1/qalter.1.in man1/qdel.1.in man1/qhold.1.in man1/qmove.1.in \ + man7/pbs_resources_fujitsu.7.in \ + man7/pbs_resources_hpux10.7.in man7/pbs_resources_irix5.7.in \ + man7/pbs_resources_hpux11.7.in \ +- man7/pbs_resources_irix5.7.in \ + man7/pbs_resources_irix6.7.in man7/pbs_resources_irix6array.7.in \ + man7/pbs_resources_linux.7.in man7/pbs_resources_netbsd.7.in \ + man7/pbs_resources_solaris5.7.in man7/pbs_resources_solaris7.7.in \ +@@ -79,7 +78,6 @@ nodist_man7_MANS = man7/pbs_job_attributes.7 man7/pbs_queue_attributes.7 \ + man7/pbs_resources_freebsd.7 man7/pbs_resources_fujitsu.7 \ + man7/pbs_resources_hpux10.7 man7/pbs_resources_irix5.7 \ + man7/pbs_resources_hpux11.7 \ +- man7/pbs_resources_irix5.7 \ + man7/pbs_resources_irix6.7 man7/pbs_resources_irix6array.7 \ + man7/pbs_resources_linux.7 man7/pbs_resources_netbsd.7 \ + man7/pbs_resources_solaris5.7 man7/pbs_resources_solaris7.7 \ +-- +1.7.2.2 + diff --git a/sys-cluster/torque/files/0002-fix-implicit-declaration-warnings.patch b/sys-cluster/torque/files/0002-fix-implicit-declaration-warnings.patch new file mode 100644 index 000000000000..49bf1f9a8602 --- /dev/null +++ b/sys-cluster/torque/files/0002-fix-implicit-declaration-warnings.patch @@ -0,0 +1,53 @@ +From 7a60464264bafb27c4bbaab39744b267d671f41b Mon Sep 17 00:00:00 2001 +From: Justin Bronder <jsbronder@gmail.com> +Date: Tue, 16 Nov 2010 16:31:25 -0500 +Subject: [PATCH 2/3] fix implicit declaration warnings + +vasprintf and asprintf require _GNU_SOURCE. + +Thanks to Kacper Kowalik <xarthisius@gentoo.org> +--- + src/drmaa/src/error.c | 1 + + src/drmaa/src/submit.c | 1 + + src/drmaa/src/wait.c | 1 + + 3 files changed, 3 insertions(+), 0 deletions(-) + +diff --git a/src/drmaa/src/error.c b/src/drmaa/src/error.c +index b848041..4a65b47 100644 +--- a/src/drmaa/src/error.c ++++ b/src/drmaa/src/error.c +@@ -23,6 +23,7 @@ + # include <pbs_config.h> + #endif + ++#define _GNU_SOURCE // asprintf + #include <unistd.h> + + #include <stdio.h> +diff --git a/src/drmaa/src/submit.c b/src/drmaa/src/submit.c +index e9b404c..9f06620 100644 +--- a/src/drmaa/src/submit.c ++++ b/src/drmaa/src/submit.c +@@ -23,6 +23,7 @@ + # include <pbs_config.h> + #endif + ++#define _GNU_SOURCE + #include <sys/stat.h> + #include <unistd.h> + #include <limits.h> +diff --git a/src/drmaa/src/wait.c b/src/drmaa/src/wait.c +index ecb2ed4..2ef7600 100644 +--- a/src/drmaa/src/wait.c ++++ b/src/drmaa/src/wait.c +@@ -23,6 +23,7 @@ + # include <pbs_config.h> + #endif + ++#define _GNU_SOURCE // vasprintf + #include <assert.h> + #include <limits.h> + #include <signal.h> +-- +1.7.2.2 + diff --git a/sys-cluster/torque/files/0003-disable-automagic-doc-building.patch b/sys-cluster/torque/files/0003-disable-automagic-doc-building.patch new file mode 100644 index 000000000000..43632c3f2115 --- /dev/null +++ b/sys-cluster/torque/files/0003-disable-automagic-doc-building.patch @@ -0,0 +1,51 @@ +From 7351d31442fcf324b7f7769911af8a98368506e2 Mon Sep 17 00:00:00 2001 +From: Justin Bronder <jsbronder@gmail.com> +Date: Tue, 16 Nov 2010 17:03:13 -0500 +Subject: [PATCH 3/3] disable automagic doc building + +Instead of unconditionally building docs if doxygen is found, only build +at the request of the user. +--- + configure.ac | 19 +++++++++++++------ + 1 files changed, 13 insertions(+), 6 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 480e23e..a8182cd 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -1237,8 +1237,6 @@ dnl + if test "$build_drmaa" = "yes" ;then + AC_MSG_NOTICE([Configuring DRMAA ...]) + AC_PATH_PROG(GPERF, "gperf") +-AX_PROG_DOT +-AC_PATH_PROG(DOXYGEN, "doxygen", "none") + AC_C_BIGENDIAN_CROSS + ACX_PTHREAD(,[AC_MSG_ERROR([POSIX threads library is required by DRMAA.])]) + +@@ -1282,10 +1280,19 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <stdarg.h>]], + AC_MSG_RESULT([no]) + ]) + +- build_drmaa_docs=yes +-else +- DOXYGEN=none +- build_drmaa_docs=no ++AC_ARG_ENABLE([apidocs], ++ AS_HELP_STRING([--enable-apidocs],[Build DRMAA documentation]) ++) ++AS_IF([test "x$enable_apidocs" = "xyes"], ++ [ AX_PROG_DOT ++ AC_PATH_PROG(DOXYGEN, "doxygen", "none") ++ build_drmaa_docs=yes ], ++ [ build_drmaa_docs=no ++ DOXYGEN=none ] ++) ++else ++ DOXYGEN="none" ++ build_drmaa_docs=no + fi + AM_CONDITIONAL(DRMAA_DOCS, [test "$DOXYGEN" != "none"]) + AC_SUBST(build_drmaa_docs) +-- +1.7.2.2 + diff --git a/sys-cluster/torque/torque-2.3.13.ebuild b/sys-cluster/torque/torque-2.3.13.ebuild index d3b64bb12c63..a968401a0cbd 100644 --- a/sys-cluster/torque/torque-2.3.13.ebuild +++ b/sys-cluster/torque/torque-2.3.13.ebuild @@ -1,9 +1,9 @@ # Copyright 1999-2010 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-cluster/torque/torque-2.3.13.ebuild,v 1.1 2010/09/27 13:41:36 jsbronder Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-cluster/torque/torque-2.3.13.ebuild,v 1.2 2010/11/18 16:20:44 jsbronder Exp $ EAPI=2 -inherit flag-o-matic eutils linux-info +inherit flag-o-matic eutils linux-info autotools DESCRIPTION="Resource manager and queuing system based on OpenPBS" HOMEPAGE="http://www.clusterresources.com/products/torque/" @@ -23,6 +23,7 @@ DEPEND_COMMON="sys-libs/ncurses !games-util/qstat" DEPEND="${DEPEND_COMMON} + doc? ( drmaa? ( app-doc/doxygen[latex,-nodot] ) ) sys-apps/ed" RDEPEND="${DEPEND_COMMON} @@ -42,7 +43,7 @@ pkg_setup() { fi fi - USE_CPUSETS="--disable-cpusets" + USE_CPUSETS="--disable-cpuset" if use cpusets; then if ! use kernel_linux; then einfo @@ -61,16 +62,37 @@ pkg_setup() { elog "your kernel with CONFIG_CPUSETS enabled." einfo fi - USE_CPUSETS="--enable-cpusets" + USE_CPUSETS="--enable-cpuset" fi fi } +src_prepare() { + epatch "${FILESDIR}"/0001-fix-parallel-doc-install.patch + epatch "${FILESDIR}"/0002-fix-implicit-declaration-warnings.patch + epatch "${FILESDIR}"/0003-disable-automagic-doc-building.patch + + sed -i \ + -e 's,\(COMPACT_LATEX *=\).*,\1 NO,' \ + -e 's,\(GENERATE_MAN *=\).*,\1 NO,' \ + src/drmaa/Doxyfile.in || die + sed -i \ + -e '/INSTALL_DATA/d' \ + src/drmaa/Makefile.am || die + eautoreconf +} + src_configure() { local myconf="--with-rcp=mom_rcp" use crypt && myconf="--with-rcp=scp" + if use drmaa && use doc; then + myconf="${myconf} --enable-apidocs" + else + myconf="${myconf} --disable-apidocs" + fi + econf \ $(use_enable tk gui) \ $(use_enable syslog) \ @@ -129,18 +151,22 @@ src_install() { # Make directories first pbs_createspool "${D}" - make DESTDIR="${D}" install || die "make install failed" + emake DESTDIR="${D}" install || die "make install failed" dodoc CHANGELOG DEVELOPMENT README.* Release_Notes || die "dodoc failed" if use doc; then dodoc doc/admin_guide.ps doc/*.pdf || die "dodoc failed" + if use drmaa; then + dohtml -r src/drmaa/doc/html/* || die + dodoc src/drmaa/drmaa.pdf || die + fi fi # The build script isn't alternative install location friendly, # So we have to fix some hard-coded paths in tclIndex for xpbs* to work for file in `find "${D}" -iname tclIndex`; do - sed -e "s/${D//\// }/ /" "${file}" > "${file}.new" - mv "${file}.new" "${file}" + sed -e "s/${D//\// }/ /" "${file}" > "${file}.new" || die + mv "${file}.new" "${file}" || die done if use server; then @@ -150,6 +176,9 @@ src_install() { newinitd "${FILESDIR}"/pbs_mom-init.d pbs_mom newconfd "${FILESDIR}"/torque-conf.d torque newenvd "${FILESDIR}"/torque-env.d 25torque + + [ -d "${D}"/usr/share/doc/torque-drmaa ] && \ + rm -rf "${D}"/usr/share/doc/torque-drmaa } pkg_preinst() { @@ -160,7 +189,8 @@ pkg_preinst() { echo "${PBS_SERVER_NAME}" > "${D}${PBS_SERVER_HOME}/server_name" # Fix up the env.d file to use our set server home. - sed -i "s:/var/spool/torque:${PBS_SERVER_HOME}:g" "${D}"/etc/env.d/25torque + sed -i "s:/var/spool/torque:${PBS_SERVER_HOME}:g" \ + "${D}"/etc/env.d/25torque || die } pkg_postinst() { |