Update to 2.0.6

Signed-off-by: Igor Gnatenko <ignatenkobrain@fedoraproject.org>
This commit is contained in:
Igor Gnatenko 2017-09-23 10:19:51 +02:00
parent 9c75887d5d
commit 106ce7003a
5 changed files with 16 additions and 98 deletions

1
.gitignore vendored
View File

@ -4,3 +4,4 @@
/SDL2-2.0.3.tar.gz
/SDL2-2.0.4.tar.gz
/SDL2-2.0.5.tar.gz
/SDL2-2.0.6.tar.gz

View File

@ -1,45 +0,0 @@
# HG changeset patch
# User Sam Lantinga <slouken@libsdl.org>
# Date 1477183983 25200
# Node ID fbf9b0e3589a1f88e2eefbbeb3b632e2da795fde
# Parent 5184186d4366169617b434f5b71c618a7035cde4
Fixed NULL pointer dereference, thanks Ozkan Sezer
diff -r 5184186d4366 -r fbf9b0e3589a src/video/SDL_blit_N.c
--- a/src/video/SDL_blit_N.c Sat Oct 22 11:01:55 2016 -0700
+++ b/src/video/SDL_blit_N.c Sat Oct 22 17:53:03 2016 -0700
@@ -125,11 +125,7 @@
0x0C);
vector unsigned char vswiz;
vector unsigned int srcvec;
-#define RESHIFT(X) (3 - ((X) >> 3))
- Uint32 rmask = RESHIFT(srcfmt->Rshift) << (dstfmt->Rshift);
- Uint32 gmask = RESHIFT(srcfmt->Gshift) << (dstfmt->Gshift);
- Uint32 bmask = RESHIFT(srcfmt->Bshift) << (dstfmt->Bshift);
- Uint32 amask;
+ Uint32 rmask, gmask, bmask, amask;
if (!srcfmt) {
srcfmt = &default_pixel_format;
@@ -138,6 +134,11 @@
dstfmt = &default_pixel_format;
}
+#define RESHIFT(X) (3 - ((X) >> 3))
+ rmask = RESHIFT(srcfmt->Rshift) << (dstfmt->Rshift);
+ gmask = RESHIFT(srcfmt->Gshift) << (dstfmt->Gshift);
+ bmask = RESHIFT(srcfmt->Bshift) << (dstfmt->Bshift);
+
/* Use zero for alpha if either surface doesn't have alpha */
if (dstfmt->Amask) {
amask =
@@ -149,6 +150,7 @@
0xFFFFFFFF);
}
#undef RESHIFT
+
((unsigned int *) (char *) &srcvec)[0] = (rmask | gmask | bmask | amask);
vswiz = vec_add(plus, (vector unsigned char) vec_splat(srcvec, 0));
return (vswiz);

View File

@ -1,45 +0,0 @@
# HG changeset patch
# User Sam Lantinga <slouken@libsdl.org>
# Date 1477159315 25200
# Node ID 5184186d4366169617b434f5b71c618a7035cde4
# Parent 71d4148e32de5088c4bc2f04c1e5ded647a2bf82
Fixed bug 3466 - Can't build 2.0.5 on ppc64
/home/fedora/SDL2-2.0.5/src/video/SDL_blit_N.c: In function 'calc_swizzle32':
/home/fedora/SDL2-2.0.5/src/video/SDL_blit_N.c:127:5: error: ISO C90 forbids mixed declarations and code [-Werror=declaration-after-statement]
const vector unsigned char plus = VECUINT8_LITERAL(0x00, 0x00, 0x00, 0x00,
^
diff -r 71d4148e32de -r 5184186d4366 src/video/SDL_blit_N.c
--- a/src/video/SDL_blit_N.c Wed Oct 19 21:22:42 2016 -0700
+++ b/src/video/SDL_blit_N.c Sat Oct 22 11:01:55 2016 -0700
@@ -118,12 +118,6 @@
16, 8, 0, 24,
0, NULL
};
- if (!srcfmt) {
- srcfmt = &default_pixel_format;
- }
- if (!dstfmt) {
- dstfmt = &default_pixel_format;
- }
const vector unsigned char plus = VECUINT8_LITERAL(0x00, 0x00, 0x00, 0x00,
0x04, 0x04, 0x04, 0x04,
0x08, 0x08, 0x08, 0x08,
@@ -136,6 +130,14 @@
Uint32 gmask = RESHIFT(srcfmt->Gshift) << (dstfmt->Gshift);
Uint32 bmask = RESHIFT(srcfmt->Bshift) << (dstfmt->Bshift);
Uint32 amask;
+
+ if (!srcfmt) {
+ srcfmt = &default_pixel_format;
+ }
+ if (!dstfmt) {
+ dstfmt = &default_pixel_format;
+ }
+
/* Use zero for alpha if either surface doesn't have alpha */
if (dstfmt->Amask) {
amask =

View File

@ -1,6 +1,6 @@
Name: SDL2
Version: 2.0.5
Release: 6%{?dist}
Version: 2.0.6
Release: 1%{?dist}
Summary: A cross-platform multimedia library
License: zlib and MIT
@ -9,10 +9,6 @@ Source0: http://www.libsdl.org/release/%{name}-%{version}.tar.gz
Source1: SDL_config.h
Patch0: multilib.patch
# https://hg.libsdl.org/SDL/rev/5184186d4366
Patch1: %{name}-2.0.5-ppc.patch
# https://hg.libsdl.org/SDL/rev/fbf9b0e3589a
Patch2: %{name}-2.0.5-null-deref.patch
BuildRequires: alsa-lib-devel
BuildRequires: audiofile-devel
@ -32,6 +28,8 @@ BuildRequires: libXcursor-devel
BuildRequires: systemd-devel
# PulseAudio
BuildRequires: pkgconfig(libpulse-simple)
# Jack
BuildRequires: pkgconfig(jack)
# D-Bus
BuildRequires: pkgconfig(dbus-1)
# IBus
@ -43,6 +41,8 @@ BuildRequires: pkgconfig(wayland-cursor)
BuildRequires: pkgconfig(wayland-protocols)
BuildRequires: pkgconfig(wayland-scanner)
BuildRequires: pkgconfig(xkbcommon)
# Vulkan
BuildRequires: vulkan-devel
%description
Simple DirectMedia Layer (SDL) is a cross-platform multimedia library designed
@ -80,8 +80,12 @@ sed -i -e 's/\r//g' TODO.txt README.txt WhatsNew.txt BUGS.txt COPYING.txt CREDIT
--disable-esd \
--disable-nas \
--enable-pulseaudio-shared \
--enable-jack-shared \
--enable-alsa \
--enable-video-wayland \
--enable-video-vulkan \
--enable-sse2=no \
--enable-sse3=no \
--disable-rpath
make %{?_smp_mflags}
@ -94,7 +98,7 @@ mv %{buildroot}%{_includedir}/SDL2/SDL_config.h %{buildroot}%{_includedir}/SDL2/
install -p -m 644 %{SOURCE1} %{buildroot}%{_includedir}/SDL2/SDL_config.h
# remove libtool .la file
rm -f %{buildroot}%{_libdir}/*.la
rm -vf %{buildroot}%{_libdir}/*.la
# remove static .a file
# rm -f %{buildroot}%{_libdir}/*.a
@ -121,6 +125,9 @@ rm -f %{buildroot}%{_libdir}/*.la
%{_libdir}/lib*.a
%changelog
* Sat Sep 23 2017 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 2.0.6-1
- Update to 2.0.6
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.5-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild

View File

@ -1 +1 @@
d4055424d556b4a908aa76fad63abd3c SDL2-2.0.5.tar.gz
SHA512 (SDL2-2.0.6.tar.gz) = ad4dad5663834ee0ffbdca1b531d753449b260c9256df2c48da7261aacd9795d91eef1286525cf914f6b92ba5985de7798f041557574b5d978b8224f10041830