--- findutils-4.1.7-r4.ebuild 2003-04-26 15:59:59.000000000 -0400 +++ findutils-4.1.7-r4.ebuild.new 2003-04-26 15:59:40.000000000 -0400 @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Header: /home/cvsroot/gentoo-x86/sys-apps/findutils/findutils-4.1.7-r4.ebuild,v 1.8 2003/04/16 16:06:00 joker Exp $ -IUSE="nls build afs selinux" +IUSE="nls build afs selinux slang" inherit eutils @@ -23,7 +23,8 @@ >=sys-apps/sed-4 nls? ( sys-devel/gettext ) afs? ( net-fs/openafs ) - selinux? ( sys-apps/selinux-small )" + selinux? ( sys-apps/selinux-small ) + slang? ( sys-apps/slocate )" RDEPEND="virtual/glibc" src_unpack() { @@ -32,7 +33,7 @@ # Don't build or install locate because it conflicts with slocate, # which is a secure version of locate. See bug 18729 - sed -i '/^SUBDIRS/s/locate//' Makefile.in + use slang && sed -i '/^SUBDIRS/s/locate//' Makefile.in use selinux && epatch ${DISTDIR}/${P}-2003011510-selinux-gentoo.patch.bz2 } @@ -51,26 +52,37 @@ ./configure \ --host=${CHOST} \ --prefix=/usr \ + --localstatedir=/var/spool/locate \ ${myconf} || die emake libexecdir=/usr/lib/find || die } src_install() { - einstall libexecdir=${D}/usr/lib/find || die + #do not change 'localstatedir=/var/spool/locate' to + #'localstatedir=${D}/var/spool/locate', as it will then be hardcoded + #into locate and updatedb + einstall \ + localstatedir=${D}/var/spool/locate \ + libexecdir=${D}/usr/lib/find \ + || die prepallman + dosed "s:TMPDIR=/usr/tmp:TMPDIR=/tmp:" usr/bin/updatedb rm -rf ${D}/usr/var if ! use build; then dodoc COPYING NEWS README TODO ChangeLog else rm -rf ${D}/usr/share fi + keepdir /var/spool/locate } pkg_postinst() { + if use slang; then ewarn "Please note that the locate and updatedb binaries" ewarn "are not longer provided by findutils." ewarn "Please emerge slocate" + fi }