# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils multilib DESCRIPTION="C++ STL library implementation with extras." HOMEPAGE="http://stlport.sourceforge.net/" SRC_URI="mirror://sourceforge/stlport/${P}.tar.bz2" LICENSE="as-is" SLOT="0" KEYWORDS="~amd64 ~x86" IUSE="" DEPEND="" S=${WORKDIR}/${PN} src_unpack() { unpack ${A} cd "${S}" sed -i \ -e 's:OPT += -O2::' \ -e 's:OPT += -g::' \ build/Makefiles/gmake/{,lib/,app/}*.mak \ || die "sed opts failed" # not really sure we still need this part below, but does not work without cat <<- EOF >> stlport/config/stl_gcc.h #undef _STLP_NATIVE_INCLUDE_PATH #define _STLP_NATIVE_INCLUDE_PATH ../g++-v3 EOF } src_compile() { export OPT="${CXXFLAGS}" emake \ -C build/lib \ -f gcc.mak \ depend all || die "Compile failed" } src_install() { dodir /usr/$(get_libdir) cp -pPR build/lib/obj/*/*/libstlport*.so* "${D}"/usr/$(get_libdir)/ || die "dolib.so failed" dodir /usr/include cp -R "${S}"/stlport "${D}"/usr/include rm -r "${D}"/usr/include/stlport/BC50 chmod -R a+r "${D}"/usr/include/stlport cd "${S}"/etc/ dodoc ChangeLog* README TODO *.txt cd "${S}" dohtml -r doc/* }