# Copyright 1999-2009 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ EAPI=1 inherit eutils DESCRIPTION="interconverts file formats used in molecular modeling" HOMEPAGE="http://openbabel.sourceforge.net/" SRC_URI="mirror://sourceforge/openbabel/${P}.tar.gz" KEYWORDS="~amd64 ~ppc ~ppc64 ~sparc ~x86" SLOT="0" LICENSE="GPL-2" IUSE="doc python +zlib" RDEPEND="!sci-chemistry/babel >=dev-libs/libxml2-2.6.5 python? ( dev-lang/python ) zlib? ( sys-libs/zlib )" DEPEND="${RDEPEND} >=dev-libs/boost-1.33.1 dev-lang/perl python? ( dev-lang/swig ) doc? ( app-doc/doxygen )" src_compile() { local myconf="" use python && myconf="--enable-maintainer-mode" econf \ ${myconf} \ --enable-static \ $(use_with zlib) \ || die "econf failed" emake || die "emake failed" } src_test() { make check || die "make check failed" } src_install() { emake DESTDIR="${D}" install || die "make install failed" if use python ; then cd scripts/python python ./setup.py build || die "python setup build failed" python ./setup.py install --root="${D}" --optimize=1 \ || die "python setup install failed" cd ../.. fi dodoc AUTHORS ChangeLog NEWS README THANKS cd doc dohtml *.html *.png dodoc *.inc README* *.inc *.mol2 }