fix build against libpng 1.5
This commit is contained in:
parent
6475f3984d
commit
a5c9180a97
|
@ -0,0 +1,32 @@
|
|||
diff -up slashem-0.0.8E0F1/win/gl/gl_image.c.libpng slashem-0.0.8E0F1/win/gl/gl_image.c
|
||||
--- slashem-0.0.8E0F1/win/gl/gl_image.c.libpng 2006-12-30 14:04:53.000000000 +0100
|
||||
+++ slashem-0.0.8E0F1/win/gl/gl_image.c 2012-01-15 01:13:55.000000000 +0100
|
||||
@@ -495,7 +495,7 @@ unsigned char *sdlgl_load_png_file(const
|
||||
/* set error handling since we are using the setjmp/longjmp method
|
||||
* (this is the normal method of doing things with libpng).
|
||||
*/
|
||||
- if (setjmp(png_ptr->jmpbuf))
|
||||
+ if (setjmp(png_jmpbuf(png_ptr)))
|
||||
{
|
||||
sdlgl_warning("Problem within LibPNG (unknown)\n");
|
||||
goto failed;
|
||||
diff -up slashem-0.0.8E0F1/win/share/tile2png.c.libpng slashem-0.0.8E0F1/win/share/tile2png.c
|
||||
--- slashem-0.0.8E0F1/win/share/tile2png.c.libpng 2012-01-15 01:14:08.000000000 +0100
|
||||
+++ slashem-0.0.8E0F1/win/share/tile2png.c 2012-01-15 01:25:02.000000000 +0100
|
||||
@@ -26,6 +26,7 @@
|
||||
#undef blue
|
||||
|
||||
#include <png.h>
|
||||
+#include <zlib.h>
|
||||
#include <assert.h>
|
||||
|
||||
|
||||
@@ -104,7 +105,7 @@ void save_png(const char *filename, int
|
||||
/* set error handling since we are using the setjmp/longjmp method
|
||||
* (this is the normal method of doing things with libpng).
|
||||
*/
|
||||
- if (setjmp(png_ptr->jmpbuf))
|
||||
+ if (setjmp(png_jmpbuf(png_ptr)))
|
||||
{
|
||||
fprintf(stderr, "tile2png: Unknown problem while writing PNG.\n");
|
||||
goto failed;
|
10
slashem.spec
10
slashem.spec
|
@ -1,6 +1,6 @@
|
|||
Name: slashem
|
||||
Version: 0.0.8
|
||||
Release: 0.7.E0F1%{?dist}
|
||||
Release: 0.8.E0F1%{?dist}
|
||||
Summary: Super Lotsa Added Stuff Hack - Extended Magic
|
||||
|
||||
Group: Amusements/Games
|
||||
|
@ -9,13 +9,15 @@ URL: http://slashem.sourceforge.net/
|
|||
Source0: http://downloads.sourceforge.net/slashem/se008e0f1.tar.gz
|
||||
Source1: %{name}.desktop
|
||||
Patch0: slashem-config.patch
|
||||
# fix building with libpng 1.5
|
||||
Patch1: slashem-libpng-1.5.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||
|
||||
BuildRequires: ncurses-devel
|
||||
BuildRequires: bison, flex, desktop-file-utils
|
||||
BuildRequires: bdftopcf, libX11-devel, libXaw-devel, libXext-devel
|
||||
BuildRequires: libXmu-devel, libXpm-devel, libXt-devel
|
||||
BuildRequires: SDL-devel libGL-devel libpng-devel
|
||||
BuildRequires: SDL-devel libGL-devel libpng-devel zlib-devel
|
||||
# to compress save files
|
||||
Requires: bzip2
|
||||
# for X11 core fonts
|
||||
|
@ -50,6 +52,7 @@ SLASH'EM is the (continuing) saga of one such variant...
|
|||
%prep
|
||||
%setup -q -n %{name}-%{version}E0F1
|
||||
%patch0 -p 1 -b .config
|
||||
%patch1 -p 1 -b .libpng
|
||||
|
||||
sed -i \
|
||||
-e 's:^\(#define FILE_AREA_VAR\).*:\1 "%{fa_var}/":' \
|
||||
|
@ -150,6 +153,9 @@ rm -rf %{buildroot}
|
|||
|
||||
|
||||
%changelog
|
||||
* Sun Jan 15 2012 Iain Arnell <iarnell@gmail.com> 0.0.8-0.8.E0F1
|
||||
- fix build against libpng 1.5
|
||||
|
||||
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.8-0.7.E0F1
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
|
||||
|
||||
|
|
Loading…
Reference in New Issue