From: Manuel Rüger Date: Sun, 25 Jan 2015 09:24:53 +0000 (+0000) Subject: EAPI bump, add ruby 2.0, 2.1 targets. Drop ~ppc, ~x86 keywords. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=6bad681db7be0b92f3f79f6b0f89cb2ea93c7712;p=gentoo.git EAPI bump, add ruby 2.0, 2.1 targets. Drop ~ppc, ~x86 keywords. Package-Manager: portage-2.2.15/cvs/Linux x86_64 --- diff --git a/net-irc/rbot/ChangeLog b/net-irc/rbot/ChangeLog index 796a41f4fe34..73e0010a30c7 100644 --- a/net-irc/rbot/ChangeLog +++ b/net-irc/rbot/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for net-irc/rbot -# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-irc/rbot/ChangeLog,v 1.58 2014/08/14 14:39:38 mrueg Exp $ +# Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-irc/rbot/ChangeLog,v 1.59 2015/01/25 09:24:49 mrueg Exp $ + +*rbot-0.9.15_p20131020-r1 (25 Jan 2015) + + 25 Jan 2015; Manuel Rüger +rbot-0.9.15_p20131020-r1.ebuild: + EAPI bump, add ruby 2.0, 2.1 targets. Drop ~ppc, ~x86 keywords. 14 Aug 2014; Manuel Rüger rbot-0.9.15_p20131020.ebuild: Remove ruby18 from USE_RUBY. diff --git a/net-irc/rbot/Manifest b/net-irc/rbot/Manifest index f3b7a17d0915..6dd5826c8448 100644 --- a/net-irc/rbot/Manifest +++ b/net-irc/rbot/Manifest @@ -4,6 +4,7 @@ AUX rbot.conf2 1111 SHA256 22c2b489846c56d054f3e88e1763486bcb59df621c288e8b816fd AUX rbot.init 1564 SHA256 6755c99f34b679decace984c63d1c93f1f2d44cd73eab92ad0a225c5add5af57 SHA512 7acd93358b4ef21363716d4fc5b7387d316547f168f8ff932c1fc8fc64b1b315f8031f705e024302aed86e0e8ba7b18bbe009903b2b12aee772dea3a6a20e501 WHIRLPOOL 94a1ce7b268d3776fc3c00c578a922eea6658b3084062fe5b7e1da45c80ea7579494a1ba1d23c3d30abd6ed1adb5631f198cfeea1f93ba01dac09995955c91ad AUX rbot.init2 1446 SHA256 f751394c927424c9b614c70dcaba19652d2d4383d30f20c295cd7da4268e02c1 SHA512 464e22209cbf4d367eacb6adf85dfb7addb8d5ee5c9b824596854a632ffc67bfdb1090ef4ae13a332e41e45ae6dd7dbef15516447c836c33da5d1ee4178ebd1a WHIRLPOOL ebd3ccd8cdc5ef96c54adfcbf34363fbc0bfa75a3a653536fded31083f229f213989de75fc812d20543a6e8cb78d682bbbe94bad184171a41657b04dc0a96d8b DIST rbot-0.9.15_p20131020.tar.gz 773953 SHA256 74b4db6a2b24784a1779518cd070bbf8cb6d4a5059167579d8226a0fc69cef15 SHA512 3319031361f7ab23e43a997a94663790775047c50eb8eb51f3f579cf879ca822b48118060fdd9f2816d5d97c57de8f6fb7ce883457336f961ff25cf6c49a8d2a WHIRLPOOL 8e77fdeb290dae0c4932628e010768217df223e94a5ec902ed48e9db3a2c2985ef2df932e84048ab8721b8d4bb954852397974afa02f1bdfc1e1b8533b58d812 +EBUILD rbot-0.9.15_p20131020-r1.ebuild 4823 SHA256 e957c990dd140942ae1a0faa3c5781490e2e6a3c3ba12e640a29bd07fad4d06f SHA512 5ce38d6ade143591cff7981413a930ec588f2543233ba7c0985e22e4dae1e4865cfdfaad6efacfc7f3a9d67f9489689c3b3a080921abed9e6619749aa6481068 WHIRLPOOL 0d8a04b62ecc49c7d7d7cae6c554097356129e0e1f74fe6eecf40f91058347e667da36da241500e66a1373acf050e207716ed37cc1aa3046013e4b37ba73adce EBUILD rbot-0.9.15_p20131020.ebuild 4829 SHA256 fa4c6aa6e368ef023dfe4a1695446452c20f15ea58c8241ee8168f00e989ab49 SHA512 f7aac72da1daf73b2cc7e240a409173ee321998e9a15da6fc9792982d2b2ec7e7c693b620b204cc50560347bd0259294879981fba2fa4be9f5df2831bdcdfdaf WHIRLPOOL b2d3e3146eefbc1a0322a89993f81296104ef17f423d75d9ddaae7de630052c52442473c2e631bc9ae7ee1b402ac77dac1840798ac748566fe348154d877f20c -MISC ChangeLog 10007 SHA256 4033f33ed1d47f34b6c2aad397a8d566d856eae9cc0e99c257d4e0b3bbcdcb56 SHA512 056b846ac455ba5d173b310af281f11f16139e65668ec75f0693fb959cab30aa10851925efd24e7ca53903e25a0f4c8def6c2d2fc39d29f49c1ab33f3956914a WHIRLPOOL ca72332bd8a1b9a7b7e9d262f1872d4a26852163901bdd2184eec30aa1b7a437d5b35bcc021dc459db6252fbb7a35d69edf2f5098f333672d4c5219210127829 +MISC ChangeLog 10197 SHA256 b109bd1651a23c1d3e5e22739482a01593877673b01c3ac1d4cf69cc002bce57 SHA512 c289841404fa1ecf08b6a32b04d68d12b389cd92773c69abf1795a74b841ac8ec08cfc2a3846f4ae47f990d17f20316c0d2936cd2270b393f760ee235c79d449 WHIRLPOOL 77bfbdc4de3b2e4f5b1f7c0b6a4869bd30910e2450a36b468ce9cf1e8f8aea8ef833487079baf1979c260f615221f4580c35f8c8fdc77bda758e685e0ce77954 MISC metadata.xml 2799 SHA256 5dd7f94886d19526bbc3fa2c974507b4835959e177fa3ba82e73d24e82edc911 SHA512 366692b73e2becfefc82cf733983abbaad9c704680eff7d93bf9f2207f5c04d18b05a5258df8d13930fe8dc56a801533c8afd7a03c1c6f5fd5684dd3365d7f28 WHIRLPOOL 32d9fbe256627af08ec22c00b9cebd0ebf332b030516e1b36956f44aa52b9b6cea0c88bdfbc22261e0005de1b216b568cc68d4799c5bceeb90ef6486b910485e diff --git a/net-irc/rbot/rbot-0.9.15_p20131020-r1.ebuild b/net-irc/rbot/rbot-0.9.15_p20131020-r1.ebuild new file mode 100644 index 000000000000..8ede9b8c7ad3 --- /dev/null +++ b/net-irc/rbot/rbot-0.9.15_p20131020-r1.ebuild @@ -0,0 +1,176 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-irc/rbot/rbot-0.9.15_p20131020-r1.ebuild,v 1.1 2015/01/25 09:24:49 mrueg Exp $ + +EAPI=5 +USE_RUBY="ruby19 ruby20 ruby21" + +inherit ruby-ng eutils user + +DESCRIPTION="A ruby IRC bot" +HOMEPAGE="http://ruby-rbot.org/" +SRC_URI="http://dev.a3li.li/gentoo/distfiles/${P}.tar.gz" + +LICENSE="|| ( feh GPL-2 )" +SLOT="0" +KEYWORDS="~amd64" +IUSE="spell aspell timezone translator shorturl nls dict figlet + fortune cal host toilet" +ILINGUAS="zh_CN zh_TW ru nl de fi fr it ja" +RUBY_S="${PN}-master" + +for lang in $ILINGUAS; do + IUSE="${IUSE} linguas_${lang}" +done + +RDEPEND+=" + spell? ( + aspell? ( app-text/aspell ) + !aspell? ( app-text/hunspell ) + ) + figlet? ( app-misc/figlet ) + toilet? ( app-misc/toilet ) + fortune? ( games-misc/fortune-mod ) + cal? ( || ( sys-apps/util-linux sys-freebsd/freebsd-ubin ) ) + host? ( net-dns/bind-tools )" + +ruby_add_bdepend " + nls? ( + >=dev-ruby/ruby-gettext-2 + dev-ruby/rake + )" + +ruby_add_rdepend " + dev-ruby/tokyocabinet + timezone? ( dev-ruby/tzinfo ) + translator? ( dev-ruby/mechanize ) + shorturl? ( dev-ruby/shorturl ) + nls? ( dev-ruby/ruby-gettext >=dev-ruby/locale-2.0.5-r2 ) + dict? ( >=dev-ruby/ruby-dict-0.9.4-r2 )" + +RUBY_PATCHES=( "rbot-rakefile.patch" ) + +pkg_setup() { + enewuser rbot -1 -1 /var/lib/rbot nobody +} + +all_ruby_compile() { + disable_rbot_plugin() { + mv "${S}"/data/rbot/plugins/$1.rb{,.disabled} + } + use_rbot_plugin() { + use $1 && return + disable_rbot_plugin "$2" + } + rbot_conf() { + echo "$1: $2" >> "${T}"/rbot.conf + } + use_rbot_conf_path() { + use "$1" \ + && rbot_conf "$2" "$3" \ + || rbot_conf "$2" /bin/false + } + + local spell_program="/usr/bin/hunspell -i" + if use !spell; then + disable_rbot_plugin spell + spell_program="/bin/false" + elif use aspell; then + spell_program="/usr/bin/ispell-aspell" + fi + + rbot_conf spell.program "${spell_program}" + + if use !figlet && use !toilet; then + disable_rbot_plugin figlet + fi + + use_rbot_conf_path figlet figlet.path /usr/bin/figlet + use_rbot_conf_path toilet toilet.path /usr/bin/toilet + + use_rbot_plugin timezone time + use_rbot_plugin translator translator + use_rbot_plugin shorturl shortenurls + use_rbot_plugin dict dictclient + + use_rbot_plugin fortune fortune + use_rbot_conf_path fortune fortune.path /usr/bin/fortune + + use_rbot_plugin cal cal + use_rbot_conf_path cal cal.path /usr/bin/cal + + use_rbot_plugin host host + use_rbot_conf_path host host.path /usr/bin/host + + local rbot_datadir="${D}"/usr/share/rbot + + # This is unfortunately pretty manual at the moment, but it's just + # to avoid having to run special scripts to package new versions + # of rbot. The default if new languages are added that are not + # considered for an opt-out here is to install them, so you just + # need to add them later. + if use nls; then + strip-linguas ${ILINGUAS} + if [[ -n ${LINGUAS} ]]; then + # As the the language name used by the rbot data files does + # not correspond to the ISO codes we usually use for LINGUAS, + # the following list of local varables will work as a + # dictionary to get the name used by rbot from the ISO code. + local lang_rbot_zh_CN="traditional_chinese" + local lang_rbot_ru="russian" + local lang_rbot_nl="dutch" + local lang_rbot_de="german" + local lang_rbot_fi="finnish" + local lang_rbot_fr="french" + local lang_rbot_it="italian" + local lang_rbot_ja="japanese" + + for lang in ${ILINGUAS}; do + use linguas_${lang} && continue + + lang_varname="lang_rbot_${lang}" + lang_rbot=${!lang_varname} + + rm -r \ + "${S}"/data/rbot/languages/${lang_rbot}.lang \ + "${S}"/data/rbot/templates/lart/larts-${lang_rbot} \ + "${S}"/data/rbot/templates/lart/praises-${lang_rbot} \ + "${S}"/data/rbot/templates/salut/salut-${lang_rbot} \ + "${S}"/po/${lang} &>/dev/null + done + fi + + ${RUBY} /usr/bin/rake makemo || die "locale generation failed" + fi +} + +each_ruby_compile() { + ${RUBY} setup.rb config --prefix="/usr" \ + || die "setup.rb install failed" +} + +each_ruby_install() { + ${RUBY} setup.rb install --prefix="${D}" \ + || die "setup.rb install failed" +} + +all_ruby_install() { + diropts -o rbot -g nobody -m 0700 + keepdir /var/lib/rbot + + insinto /etc + doins "${T}"/rbot.conf + + newinitd "${FILESDIR}/rbot.init2" rbot + newconfd "${FILESDIR}/rbot.conf2" rbot +} + +pkg_postinst() { + elog "rbot can be started as a normal service." + elog "Check /etc/conf.d/rbot file for more information about this feature." + ewarn "DEPRECATION NOTICE:" + ewarn "The bdb database backend is deprecated and only available on Ruby 1.8." + ewarn "To migrate to the new tokyocabinet-based backend, change the core.db" + ewarn "parameter in your bot's conf.yaml to 'tc' and restart rbot." + ewarn "This procedure requires a Ruby version supporting both BDB and TC." +}