[-]
[+]
|
Added |
gdk-pixbuf.spec
|
|
[-]
[+]
|
Added |
u_contrib-gdk-pixbuf-xlib-Fix-rgb888amsb.patch
^
|
@@ -0,0 +1,68 @@
+From: Max Staudt <mstaudt@suse.de>
+Date: Fri Dec 9 14:26:34 2016 +0100
+Subject: [PATCH]contrib/gdk-pixbuf-xlib: Fix rgb888amsb()
+Patch-mainline: to be upstreamed
+Git-repo: git://git.gnome.org/gdk-pixbuf
+References: boo#929462 bsc#1010497
+Signed-off-by: Max Staudt <mstaudt@suse.de>
+
+On Little Endian, it wrote memory out of bounds (i.e. when running
+inside a little endian client, connecting to a big endian X server).
+
+On Big Endian, it only processed the first 1/4 of the icon.
+
+The effects can be seen when running IceWM. Running native on Big Endian
+ppc64 with a Big Endian X11 server, the icon background was 3/4 random:
+
+ https://bugzilla.suse.com/show_bug.cgi?id=929462
+
+This match makes rgb888amsb() behave analogously to rgb888msb().
+
+Signed-off-by: Max Staudt <mstaudt@suse.de>
+---
+ contrib/gdk-pixbuf-xlib/gdk-pixbuf-xlib-drawable.c | 15 ---------------
+ 1 file changed, 15 deletions(-)
+
+diff --git a/contrib/gdk-pixbuf-xlib/gdk-pixbuf-xlib-drawable.c b/contrib/gdk-pixbuf-xlib/gdk-pixbuf-xlib-drawable.c
+index 972c2be..422fdc8 100644
+--- a/contrib/gdk-pixbuf-xlib/gdk-pixbuf-xlib-drawable.c
++++ b/contrib/gdk-pixbuf-xlib/gdk-pixbuf-xlib-drawable.c
+@@ -915,13 +915,8 @@ rgb888amsb (XImage *image, guchar *pixels, int rowstride, xlib_colormap *colorma
+ int bpl;
+
+ guint8 *srow = (guint8 *)image->data, *orow = pixels;
+-#ifdef LITTLE
+- guint32 *o;
+- guint32 *s;
+-#else
+ guint8 *s; /* for byte order swapping */
+ guint8 *o;
+-#endif
+
+ d (printf ("32 bit, msb, with alpha\n"));
+
+@@ -931,24 +926,14 @@ rgb888amsb (XImage *image, guchar *pixels, int rowstride, xlib_colormap *colorma
+
+ /* msb data */
+ for (yy = 0; yy < height; yy++) {
+-#ifdef LITTLE
+- s = (guint32 *) srow;
+- o = (guint32 *) orow;
+-#else
+ s = srow;
+ o = orow;
+-#endif
+ for (xx = 0; xx < width; xx++) {
+-#ifdef LITTLE
+ *o++ = s[1];
+ *o++ = s[2];
+ *o++ = s[3];
+ *o++ = 0xff;
+ s += 4;
+-#else
+- *o++ = (*s << 8) | 0xff; /* untested */
+- s++;
+-#endif
+ }
+ srow += bpl;
+ orow += rowstride;
|
[-]
[+]
|
Added |
baselibs.conf
^
|
@@ -0,0 +1,18 @@
+gdk-pixbuf-devel
+ requires -gdk-pixbuf-<targettype>
+ requires "libgdk_pixbuf-2_0-0-<targettype> = <version>"
+gdk-pixbuf-query-loaders
+ +/usr/bin/gdk-pixbuf-query-loaders(-64)?
+ post "%if "%_lib" == "lib64""
+ post "if [ $1 == 1 ]; then test -d <prefix>%{_libdir}/gdk-pixbuf-2.0/2.10.0; if test $? -eq 0; then <prefix>%{_bindir}/gdk-pixbuf-query-loaders-64 --update-cache; fi; fi"
+ post "%else"
+ post "if [ $1 == 1 ]; then test -d <prefix>%{_libdir}/gdk-pixbuf-2.0/2.10.0; if test $? -eq 0; then <prefix>%{_bindir}/gdk-pixbuf-query-loaders --update-cache; fi; fi"
+ post "%endif"
+libgdk_pixbuf-2_0-0
+ requires "gdk-pixbuf-query-loaders-<targettype>"
+ provides "gdk-pixbuf-<targettype> = <version>"
+ post "%if "%_lib" == "lib64""
+ post "if test -f <prefix>%{_bindir}/gdk-pixbuf-query-loaders-64; then <prefix>%{_bindir}/gdk-pixbuf-query-loaders-64 --update-cache; fi"
+ post "%else"
+ post "if test -f <prefix>%{_bindir}/gdk-pixbuf-query-loaders; then <prefix>%{_bindir}/gdk-pixbuf-query-loaders --update-cache; fi"
+ post "%endif"
|
|
Added |
gdk-pixbuf-2.36.5.tar.xz
^
|
[-]
[+]
|
Added |
macros.gdk-pixbuf
^
|
@@ -0,0 +1,35 @@
+# RPM macros for packages installing a gdk-pixbuf loader
+#
+###
+#
+# When a package installs a gdk-pixbuf loader, it should use all
+# three macros:
+#
+# - %gdk_pixbuf_loader_requires in the preamble
+# - %gdk_pixbuf_loader_post in %post
+# - %gdk_pixbuf_loader_postun in %postun
+#
+###
+
+%gdk_pixbuf_loader_requires \
+Requires(post): gdk-pixbuf-query-loaders \
+Requires(postun): gdk-pixbuf-query-loaders
+
+# On install, update the cache
+%gdk_pixbuf_loader_post \
+%if "%_lib" == "lib64" \
+ %{_bindir}/gdk-pixbuf-query-loaders-64 --update-cache \
+%else \
+ %{_bindir}/gdk-pixbuf-query-loaders --update-cache \
+%endif
+
+# On uninstall, update the cache. Note: we ignore upgrades (already
+# handled in %post of the new package).
+%gdk_pixbuf_loader_postun \
+if [ $1 -eq 0 ]; then \
+ %if "%_lib" == "lib64" \
+ %{_bindir}/gdk-pixbuf-query-loaders-64 --update-cache \
+ %else \
+ %{_bindir}/gdk-pixbuf-query-loaders --update-cache \
+ %endif \
+fi
|