%bcond_without asprintf # libasprintf C++ library
%bcond_with xemacs # po-mode for xemacs
%bcond_without java # convenience bcond to disable Java (any)
-%bcond_without gcj # Java support by gcj (preferred over javac)
-%bcond_with javac # Java support by some javac
+%bcond_with gcj # Java support by gcj (preferred over javac)
+%bcond_without javac # Java support by some javac
%bcond_without dotnet # .NET support package
%bcond_with bootstrap # no system GLib and libcroco (for bootstrap)
Summary(uk.UTF-8): Бібліотеки та утиліти для підтримки національних мов
Name: gettext
Version: 0.19.8.1
-Release: 5
+Release: 6
License: LGPL v2+ (libintl), GPL v3+ (tools)
Group: Development/Tools
Source0: http://ftp.gnu.org/gnu/gettext/%{name}-%{version}.tar.lz
Patch1: %{name}-killkillkill.patch
Patch2: %{name}-libintl_by_gcj.patch
Patch3: %{name}-libdir.patch
+Patch4: perlre.patch
+Patch5: java.patch
URL: http://www.gnu.org/software/gettext/
BuildRequires: acl-devel
BuildRequires: autoconf >= 2.62
%patch1 -p1
%patch2 -p1
%patch3 -p1
+%patch4 -p1
+%patch5 -p1
%{__sed} -i \
-e 's@m4_esyscmd(\[build-aux/git-version-gen \.tarball-version\])@[%{version}]@' \
--- /dev/null
+--- gettext-0.19.8.1/gettext-tools/gnulib-m4/javacomp.m4~ 2016-06-11 15:00:03.000000000 +0200
++++ gettext-0.19.8.1/gettext-tools/gnulib-m4/javacomp.m4 2017-09-03 12:02:50.751509338 +0200
+@@ -99,7 +99,7 @@
+ CLASSPATH=.${CLASSPATH:+$CLASSPATH_SEPARATOR$CLASSPATH} $CONF_JAVA conftestver 2>&AS_MESSAGE_LOG_FD
+ }`
+ case "$target_version" in
+- 1.1 | 1.2 | 1.3 | 1.4 | 1.5 | 1.6) ;;
++ 1.1 | 1.2 | 1.3 | 1.4 | 1.5 | 1.6 | 1.7 | 1.8) ;;
+ null)
+ dnl JDK 1.1.X returns null.
+ target_version=1.1 ;;
+@@ -127,6 +127,8 @@
+ 1.4) cfversion=48 ;;
+ 1.5) cfversion=49 ;;
+ 1.6) cfversion=50 ;;
++ 1.7) cfversion=51 ;;
++ 1.8) cfversion=52 ;;
+ *) AC_MSG_ERROR([invalid target-version argument to gt_@&t@JAVACOMP: $target_version]) ;;
+ esac
+ # Function to output the classfile version of a file (8th byte) in decimal.
--- /dev/null
+--- gettext-0.19.8.1/gettext-runtime/libasprintf/texi2html.orig 2015-12-08 13:50:04.000000000 +0100
++++ gettext-0.19.8.1/gettext-runtime/libasprintf/texi2html 2017-09-03 11:56:03.019241853 +0200
+@@ -879,7 +879,7 @@
+ s/\@refill\s+//g;
+ # other substitutions
+ &simple_substitutions;
+- s/\@value{($VARRE)}/$value{$1}/eg;
++ s/\@value\{($VARRE)\}/$value{$1}/eg;
+ s/\@footnote\{/\@footnote$docu_doc\{/g; # mark footnotes, cf. pass 4
+ #
+ # analyze the tag again
+@@ -1204,7 +1204,7 @@
+ #
+ # xref
+ #
+- while (/\@(x|px|info|)ref{($XREFRE)(}?)/o) {
++ while (/\@(x|px|info|)ref\{($XREFRE)(\}?)/o) {
+ # note: Texinfo may accept other characters
+ ($type, $nodes, $full) = ($1, $2, $3);
+ ($before, $after) = ($`, $');
+@@ -1810,7 +1810,7 @@
+ while ($changed) {
+ $changed = 0;
+ $done = '';
+- while (/\@(\w+|"|\~|,|\^){([^\{\}]+)}/) {
++ while (/\@\(\w+|"|\~|,|\^\)\{([^\{\}]+)\}/) {
+ $text = &apply_style($1, $2);
+ if ($text) {
+ $_ = "$`$text$'";
+--- gettext-0.19.8.1/gettext-tools/doc/texi2html.orig 2017-09-03 11:56:41.053102137 +0200
++++ gettext-0.19.8.1/gettext-tools/doc/texi2html 2017-09-03 11:57:44.060639306 +0200
+@@ -879,7 +879,7 @@
+ s/\@refill\s+//g;
+ # other substitutions
+ &simple_substitutions;
+- s/\@value{($VARRE)}/$value{$1}/eg;
++ s/\@value\{($VARRE)\}/$value{$1}/eg;
+ s/\@footnote\{/\@footnote$docu_doc\{/g; # mark footnotes, cf. pass 4
+ #
+ # analyze the tag again
+@@ -1204,7 +1204,7 @@
+ #
+ # xref
+ #
+- while (/\@(x|px|info|)ref{($XREFRE)(}?)/o) {
++ while (/\@(x|px|info|)ref\{($XREFRE)(\}?)/o) {
+ # note: Texinfo may accept other characters
+ ($type, $nodes, $full) = ($1, $2, $3);
+ ($before, $after) = ($`, $');
+@@ -1810,7 +1810,7 @@
+ while ($changed) {
+ $changed = 0;
+ $done = '';
+- while (/\@(\w+|"|\~|,|\^){([^\{\}]+)}/) {
++ while (/\@(\w+|"|\~|,|\^)\{([^\{\}]+)\}/) {
+ $text = &apply_style($1, $2);
+ if ($text) {
+ $_ = "$`$text$'";