--- /home/pclouds/t/gentoo-x86/www-plugins/nspluginwrapper/nspluginwrapper-1.2.2-r1.ebuild 2009-07-21 03:26:05.000000000 +0700 +++ nspluginwrapper-1.2.2-r2.ebuild 2009-10-08 11:56:01.000000000 +0700 @@ -12,13 +12,13 @@ LICENSE="GPL-2" SLOT="0" -KEYWORDS="~amd64" +KEYWORDS="~amd64 ~x86" IUSE="" RDEPEND=">=x11-libs/gtk+-2 net-misc/curl - app-emulation/emul-linux-x86-xlibs - app-emulation/emul-linux-x86-gtklibs + amd64? ( app-emulation/emul-linux-x86-xlibs + app-emulation/emul-linux-x86-gtklibs ) || ( >=sys-apps/util-linux-2.13 sys-apps/setarch )" DEPEND="${RDEPEND} dev-util/pkgconfig" @@ -63,20 +63,23 @@ src_install() { emake -j1 DESTDIR="${D}" install || die "emake install failed" - inst_plugin "/usr/$(get_libdir)/${PN}/x86_64/linux/npwrapper.so" - dosym "/usr/$(get_libdir)/${PN}/x86_64/linux/npconfig" "/usr/bin/${PN}" + local ARCH=i386 + use amd64 && ARCH=x86_64 + inst_plugin "/usr/$(get_libdir)/${PN}/${ARCH}/linux/npwrapper.so" + dosym "/usr/$(get_libdir)/${PN}/${ARCH}/linux/npconfig" "/usr/bin/${PN}" dodoc NEWS README TODO ChangeLog } pkg_postinst() { - autoinstall - elog "Any 32bit plugins you currently have installed have now been" - elog "configured to work in a 64bit browser. Any plugins you install in" - elog "the future will first need to be setup with:" - elog " \"nspluginwrapper -i \"" - elog "before they will function in a 64bit browser" - elog + if use amd64; then + autoinstall + elog "Any 32bit plugins you currently have installed have now been" + elog "configured to work in a 64bit browser. Any plugins you install in" + elog "the future will first need to be setup with:" + elog " \"nspluginwrapper -i \"" + elog "before they will function in a 64bit browser" + fi } # this is terribly ugly, but without a way to query portage as to whether @@ -89,5 +92,5 @@ } pkg_postrm() { - autoinstall + use amd64 && autoinstall }