1 # Copyright 1999-2009 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
7 # The globus-build tools do not require java to be installed, BUT
8 # configure still expects it...
11 MY_P="gt${PV}-all-source-installer"
13 DESCRIPTION="The Globus Toolkit Build Tools"
14 HOMEPAGE="http://www.globus.org/toolkit/"
16 SRC_URI="http://www-unix.globus.org/ftppub/gt${PV:0:1}/${PV}/installers/src/${MY_P}.tar.bz2"
23 IUSE="condor iodbc lsf odbc pbs"
25 RDEPEND="dev-lang/perl"
29 S="${WORKDIR}/${MY_P}"
31 GLOBUS="/opt/globus${PV:0:1}"
35 enewuser globus -1 -1 /var/globus globus
39 mkdir "${S}"/build || die "making build directory failed"
41 sed -e "s|%%GLOBUS%%|${GLOBUS}|" \
42 "${FILESDIR}"/21globus-build > "${T}"/21globus-build \
43 || die "sed envfile failed"
49 # should we use odbc with iodbc or unixodbc
51 myconfig="--with-iodbc-libs=$(iodbc-config --prefix)/lib"
52 myconfig="${myconfig} --with-iodbc-includes=$(iodbc-config --prefix)/include/iodbc"
54 myconfig="--with-unixodbc-libs=/usr/lib"
55 myconfig="${myconfig} --with-unixodbc-includes=/usr/include/unixodbc"
58 # even though globus does not use java we still need all the junk to
59 # make configure happy...
62 econf --prefix="${S}/build/${GLOBUS}" \
63 --with-gptlocation="${S}/build/${GLOBUS}" \
64 $(use_enable condor wsgram-condor) \
65 $(use_enable lsf wsgram-lsf) \
66 $(use_enable pbs wsgram-pbs) ${myconfig}
70 emake gpt || die "compile failed"
74 einfo "Hand installing..."
75 # The supplied Makefile install violates standard practices. The
76 # following simulates a "make DESTDIR=${D}" and moves the built
77 # programs/files into ${D}
78 cp -dpR "${S}"/build/* "${D}/" || die "mv failed"
80 doenvd "${T}"/21globus-build || die "install env.d/globus-build died"
82 einfo "Updating ownership and permissions..."
83 fowners -R globus:globus * || die "fowners failed"