catdoc-0.95.ebuild 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. # Copyright 1999-2016 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=6
  4. DESCRIPTION="Converter for Microsoft Word, Excel, PowerPoint and RTF files to text"
  5. HOMEPAGE="http://www.wagner.pp.ru/~vitus/software/catdoc/"
  6. SRC_URI="http://ftp.wagner.pp.ru/pub/${PN}/${P}.tar.gz"
  7. LICENSE="GPL-2"
  8. SLOT="0"
  9. KEYWORDS="amd64 ~arm ~ppc x86 ~amd64-linux ~ppc-macos ~x86-macos ~x64-solaris ~x86-solaris"
  10. IUSE="tk"
  11. DEPEND="tk? ( >=dev-lang/tk-8.1 )"
  12. DOCS="CODING.STD NEWS README TODO"
  13. # CREDITS missing by accident in catdoc-0.95
  14. PATCHES=(
  15. "${FILESDIR}/${P}-parallel-make.patch"
  16. )
  17. src_prepare() {
  18. default
  19. # Fix for case-insensitive filesystems
  20. echo ".PHONY: all install clean distclean dist" >> Makefile.in || die
  21. mv configure.{in,ac} || die
  22. }
  23. src_configure() {
  24. econf --with-install-root="${D}" \
  25. $(use_with tk wish "${EPREFIX}"/usr/bin/wish) \
  26. $(use_enable tk wordview)
  27. }
  28. src_compile() {
  29. emake LIB_DIR="${EPREFIX}"/usr/share/catdoc
  30. }
  31. src_install() {
  32. default
  33. if [[ -e ${ED}/usr/bin/xls2csv ]]; then
  34. einfo "Renaming xls2csv to xls2csv-${PN} because of bug 314657."
  35. mv -vf "${ED}"/usr/bin/xls2csv "${ED}"/usr/bin/xls2csv-${PN} || die
  36. fi
  37. }