dog-1.7-r5.ebuild 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. # Copyright 1999-2015 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI="5"
  4. inherit eutils toolchain-funcs
  5. DESCRIPTION="Dog is better than cat"
  6. # the best HOMEPAGE we have.
  7. HOMEPAGE="https://packages.gentoo.org/package/sys-apps/dog"
  8. SRC_URI="mirror://gentoo/${P}.tar.gz"
  9. LICENSE="GPL-2"
  10. SLOT="0"
  11. KEYWORDS="~alpha ~amd64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~sparc64-solaris"
  12. IUSE=""
  13. PATCHES=(
  14. "${FILESDIR}"/${P}-check-ctime.diff
  15. "${FILESDIR}"/${PV}-manpage-touchup.patch
  16. "${FILESDIR}"/${P}-64bit-goodness.patch
  17. "${FILESDIR}"/${P}-strfry.patch
  18. )
  19. src_prepare() {
  20. epatch "${PATCHES[@]}"
  21. if [[ "${CHOST}" == *-solaris* ]]; then
  22. sed -i '/gcc.*-o dog/s/$/ -lsocket -lnsl/' \
  23. Makefile || die "sed Makefile failed"
  24. fi
  25. sed -i \
  26. -e 's,^CFLAGS,#CFLAGS,' \
  27. -e "s,gcc,$(tc-getCC)," \
  28. -e 's:-o dog:$(LDFLAGS) -o dog:g' \
  29. Makefile || die "sed Makefile failed"
  30. }
  31. src_install() {
  32. dobin "${PN}" || die
  33. doman "${PN}".1 || die
  34. dodoc README AUTHORS || die
  35. }