ecls-13.5.1-r1.ebuild 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. # Copyright 1999-2015 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. inherit eutils multilib
  5. # test phase only works if ecls already installed #516876
  6. RESTRICT="test"
  7. MY_P=ecl-${PV}
  8. DESCRIPTION="ECL is an embeddable Common Lisp implementation"
  9. HOMEPAGE="http://ecls.sourceforge.net/"
  10. SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tgz"
  11. LICENSE="BSD LGPL-2"
  12. SLOT="0/${PV}"
  13. KEYWORDS="amd64 ~ppc ~sparc x86"
  14. IUSE="debug emacs gengc precisegc cpu_flags_x86_sse +threads +unicode X"
  15. CDEPEND="dev-libs/gmp
  16. virtual/libffi
  17. >=dev-libs/boehm-gc-7.1[threads?]
  18. >=dev-lisp/asdf-2.33-r3:="
  19. DEPEND="${CDEPEND}
  20. app-text/texi2html
  21. emacs? ( virtual/emacs >=app-eselect/eselect-emacs-1.12 )"
  22. RDEPEND="${CDEPEND}"
  23. S="${WORKDIR}"/${MY_P}
  24. pkg_setup () {
  25. if use gengc || use precisegc ; then
  26. ewarn "You have enabled the generational garbage collector or"
  27. ewarn "the precise collection routines. These features are not very stable"
  28. ewarn "at the moment and may cause crashes."
  29. ewarn "Don't enable them unless you know what you're doing."
  30. fi
  31. }
  32. src_prepare() {
  33. epatch "${FILESDIR}"/${PV}-headers-gentoo.patch
  34. # bug #496780
  35. epatch "${FILESDIR}"/${PV}-gc74.patch
  36. cp "${EPREFIX}"/usr/share/common-lisp/source/asdf/build/asdf.lisp contrib/asdf/ || die
  37. }
  38. src_configure() {
  39. econf \
  40. --with-system-gmp \
  41. --enable-boehm=system \
  42. --enable-longdouble \
  43. --with-dffi \
  44. $(use_enable gengc) \
  45. $(use_enable precisegc) \
  46. $(use_with debug debug-cflags) \
  47. $(use_with cpu_flags_x86_sse sse) \
  48. $(use_enable threads) \
  49. $(use_with threads __thread) \
  50. $(use_enable unicode) \
  51. $(use_with X x) \
  52. $(use_with X clx)
  53. }
  54. src_compile() {
  55. if use emacs; then
  56. local ETAGS=$(eselect --brief etags list | sed -ne '/emacs/{p;q}')
  57. [[ -n ${ETAGS} ]] || die "No etags implementation found"
  58. pushd build > /dev/null || die
  59. emake ETAGS=${ETAGS} TAGS
  60. popd > /dev/null
  61. else
  62. touch build/TAGS
  63. fi
  64. #parallel make fails
  65. emake -j1 || die "Compilation failed"
  66. }
  67. src_install () {
  68. emake DESTDIR="${D}" install || die "Installation failed"
  69. dodoc ANNOUNCEMENT Copyright
  70. dodoc "${FILESDIR}"/README.Gentoo
  71. pushd build/doc
  72. newman ecl.man ecl.1
  73. newman ecl-config.man ecl-config.1
  74. popd
  75. }