# Copyright 1999-2003 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: /home/cvsroot/gentoo-x86/dev-perl/libapreq/libapreq-1.2-r1.ebuild,v 1.1 2003/11/05 00:17:07 rac Exp $ inherit libtool MY_P=${P/libapreq/libapreq2} MY_P=${MY_P/alpha/} S=${WORKDIR}/${MY_P/_[0-9][0-9]/}-dev DESCRIPTION="A Apache Request Perl Module" SRC_URI="http://www.apache.org/dist/httpd/libapreq/${MY_P}-dev.tar.gz" HOMEPAGE="http://httpd.apache.org/apreq/" SLOT="2" LICENSE="Apache-1.1 as-is" KEYWORDS="~x86 amd64 ~ppc ~sparc ~alpha ~ia64" # ccache breaks the cgi portion of make test # thieved from lilypond ebuild PATH="$(echo ":${PATH}:" | sed 's/:[^:]*ccache[^:]*:/:/;s/^://;s/:$//;')" DEPEND="${DEPEND} >=sys-apps/sed-4 dev-perl/Apache-Test >=dev-perl/mod_perl-1.99" mydoc="TODO" # the install process installs libapreq2 first, and then calls apxs2 # -i, which tries to recompile a libtool thing and fails because it # can't find libapreq2, which is still sitting in the staging # directory. this approach thieved from subversion ebuild, suggested # by pauldv. that didn't work, neither did the LD_LIBRARY_PATH thing. # I'm at the end of my rope for now on this, so i'm disabling relink. # Anybody that can figure out a cleaner way is certainly welcome to do # so. src_unpack() { unpack ${A} cd ${S} epatch ${FILESDIR}/libapreq-2.0-binloc.patch || die epatch ${FILESDIR}/libapreq-2.0-notest.patch || die epatch ${FILESDIR}/libapreq-2.0-modinstall.patch || die echo "ScriptSock ${D}/run" >> ${S}/env/t/conf/extra.conf.in elibtoolize sed -i -e 's/need_relink=yes/#ouch need_relink=yes/' ${S}/ltmain.sh } src_compile() { autoreconf econf --with-apache2-apxs=/usr/sbin/apxs2 \ --with-apache2-httpd=/usr/sbin/apache2 \ --with-perl-glue emake LT_LDFLAGS="-L${D}/usr/lib" || die emake test || die } src_install() { make DESTDIR=${D} LT_LDFLAGS="-L${D}/usr/lib" install || die }