# Copyright 1999-2002 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/sys-devel/perl/perl-5.8.0-r3.ebuild,v 1.7 2002/12/11 16:00:48 mcummings Exp $ IUSE="berkdb gdbm" S=${WORKDIR}/${P} DESCRIPTION="Larry Wall's Practical Extraction and Reporting Language" SRC_URI="ftp://ftp.perl.org/pub/CPAN/src/${P}.tar.gz" HOMEPAGE="http://www.perl.org" LICENSE="Artistic GPL-2" SLOT="0" KEYWORDS="~x86 ~sparc ~ppc ~alpha" DEPEND="sys-apps/groff berkdb? ( >=sys-libs/db-3.2.3h-r3 =sys-libs/db-1.85-r1 ) gdbm? ( >=sys-libs/gdbm-1.8.0 )" RDEPEND="berkdb? ( >=sys-libs/db-3.2.3h-r3 =sys-libs/db-1.85-r1 ) gdbm? ( >=sys-libs/gdbm-1.8.0 )" src_compile() { local myconf if [ "`use gdbm`" ] then myconf="-Di_gdbm" fi if [ "`use berkdb`" ] then myconf="${myconf} -Di_db -Di_ndbm" else myconf="${myconf} -Ui_db -Ui_ndbm" fi if [ "`use sparc`" ] then myconf="${myconf} -Ud_longdbl" fi if [ "`use sparc64`" ] then myconf="${myconf} -Ud_longdbl" fi cd ${S} rm -f config.sh Policy.sh sh Configure -des \ -Darchname=${CHOST%%-*}-linux \ -Dcccdlflags='-fPIC' \ -Dccdlflags='-rdynamic' \ -Dcc=gcc \ -Dprefix='/usr' \ -Dvendorprefix='/usr' \ -Dsiteprefixx='/usr' \ -Dlocincpth=' ' \ -Doptimize="${CFLAGS}" \ -Duselargefiles \ -Duseshrplib \ -Dman3ext=3pm \ -Dlibperl=libperl.so \ -Dd_dosuid \ -Dd_semctl_semun \ -Dcf_by=Gentoo \ -Ud_csh \ ${myconf} || die make -f Makefile depend || die "Couldn't make libperl.so depends" make -f Makefile libperl.so || die "Unable to make libperl.so" mv libperl.so ${WORKDIR} cd ${WORKDIR} rm -rf ${S} unpack ${A} cd ${S} cat > config.over < ${D}/usr/lib/perl5/${PV}/${CHOST%%-*}-linux/Config.pm cp ${D}/usr/lib/perl5/${PV}/${CHOST%%-*}-linux/Config.pm ${D}/usr/lib/perl5/${PV}/${CHOST%%-*}-linux/Config.pm.bak sed -e "s:cppflags=':cppflags='-DPERL5 :" ${D}/usr/lib/perl5/${PV}/${CHOST%%-*}-linux/Config.pm.bak > ${D}/usr/lib/perl5/${PV}/${CHOST%%-*}-linux/Config.pm rm -f ${D}/usr/lib/perl5/${PV}/${CHOST%%-*}-linux/Config.pm.bak rm -f ${D}/usr/lib/perl5/${PV}/Config.pm.4install # A poor fix for the miniperl issues sed -e 's:./miniperl:/usr/bin/perl:' ${D}/usr/lib/perl5/${PV}/ExtUtils/xsubpp > ${D}/usr/lib/perl5/${PV}/ExtUtils/xsubpp.bak mv ${D}/usr/lib/perl5/${PV}/ExtUtils/xsubpp.bak ${D}/usr/lib/perl5/${PV}/ExtUtils/xsubpp chmod 444 ${D}/usr/lib/perl5/${PV}/ExtUtils/xsubpp sed -e 's:./miniperl:/usr/bin/perl:' ${D}/usr/bin/xsubpp > ${D}/usr/bin/xsubpp.bak mv ${D}/usr/bin/xsubpp.bak ${D}/usr/bin/xsubpp chmod 755 ${D}/usr/bin/xsubpp ./perl installman --man1dir=${D}/usr/share/man/man1 --man1ext=1 --man3dir=${D}/usr/share/man/man3 --man3ext=3 # This removes ${D} from Config.pm dosed /usr/lib/perl5/${PV}/${CHOST%%-*}-linux/Config.pm dosed /usr/lib/perl5/${PV}/${CHOST%%-*}-linux/.packlist dodoc Changes* Artistic Copying README Todo* AUTHORS prepalldocs # HTML Documentation # We expect errors, warnings, and such with the following. dodir /usr/share/doc/${PF}/html ./perl installhtml \ --podroot=. \ --podpath=lib:ext:pod:vms \ --recurse \ --htmldir=${D}/usr/share/doc/${PF}/html \ --libpods=perlfunc:perlguts:perlvar:perlrun:perlop }