rpms/fceux/F-17 fceux-2.1.5-datatype-gz.patch, NONE, 1.1 fceux-2.1.5-gcc47.patch, NONE, 1.1 fceux-2.1.5-minizip.patch, NONE, 1.1 fceux-2.1.5-underlink.patch, NONE, 1.1 fceux.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Andrea Musuruane musuruan at rpmfusion.org
Tue May 1 11:47:08 CEST 2012


Author: musuruan

Update of /cvs/free/rpms/fceux/F-17
In directory old02.ovh.rpmfusion.lan:/tmp/cvs-serv26725/F-17

Modified Files:
	.cvsignore sources 
Added Files:
	fceux-2.1.5-datatype-gz.patch fceux-2.1.5-gcc47.patch 
	fceux-2.1.5-minizip.patch fceux-2.1.5-underlink.patch 
	fceux.spec 
Log Message:
First import


fceux-2.1.5-datatype-gz.patch:
 file.cpp |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- NEW FILE fceux-2.1.5-datatype-gz.patch ---
diff -Naur a/fceu2.1.5/src/file.cpp b/fceu2.1.5/src/file.cpp
--- a/fceu2.1.5/src/file.cpp	2010-09-19 00:05:09.000000000 +0000
+++ b/fceu2.1.5/src/file.cpp	2012-03-01 19:21:25.856204727 +0000
@@ -310,7 +310,7 @@
 				if(magic==0x088b1f) {
 					 // maybe gzip... 
 
-					void* gzfile = gzopen(fileToOpen.c_str(),"rb");
+					gzFile gzfile = gzopen(fileToOpen.c_str(),"rb");
 					if(gzfile) {
 						delete fp;
 

fceux-2.1.5-gcc47.patch:
 endian.h |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

--- NEW FILE fceux-2.1.5-gcc47.patch ---
--- fceu/src/utils/endian.h	2010/11/07 23:33:11	2078
+++ fceu/src/utils/endian.h	2012/04/07 18:33:25	2484
@@ -98,10 +98,10 @@
 {
 	CTASSERT(sizeof(T)==1||sizeof(T)==2||sizeof(T)==4||sizeof(T)==8);
 	switch(sizeof(T)) {
-		case 1: return write8le((uint8*)Bufo,os);
-		case 2: return write16le((uint16*)Bufo,os);
-		case 4: return write32le((uint32*)Bufo,os);
-		case 8: return write64le((uint64*)Bufo,os);
+		case 1: return write8le(*(uint8*)Bufo,os);
+		case 2: return write16le(*(uint16*)Bufo,os);
+		case 4: return write32le(*(uint32*)Bufo,os);
+		case 8: return write64le(*(uint64*)Bufo,os);
 		default:
 			return 0;
 	}

fceux-2.1.5-minizip.patch:
 SConstruct   |    2 +-
 src/file.cpp |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

--- NEW FILE fceux-2.1.5-minizip.patch ---
diff -durN fceu2.1.5.orig/SConstruct fceu2.1.5/SConstruct
--- fceu2.1.5.orig/SConstruct	2011-06-04 07:26:55.000000000 +0200
+++ fceu2.1.5/SConstruct	2012-04-22 17:23:42.728386552 +0200
@@ -55,7 +55,7 @@
   env.Append(LIBS = ["rpcrt4", "comctl32", "vfw32", "winmm", "ws2_32", "comdlg32", "ole32", "gdi32", "htmlhelp"])
 else:
   conf = Configure(env)
-  assert conf.CheckLibWithHeader('z', 'zlib.h', 'C', 'inflate;', 1), "please install: zlib"
+  assert conf.CheckLibWithHeader('minizip', 'minizip/unzip.h', 'C', 'unzOpen;', 1), "please install: libminizip"
   if not conf.CheckLib('SDL'):
     print 'Did not find libSDL or SDL.lib, exiting!'
     Exit(1)
diff -durN fceu2.1.5.orig/src/file.cpp fceu2.1.5/src/file.cpp
--- fceu2.1.5.orig/src/file.cpp	2010-09-19 02:05:09.000000000 +0200
+++ fceu2.1.5/src/file.cpp	2012-04-22 17:12:06.870780995 +0200
@@ -36,7 +36,7 @@
 #include "utils/endian.h"
 #include "utils/memory.h"
 #include "utils/md5.h"
-#include "utils/unzip.h"
+#include <minizip/unzip.h>
 #include "driver.h"
 #include "types.h"
 #include "fceu.h"

fceux-2.1.5-underlink.patch:
 SConstruct |    4 ++++
 1 file changed, 4 insertions(+)

--- NEW FILE fceux-2.1.5-underlink.patch ---
--- SConstruct.org	2011-06-07 21:33:28.876609681 +0200
+++ SConstruct	2011-06-07 21:34:11.420368249 +0200
@@ -70,6 +70,10 @@
     env.ParseConfig('pkg-config --cflags --libs gtk+-3.0')
     env.Append(CPPDEFINES=["_GTK3"])
     env.Append(CCFLAGS = ["-D_GTK"])
+  env.Append(LIBS =["-lz"])
+  env.Append(LIBS =["-ldl"])
+  env.Append(LIBS =["-lX11"])
+
   ### Lua platform defines
   ### Applies to all files even though only lua needs it, but should be ok
   if env['LUA']:


--- NEW FILE fceux.spec ---
Name:           fceux
Version:        2.1.5
Release:        2%{?dist}
Summary:        A cross platform, NTSC and PAL Famicom/NES emulator

Group:          Applications/Emulators
License:        GPLv2+
URL:            http://fceux.com/
Source:         http://downloads.sourceforge.net/fceultra/%{name}-%{version}.src.tar.bz2
# Fix compiling
# https://bugs.gentoo.org/show_bug.cgi?id=406471
# Upstream SVN rev 2395
Patch0:         %{name}-2.1.5-datatype-gz.patch
# Fix underlinking
# https://bugs.gentoo.org/show_bug.cgi?id=367675
# http://sourceforge.net/tracker/?func=detail&aid=3522221&group_id=13536&atid=113536
Patch1:         %{name}-2.1.5-underlink.patch
# Use system minizip
# https://sourceforge.net/tracker/?func=detail&aid=3520369&group_id=13536&atid=113536
Patch2:         %{name}-2.1.5-minizip.patch
# Fix compiling with GCC 4.7
# Upstream SVN rev 2484
Patch3:         %{name}-2.1.5-gcc47.patch

BuildRequires:  scons
BuildRequires:  SDL-devel >= 1.2.14
BuildRequires:  gtk2-devel >= 2.18
BuildRequires:  gd-devel
BuildRequires:  minizip-devel
BuildRequires:  desktop-file-utils
Requires:       hicolor-icon-theme
Provides:       fceultra = %{version}-%{release}
Obsoletes:      fceultra < 2.0.0
Provides:       gfceu = %{version}-%{release}
Obsoletes:      gfceu <= 0.6.2


%description
FCEUX is a cross platform, NTSC and PAL Famicom/NES emulator that is an
evolution of the original FCE Ultra emulator. Over time FCE Ultra had
separated into many separate branches.

The concept behind FCEUX is to merge elements from FCE Ultra, FCEU
rerecording, FCEUXD, FCEUXDSP, and FCEU-mm into a single branch of FCEU. As
the X implies, it is an all-encompassing FCEU emulator that gives the best
of all worlds for the casual player, the ROM-hacking community, Lua
Scripters, and the Tool-Assisted Speedrun Community.


%prep
%setup -q -n fceu%{version}
%patch0 -p2
%patch1 -p0
%patch2 -p1
%patch3 -p1

# Remove binary files
rm -rf bin/fceux
rm -rf src/fceux

# Remove bundled LUA library
rm -rf src/lua
sed -i 's/^lua//' src/SConscript

# Remove bundled minizip library
rm -rf src/utils/unzip.*
sed -i 's/^unzip.cpp//' src/utils/SConscript

# Remove default CFLAGS
sed -i 's/^env.Append(CCFLAGS/#env.Append(CCFLAGS/' SConstruct

# Fix end-of-line-encoding
sed -i 's/\r//' Authors.txt changelog.txt TODO-PROJECT \
  documentation/Videolog.txt

# Fix icon path in desktop file
sed -i 's/\/usr\/share\/pixmaps\/fceux.png/fceux/' fceux.desktop


%build
export CFLAGS="%{optflags}"
# Disable LUA support
# Enable AVI creation
scons %{?_smp_mflags} \
  LUA=0 \
  CREATE_AVI=1


%install
# Install binary file
install -d %{buildroot}%{_bindir}
install -p -m 755 src/fceux %{buildroot}%{_bindir}

# Install icon
install -d %{buildroot}%{_datadir}/icons/hicolor/32x32/apps
install -p -m 644 %{name}.png \
  %{buildroot}%{_datadir}/icons/hicolor/32x32/apps/%{name}.png

# Install desktop file
desktop-file-install \
  --dir %{buildroot}%{_datadir}/applications \
  %{name}.desktop

# Install man page
install -d %{buildroot}%{_mandir}/man6
install -p -m 644 documentation/%{name}.6 \
  %{buildroot}%{_mandir}/man6/%{name}.6


%post
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :


%postun
if [ $1 -eq 0 ] ; then
    /bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
    /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
fi


%posttrans
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :


%files
%{_bindir}/fceux
%{_datadir}/applications/%{name}.desktop
%{_datadir}/icons/hicolor/*/apps/%{name}.png
%{_mandir}/man6/%{name}.6*
%doc Authors.txt changelog.txt COPYING README-SDL TODO-PROJECT TODO-SDL
%doc documentation/{cheat.html,faq,todo,Videolog.txt}


%changelog
* Sat Apr 28 2012 Andrea Musuruane <musuruan at gmail.com> 2.1.5-2
- Obsoleted gfceu too
- Notified upstream about underlinking

* Sun Apr 22 2012 Andrea Musuruane <musuruan at gmail.com> 2.1.5-1
- First release for RPM Fusion
- LUA support is disabled because fceux uses a private header file
- Reused Gentoo and upstream patches
- Made a patch not to use the bundled minizip library



Index: .cvsignore
===================================================================
RCS file: /cvs/free/rpms/fceux/F-17/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	30 Apr 2012 17:44:30 -0000	1.1
+++ .cvsignore	1 May 2012 09:47:08 -0000	1.2
@@ -0,0 +1 @@
+fceux-2.1.5.src.tar.bz2


Index: sources
===================================================================
RCS file: /cvs/free/rpms/fceux/F-17/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	30 Apr 2012 17:44:30 -0000	1.1
+++ sources	1 May 2012 09:47:08 -0000	1.2
@@ -0,0 +1 @@
+e8b20e62bbbb061b1a59d51b47c827bd  fceux-2.1.5.src.tar.bz2


More information about the rpmfusion-commits mailing list