summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-haskell/haddock/haddock-0.7.ebuild')
-rw-r--r--dev-haskell/haddock/haddock-0.7.ebuild73
1 files changed, 73 insertions, 0 deletions
diff --git a/dev-haskell/haddock/haddock-0.7.ebuild b/dev-haskell/haddock/haddock-0.7.ebuild
new file mode 100644
index 000000000000..8691f0fe7dc0
--- /dev/null
+++ b/dev-haskell/haddock/haddock-0.7.ebuild
@@ -0,0 +1,73 @@
+# Copyright 1999-2005 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-haskell/haddock/haddock-0.7.ebuild,v 1.1 2005/08/05 12:48:21 kosmikus Exp $
+#
+# USE variable summary:
+# doc - Build extra documenation from DocBook sources,
+# in HTML format.
+# tetex - Build the above docs as PostScript as well.
+
+
+inherit ghc-package
+IUSE="doc java"
+
+DESCRIPTION="A documentation tool for Haskell"
+SRC_URI="http://www.haskell.org/haddock/${P}-src.tar.gz"
+HOMEPAGE="http://www.haskell.org/haddock"
+
+SLOT="0"
+KEYWORDS="~x86 ~ppc ~amd64 ~sparc"
+LICENSE="as-is"
+
+DEPEND="virtual/ghc
+ doc? ( ~app-text/docbook-xml-dtd-4.2
+ app-text/docbook-xsl-stylesheets
+ >=dev-libs/libxslt-1.1.2
+ >=dev-haskell/haddock-0.6-r2
+ java? ( >=dev-java/fop-0.20.5 ) )"
+RDEPEND=""
+
+src_compile() {
+ local myconf
+ local mydoc
+
+ # initialize build.mk
+ echo '# Gentoo changes' > mk/build.mk
+ # determine what to do with documentation
+ if use doc; then
+ mydoc="html"
+ if use java; then
+ mydoc="${mydoc} ps"
+ fi
+ else
+ mydoc=""
+ # needed to prevent haddock from being called
+ echo NO_HADDOCK_DOCS=YES >> mk/build.mk
+ fi
+ echo XMLDocWays="${mydoc}" >> mk/build.mk
+
+ econf || die "econf failed"
+
+ # using -j1 because -j2 behaved strangely on my machine
+ emake -j1 || die "make failed"
+}
+
+src_install() {
+ local insttarget
+
+ insttarget="install"
+ use doc && insttarget="${insttarget} install-docs"
+
+ # the libdir0 setting is needed for amd64, and does not
+ # harm for other arches
+ emake -j1 ${insttarget} \
+ prefix="${D}/usr" \
+ datadir="${D}/usr/share/${P}" \
+ infodir="${D}/usr/share/info" \
+ mandir="${D}/usr/share/man" \
+ libdir0="${D}/usr/$(get_libdir)" \
+ || die "make install failed"
+
+ cd ${S}/haddock
+ dodoc CHANGES LICENSE README TODO
+}