opensp-1.5.2-r3.ebuild 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. # Copyright 1999-2014 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. inherit eutils flag-o-matic
  5. MY_P=${P/opensp/OpenSP}
  6. DESCRIPTION="A free, object-oriented toolkit for SGML parsing and entity management"
  7. HOMEPAGE="http://openjade.sourceforge.net/"
  8. SRC_URI="mirror://sourceforge/openjade/${MY_P}.tar.gz"
  9. LICENSE="MIT"
  10. SLOT="0"
  11. KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
  12. IUSE="doc nls static-libs test"
  13. DEPEND="nls? ( sys-devel/gettext )
  14. doc? (
  15. app-text/xmlto
  16. app-text/docbook-xml-dtd:4.1.2
  17. )
  18. test? (
  19. app-text/docbook-xml-dtd:4.5
  20. app-text/openjade
  21. app-text/sgml-common
  22. )"
  23. RDEPEND=""
  24. S=${WORKDIR}/${MY_P}
  25. src_prepare() {
  26. epatch \
  27. "${FILESDIR}"/${PN}-1.5-gcc34.patch \
  28. "${FILESDIR}"/${P}-fix-segfault.patch
  29. }
  30. src_configure() {
  31. # The following filters are taken from openjade's ebuild. See bug #100828.
  32. # Please note! Opts are disabled. If you know what you're doing
  33. # feel free to remove this line. It may cause problems with
  34. # docbook-sgml-utils among other things.
  35. #ALLOWED_FLAGS="-O -O1 -O2 -pipe -g -march"
  36. strip-flags
  37. econf \
  38. --enable-http \
  39. --enable-default-catalog="${EPREFIX}"/etc/sgml/catalog \
  40. --enable-default-search-path="${EPREFIX}"/usr/share/sgml \
  41. --datadir="${EPREFIX}"/usr/share/sgml/${P} \
  42. $(use_enable nls) \
  43. $(use_enable doc doc-build) \
  44. $(use_enable static-libs static)
  45. }
  46. src_compile() {
  47. emake pkgdocdir="${EPREFIX}"/usr/share/doc/${PF}
  48. }
  49. src_test() {
  50. # Skipping tests known not to work
  51. emake SHOWSTOPPERS= check
  52. SANDBOX_PREDICT="${SANDBOX_PREDICT%:/}"
  53. }
  54. src_install() {
  55. emake \
  56. DESTDIR="${D}" \
  57. pkgdocdir="${EPREFIX}"/usr/share/doc/${PF} \
  58. install
  59. prune_libtool_files
  60. dodoc AUTHORS BUGS ChangeLog NEWS README
  61. }