summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Elio Pettenò <flameeyes@gentoo.org>2009-07-16 13:09:49 +0000
committerDiego Elio Pettenò <flameeyes@gentoo.org>2009-07-16 13:09:49 +0000
commitddb3767bbce2426a0ce9953e73c751277c2ebd1b (patch)
tree724e977600f7185a3232be63e566fe337451cf3c /dev-ruby/prawn
parentInitial import of pdf-inspector as test dependency of prawn. (diff)
downloadgentoo-2-ddb3767bbce2426a0ce9953e73c751277c2ebd1b.tar.gz
gentoo-2-ddb3767bbce2426a0ce9953e73c751277c2ebd1b.tar.bz2
gentoo-2-ddb3767bbce2426a0ce9953e73c751277c2ebd1b.zip
Initial import of prawn.
(Portage version: 2.2_rc33/cvs/Linux x86_64)
Diffstat (limited to 'dev-ruby/prawn')
-rw-r--r--dev-ruby/prawn/ChangeLog10
-rw-r--r--dev-ruby/prawn/metadata.xml5
-rw-r--r--dev-ruby/prawn/prawn-0.4.1.ebuild88
3 files changed, 103 insertions, 0 deletions
diff --git a/dev-ruby/prawn/ChangeLog b/dev-ruby/prawn/ChangeLog
new file mode 100644
index 000000000000..0f3ed5b97f40
--- /dev/null
+++ b/dev-ruby/prawn/ChangeLog
@@ -0,0 +1,10 @@
+# ChangeLog for dev-ruby/prawn
+# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-ruby/prawn/ChangeLog,v 1.1 2009/07/16 13:09:49 flameeyes Exp $
+
+*prawn-0.4.1 (16 Jul 2009)
+
+ 16 Jul 2009; Diego E. Pettenò <flameeyes@gentoo.org> +prawn-0.4.1.ebuild,
+ +metadata.xml:
+ Initial import of prawn.
+
diff --git a/dev-ruby/prawn/metadata.xml b/dev-ruby/prawn/metadata.xml
new file mode 100644
index 000000000000..852136183369
--- /dev/null
+++ b/dev-ruby/prawn/metadata.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>ruby</herd>
+</pkgmetadata>
diff --git a/dev-ruby/prawn/prawn-0.4.1.ebuild b/dev-ruby/prawn/prawn-0.4.1.ebuild
new file mode 100644
index 000000000000..76507648510a
--- /dev/null
+++ b/dev-ruby/prawn/prawn-0.4.1.ebuild
@@ -0,0 +1,88 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-ruby/prawn/prawn-0.4.1.ebuild,v 1.1 2009/07/16 13:09:49 flameeyes Exp $
+
+EAPI=2
+
+GITHUB_USER=sandal
+
+inherit ruby
+
+DESCRIPTION="Fast, Nimble PDF Generation For Ruby"
+HOMEPAGE="http://prawn.majesticseacreature.com/"
+
+LICENSE="|| ( GPL-2 Ruby )"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="doc examples test"
+
+SRC_URI="http://github.com/${GITHUB_USER}/${PN}/tarball/${PV} -> ${P}.tgz"
+
+USE_RUBY="ruby18"
+
+RDEPEND="dev-ruby/ttfunk"
+DEPEND="doc? ( dev-ruby/rake )
+ test? (
+ dev-ruby/rake
+ dev-ruby/test-spec
+ >=dev-ruby/pdf-reader-0.7.3
+ ${RDEPEND}
+ )"
+
+S="${WORKDIR}"
+
+src_compile() {
+ cd "${WORKDIR}"/${GITHUB_USER}-${PN}-*
+
+ if use doc; then
+ rake rdoc || die "rake rdoc failed"
+ fi
+}
+
+src_test() {
+ cd "${WORKDIR}"/${GITHUB_USER}-${PN}-*
+
+ rake test || die "rake test failed"
+}
+
+dofakegemspec() {
+ cat - > "${T}"/${P}.gemspec <<EOF
+Gem::Specification.new do |s|
+ s.name = "${PN}"
+ s.version = "${PV}"
+ s.summary = "${DESCRIPTION}"
+ s.homepage = "${HOMEPAGE}"
+end
+EOF
+
+ # Note: this only works with 1.8 so if you need to make it work
+ # with 1.9 you better wait for ruby-fakegem.eclass.
+ insinto $(${RUBY} -r rbconfig -e 'print Config::CONFIG["sitedir"]')/../gems/1.8/specifications
+ doins "${T}"/${P}.gemspec || die "Unable to install fake gemspec"
+}
+
+src_install() {
+ cd "${WORKDIR}"/${GITHUB_USER}-${PN}-*
+
+ pushd lib
+ doruby -r * || die "install lib failed"
+ popd
+
+ dofakegemspec
+
+ dodoc README HACKING || die "Installing docs failed."
+
+ dohtml -r www/* || die
+
+ if use doc; then
+ docinto apidocs
+ pushd doc
+ dohtml -r * || die "Installing html documentation failed."
+ popd
+ fi
+
+ if use examples; then
+ docinto examples
+ dodoc -r examples/* || die "Installing examples failes."
+ fi
+}