diff options
author | bdrewery <bdrewery@FreeBSD.org> | 2013-08-18 00:45:55 +0800 |
---|---|---|
committer | bdrewery <bdrewery@FreeBSD.org> | 2013-08-18 00:45:55 +0800 |
commit | 4dae0a2c5fa41f22d683a8b58374c70f947495cb (patch) | |
tree | 41668734d36973ed2d54c16fdba5f61577e88ad7 /irc | |
parent | 132725827af8a996456ff471636ffc76656f6468 (diff) | |
download | freebsd-ports-gnome-4dae0a2c5fa41f22d683a8b58374c70f947495cb.tar.gz freebsd-ports-gnome-4dae0a2c5fa41f22d683a8b58374c70f947495cb.tar.zst freebsd-ports-gnome-4dae0a2c5fa41f22d683a8b58374c70f947495cb.zip |
- Fix runtime crash due to gettext
Obtained from: upstream git
Diffstat (limited to 'irc')
-rw-r--r-- | irc/rbot/Makefile | 8 | ||||
-rw-r--r-- | irc/rbot/files/patch-lib__rbot__load-gettext.rb | 26 |
2 files changed, 30 insertions, 4 deletions
diff --git a/irc/rbot/Makefile b/irc/rbot/Makefile index bae0ee189a29..ad7f28270819 100644 --- a/irc/rbot/Makefile +++ b/irc/rbot/Makefile @@ -3,7 +3,7 @@ PORTNAME= rbot PORTVERSION= 0.9.15 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= irc ruby MASTER_SITES= http://ruby-rbot.org/download/ EXTRACT_SUFX= .tgz @@ -23,16 +23,16 @@ SUB_FILES= pkg-message PORTDOCS= REQUIREMENTS ChangeLog -.include <bsd.port.pre.mk> +.include <bsd.port.options.mk> pre-install: ${RM} ${WRKSRC}/bin/svnwatch-postcommit-hook post-install: -.if !defined(NOPORTDOCS) +.if ${PORT_OPTIONS:MDOCS} ${INSTALL} -d ${DOCSDIR} ${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/,} ${DOCSDIR} .endif @${CAT} ${PKGMESSAGE} -.include <bsd.port.post.mk> +.include <bsd.port.mk> diff --git a/irc/rbot/files/patch-lib__rbot__load-gettext.rb b/irc/rbot/files/patch-lib__rbot__load-gettext.rb new file mode 100644 index 000000000000..69bb3e4d6eee --- /dev/null +++ b/irc/rbot/files/patch-lib__rbot__load-gettext.rb @@ -0,0 +1,26 @@ +commit 3342d4b9a510655d320590f7333f616355d0201d +Author: Giuseppe Bilotta <giuseppe.bilotta@gmail.com> +Date: Sat Jul 14 13:24:33 2012 +0200 + + Update gettext support + + Somewhere along the line between 2.0.0 and 2.2.1 gettext switched from + locale to lang for the hash key name. Support both. + +diff --git lib/rbot/load-gettext.rb lib/rbot/load-gettext.rb +index ba9b09b..252e1e3 100644 +--- lib/rbot/load-gettext.rb ++++ lib/rbot/load-gettext.rb +@@ -29,7 +29,11 @@ class ::Array + + include GetText + +- rbot_locale_path = File.join(Irc::Bot::Config.datadir, "../locale/%{locale}/LC_MESSAGES/%{name}.mo") ++ rbot_locale_path = File.join(Irc::Bot::Config.datadir, ++ gettext_version < [2, 2, 0] ? ++ "../locale/%{locale}/LC_MESSAGES/%{name}.mo" : ++ "../locale/%{lang}/LC_MESSAGES/%{name}.mo") ++ + if gettext_version < [2, 0, 0] + add_default_locale_path(rbot_locale_path) + else |