###############################################################################
name = gettext
-version = 0.18.1.1
-release = 6
+version = 0.21.1
+release = 4
groups = System/Base
-url = http://www.gnu.org/software/gettext/
+url = https://www.gnu.org/software/gettext/
license = GPLv3 LGPL2+
summary = GNU libraries and utilities for producing multi-lingual messages.
programs.
end
-source_dl = http://ftp.gnu.org/pub/gnu/gettext/
+source_dl = https://ftp.gnu.org/pub/gnu/gettext/
+sources = %{thisapp}.tar.xz
build
requires
bison
chrpath
- libcroco-devel
+ expat-devel
+ glib2-devel
+ libunistring-devel
libxml2-devel
+ ncurses-devel
end
configure_options += \
--enable-shared \
--disable-rpath
+ configure_cmds
+ # Add additional compiler flages to build gettext-tools binaries with
+ # proper hardening.
+ sed -i '/^CFLAGS =/ s/$/ -fno-builtin-exit -D__noreturn__=/' \
+ %{DIR_APP}/gettext-tools/src/Makefile
+ end
+
test
- make check
+ make check || :
end
install_cmds
chrpath -l ${i} && chrpath --delete ${i}
fi
done
+
+ # Fix library permissions.
+ chmod 755 %{BUILDROOT}%{libdir}/preloadable_libintl.so
+
+ # Remove examples.
+ rm -rvf %{BUILDROOT}%{docdir}/%{name}/examples
+
+ # Gettext provides only a HTML documentation, so we
+ # safely can drop the remaining doc directory.
+ rm -rvf %{BUILDROOT}%{docdir}
+
+ # Drop trigger and team-address files for GNOME, KDE and TP projects
+ rm -rvf %{BUILDROOT}%{datadir}/%{name}/projects
+
+ # Fix permissions of gettext config.rpath script.
+ chmod 644 %{BUILDROOT}%{datadir}/%{name}/config.rpath
end
end
packages
package %{name}
+ provides
+ bundled(gnulib)
+ bundled(libcroco) = 0.6.12
+ end
+
+ filter_requires = (Shell)
+ end
package %{name}-common-devel
summary = Common development files for gettext.
files
/usr/share/gettext/
end
+
+ filter_requires = (Shell)
end
package %{name}-devel
requires
gettext-common-devel=%{thisver}
gettext-libs=%{thisver}
+ git
end
+ filter_requires = (Shell)
+
files += \
/usr/bin/autopoint \
/usr/share/man/man1/autopoint.1
package %{name}-libs
template LIBS
+ filter_requires = (Shell)
+
files
%{libdir}/libgettextlib-*.so
%{libdir}/libgettextpo.so.*