mtools-4.0.18.ebuild 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. # Copyright 1999-2013 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI="4"
  4. inherit flag-o-matic
  5. DESCRIPTION="utilities to access MS-DOS disks from Unix without mounting them"
  6. HOMEPAGE="http://mtools.linux.lu/"
  7. SRC_URI="mirror://gnu/${PN}/${P}.tar.bz2"
  8. LICENSE="GPL-3"
  9. SLOT="0"
  10. KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ppc ~ppc64 ~sparc ~x86 ~x64-macos ~x64-solaris"
  11. IUSE="X elibc_glibc"
  12. DEPEND="
  13. !elibc_glibc? ( virtual/libiconv )
  14. X? (
  15. x11-libs/libICE
  16. x11-libs/libXau
  17. x11-libs/libSM
  18. x11-libs/libX11
  19. x11-libs/libXt
  20. )"
  21. RDEPEND="${DEPEND}"
  22. src_prepare() {
  23. # Don't throw errors on existing directories
  24. sed -i -e "s:mkdir:mkdir -p:" mkinstalldirs || die
  25. }
  26. src_configure() {
  27. # 447688
  28. use elibc_glibc || append-libs iconv
  29. econf \
  30. --sysconfdir="${EPREFIX}"/etc/mtools \
  31. $(use_with X x)
  32. }
  33. src_install() {
  34. emake DESTDIR="${D}" install
  35. dodoc README* Release.notes
  36. insinto /etc/mtools
  37. doins mtools.conf
  38. # default is fine
  39. sed -i -e '/^SAMPLE FILE$/s:^:#:' "${ED}"/etc/mtools/mtools.conf || die
  40. }