summaryrefslogtreecommitdiff
blob: cb8c136ac2bf6d119add6ccb0e38c87b97cd58a9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-www/gorua/gorua-0.17.ebuild,v 1.4 2004/06/25 00:53:01 agriffis Exp $

inherit eutils

IUSE=""

MY_P=${P/gorua/goRua}

DESCRIPTION="goRua -- Gtk+ on Ruby User Agent for 2ch"
HOMEPAGE="http://www.unixuser.org/~haruyama/software/goRua/"
SRC_URI="http://www.unixuser.org/~haruyama/software/goRua/${MY_P}.tar.bz2"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="x86 alpha ~ppc ~sparc"

DEPEND="virtual/ruby
	=x11-libs/gtk+-1.2*
	>=dev-ruby/ruby-gtk-0.28
	>=media-fonts/monafont-2.22
	>=dev-ruby/ruby-zlib-0.5.1"

S=${WORKDIR}/${MY_P}

src_unpack() {

	unpack ${A}
	cd ${S}
	epatch ${FILESDIR}/gorua-bbsmenu-update-gentoo.diff
}

src_compile() {

	sed -e "s|%%GORUA_DATADIR%%|\"/usr/share/${PF}\"|" \
		${FILESDIR}/goRua.sh > ${T}/goRua
	sed -e "s|%%GORUA_DATADIR%%|\"/usr/share/${PF}\"|" \
		new_2ch_bbsmenu.rb > ${T}/new_2ch_bbsmenu.rb
	sed -e "s|/usr/share/goRua|\"/usr/share/${PF}/dot.goRua_2ch\"|" \
		goRua.rb > ${T}/goRua.rb
}

src_install() {

	local sitedir=`ruby -r rbconfig -e 'print Config::CONFIG["sitedir"]'`
	dobin ${T}/goRua.rb ${T}/goRua

	insinto ${sitedir}
	doins connect2ch.rb goRua_color_table.rb

	exeinto /usr/share/${PF}
	doexe goRua_url_updator.rb goRua_bookmarks_translator.rb \
		goRua_cache_clean.rb ${T}/new_2ch_bbsmenu.rb
	insinto /usr/share/${PF}
	doins Makefile
	cp ${FILESDIR}/bookmarks_sample .goRua_2ch/bookmarks
	cp -r .goRua_2ch ${D}/usr/share/${PF}/dot.goRua_2ch

	dodoc ChangeLog README
}