[packages/gettext] - dropped *.la files - patched to build with glibc-2.16 (dropped gets declaration) - rel. 9

kiesiu kiesiu at pld-linux.org
Wed Aug 22 08:50:54 CEST 2012


commit f80b2eb30cf532468b1a42dcb44dea20909253a9
Author: Łukasz Kieś <kiesiu at pld-linux.org>
Date:   Wed Aug 22 08:49:07 2012 +0200

    - dropped *.la files
    - patched to build with glibc-2.16 (dropped gets declaration)
    - rel. 9

 gettext.spec     | 14 ++++++++------
 stdio-gets.patch | 42 ++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 50 insertions(+), 6 deletions(-)
---
diff --git a/gettext.spec b/gettext.spec
index 2bb358b..a99939d 100644
--- a/gettext.spec
+++ b/gettext.spec
@@ -38,7 +38,7 @@ Summary(tr.UTF-8):	Desteği için kitaplık ve araçlar
 Summary(uk.UTF-8):	Бібліотеки та утиліти для підтримки національних мов
 Name:		gettext
 Version:	0.18.1.1
-Release:	8
+Release:	9
 License:	LGPL v2+ (libintl), GPL v3+ (tools)
 Group:		Development/Tools
 Source0:	http://ftp.gnu.org/gnu/gettext/%{name}-%{version}.tar.gz
@@ -47,6 +47,7 @@ Patch0:		%{name}-info.patch
 Patch1:		%{name}-killkillkill.patch
 Patch2:		%{name}-pl.po-fixes.patch
 Patch3:		%{name}-libintl_by_gcj.patch
+Patch4:		stdio-gets.patch
 URL:		http://www.gnu.org/software/gettext/
 BuildRequires:	acl-devel
 BuildRequires:	autoconf >= 2.62
@@ -331,6 +332,7 @@ GNU gettext dla C#.
 #done
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1
 
 %build
 %{__libtoolize}
@@ -392,9 +394,11 @@ mv -f $RPM_BUILD_ROOT%{_bindir}/{,n}gettext $RPM_BUILD_ROOT/bin
 cp -a gettext-tools/gnulib-lib/.libs/libgettextlib.a \
 	gettext-tools/src/.libs/libgettextsrc.a $RPM_BUILD_ROOT%{_libdir}
 
-rm -r $RPM_BUILD_ROOT%{_docdir}/gettext
-rm -r $RPM_BUILD_ROOT%{_docdir}/libasprintf
-rm -f $RPM_BUILD_ROOT%{_infodir}/dir
+%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/gettext
+%{__rm} -r $RPM_BUILD_ROOT%{_docdir}/libasprintf
+%{__rm} -f $RPM_BUILD_ROOT%{_infodir}/dir
+
+%{__rm} $RPM_BUILD_ROOT%{_libdir}/lib*.la
 
 %find_lang %{name}-runtime
 %find_lang %{name}-tools
@@ -443,7 +447,6 @@ rm -rf $RPM_BUILD_ROOT
 %attr(755,root,root) %{_bindir}/recode-sr-latin
 %attr(755,root,root) %{_bindir}/xgettext
 %attr(755,root,root) %{_libdir}/libgettext*.so
-%{_libdir}/libgettext*.la
 # libgettextpo is for other programs, not used by gettext tools themselves
 %attr(755,root,root) %{_libdir}/libgettextpo.so.*.*.*
 %attr(755,root,root) %ghost %{_libdir}/libgettextpo.so.0
@@ -500,7 +503,6 @@ rm -rf $RPM_BUILD_ROOT
 %files -n libasprintf-devel
 %defattr(644,root,root,755)
 %attr(755,root,root) %{_libdir}/libasprintf.so
-%{_libdir}/libasprintf.la
 %{_includedir}/autosprintf.h
 %{_infodir}/autosprintf.info*
 
diff --git a/stdio-gets.patch b/stdio-gets.patch
new file mode 100644
index 0000000..c929e41
--- /dev/null
+++ b/stdio-gets.patch
@@ -0,0 +1,42 @@
+diff -uNr gettext-0.18.1.1.bak/gettext-runtime/gnulib-lib/stdio.in.h gettext-0.18.1.1/gettext-runtime/gnulib-lib/stdio.in.h
+--- gettext-0.18.1.1.bak/gettext-runtime/gnulib-lib/stdio.in.h	2010-05-17 21:56:12.000000000 +0200
++++ gettext-0.18.1.1/gettext-runtime/gnulib-lib/stdio.in.h	2012-08-22 08:31:28.114684793 +0200
+@@ -140,8 +140,10 @@
+ /* It is very rare that the developer ever has full control of stdin,
+    so any use of gets warrants an unconditional warning.  Assume it is
+    always declared, since it is required by C89.  */
++#if defined gets
+ #undef gets
+ _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
++#endif
+ 
+ #if @GNULIB_FOPEN@
+ # if @REPLACE_FOPEN@
+diff -uNr gettext-0.18.1.1.bak/gettext-tools/gnulib-lib/stdio.in.h gettext-0.18.1.1/gettext-tools/gnulib-lib/stdio.in.h
+--- gettext-0.18.1.1.bak/gettext-tools/gnulib-lib/stdio.in.h	2010-05-24 11:42:46.000000000 +0200
++++ gettext-0.18.1.1/gettext-tools/gnulib-lib/stdio.in.h	2012-08-22 08:30:43.291594287 +0200
+@@ -140,8 +140,10 @@
+ /* It is very rare that the developer ever has full control of stdin,
+    so any use of gets warrants an unconditional warning.  Assume it is
+    always declared, since it is required by C89.  */
++#if defined gets
+ #undef gets
+ _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
++#endif
+ 
+ #if @GNULIB_FOPEN@
+ # if @REPLACE_FOPEN@
+diff -uNr gettext-0.18.1.1.bak/gettext-tools/libgettextpo/stdio.in.h gettext-0.18.1.1/gettext-tools/libgettextpo/stdio.in.h
+--- gettext-0.18.1.1.bak/gettext-tools/libgettextpo/stdio.in.h	2010-05-17 21:58:03.000000000 +0200
++++ gettext-0.18.1.1/gettext-tools/libgettextpo/stdio.in.h	2012-08-22 08:30:11.345100689 +0200
+@@ -140,8 +140,10 @@
+ /* It is very rare that the developer ever has full control of stdin,
+    so any use of gets warrants an unconditional warning.  Assume it is
+    always declared, since it is required by C89.  */
++#if defined gets
+ #undef gets
+ _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
++#endif
+ 
+ #if @GNULIB_FOPEN@
+ # if @REPLACE_FOPEN@


More information about the pld-cvs-commit mailing list