Author: belegdol
Update of /cvs/free/rpms/bsnes/F-14
In directory se02.es.rpmfusion.net:/tmp/cvs-serv453
Modified Files:
.cvsignore README.bsnes bsnes.spec sources
Added Files:
bsnes-0.079-gcc46.patch bsnes-0.079-gtk.patch
bsnes-0.079-systemwide.patch
Removed Files:
bsnes-0.064-systemlibs.patch bsnes-0.068-newppcelf.patch
bsnes-0.068-noppcelfppc64.patch bsnes-0.072-nocheats.patch
Log Message:
* Tue Jun 21 2011 Julian Sikorski <belegdol(a)fedoraproject.org> - 0.079-1
- Updated to 0.079
- Dropped subpackages, they are too small to be worth it
- Updated the Fedora readme
- Added gcc-4.6 and systemwide patches by Themaister
- Try to handle system-wide cheats, filters and shaders properly
- Switched to accuracy profile (slower)
- Switched to gtk ui
bsnes-0.079-gcc46.patch:
snes/chip/icd2/interface/interface.cpp | 2 +-
ui/input/input.cpp | 8 ++++----
2 files changed, 5 insertions(+), 5 deletions(-)
--- NEW FILE bsnes-0.079-gcc46.patch ---
diff -up bsnes_v079-source/bsnes/snes/chip/icd2/interface/interface.cpp.gcc46
bsnes_v079-source/bsnes/snes/chip/icd2/interface/interface.cpp
--- bsnes_v079-source/bsnes/snes/chip/icd2/interface/interface.cpp.gcc46 2011-05-08
13:14:20.000000000 +0200
+++ bsnes_v079-source/bsnes/snes/chip/icd2/interface/interface.cpp 2011-06-21
00:02:22.972853738 +0200
@@ -101,7 +101,7 @@ bool ICD2::input_poll(unsigned id) {
case 3: data = ~r6007; break;
}
- switch(id) {
+ switch((GameBoy::Input)id) {
case GameBoy::Input::Start: return data & 0x80;
case GameBoy::Input::Select: return data & 0x40;
case GameBoy::Input::B: return data & 0x20;
diff -up bsnes_v079-source/bsnes/ui/input/input.cpp.gcc46
bsnes_v079-source/bsnes/ui/input/input.cpp
--- bsnes_v079-source/bsnes/ui/input/input.cpp.gcc46 2011-03-24 19:33:58.000000000 +0100
+++ bsnes_v079-source/bsnes/ui/input/input.cpp 2011-06-21 00:02:22.971853731 +0200
@@ -82,7 +82,7 @@ void InputMapper::Gamepad::create(const
}
int16_t InputMapper::Gamepad::poll(unsigned id) {
- switch(id) {
+ switch((SNES::Input::JoypadID)id) {
case SNES::Input::JoypadID::Up: return up.poll();
case SNES::Input::JoypadID::Down: return down.poll() & !up.poll();
case SNES::Input::JoypadID::Left: return left.poll();
@@ -118,7 +118,7 @@ void InputMapper::Mouse::create(const ch
}
int16_t InputMapper::Mouse::poll(unsigned id) {
- switch(id) {
+ switch((SNES::Input::MouseID)id) {
case SNES::Input::MouseID::X: return x.poll();
case SNES::Input::MouseID::Y: return y.poll();
case SNES::Input::MouseID::Left: return left.poll();
@@ -150,7 +150,7 @@ void InputMapper::SuperScope::create(con
}
int16_t InputMapper::SuperScope::poll(unsigned id) {
- switch(id) {
+ switch((SNES::Input::SuperScopeID)id) {
case SNES::Input::SuperScopeID::X: return x.poll();
case SNES::Input::SuperScopeID::Y: return y.poll();
case SNES::Input::SuperScopeID::Trigger: return trigger.poll();
@@ -182,7 +182,7 @@ void InputMapper::Justifier::create(cons
}
int16_t InputMapper::Justifier::poll(unsigned id) {
- switch(id) {
+ switch((SNES::Input::JustifierID)id) {
case SNES::Input::JustifierID::X: return x.poll();
case SNES::Input::JustifierID::Y: return y.poll();
case SNES::Input::JustifierID::Trigger: return trigger.poll();
bsnes-0.079-gtk.patch:
Makefile | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
--- NEW FILE bsnes-0.079-gtk.patch ---
diff -up bsnes_v079-source/bsnes/ui/Makefile.gtk bsnes_v079-source/bsnes/ui/Makefile
--- bsnes_v079-source/bsnes/ui/Makefile.gtk 2011-06-22 21:42:22.509169945 +0200
+++ bsnes_v079-source/bsnes/ui/Makefile 2011-06-22 21:42:51.361077057 +0200
@@ -7,11 +7,11 @@ ui_objects += $(if $(call streq,$(platfo
# platform
ifeq ($(platform),x)
-# phoenix_compile = $(call compile,-DPHOENIX_GTK `pkg-config --cflags gtk+-2.0`)
-# link += `pkg-config --libs gtk+-2.0`
+ phoenix_compile = $(call compile,-DPHOENIX_GTK `pkg-config --cflags gtk+-2.0`)
+ link += `pkg-config --libs gtk+-2.0`
- phoenix_compile = $(call compile,-DPHOENIX_QT `pkg-config --cflags QtCore QtGui`)
- link += `pkg-config --libs QtCore QtGui`
+# phoenix_compile = $(call compile,-DPHOENIX_QT `pkg-config --cflags QtCore QtGui`)
+# link += `pkg-config --libs QtCore QtGui`
ruby := video.glx video.xv video.sdl
ruby += audio.alsa audio.openal audio.oss audio.pulseaudio audio.pulseaudiosimple
audio.ao
bsnes-0.079-systemwide.patch:
Makefile | 3 ---
general/main-window.cpp | 12 ++++++++++++
2 files changed, 12 insertions(+), 3 deletions(-)
--- NEW FILE bsnes-0.079-systemwide.patch ---
diff -up bsnes_v079-source/bsnes/ui/general/main-window.cpp.systemwide
bsnes_v079-source/bsnes/ui/general/main-window.cpp
--- bsnes_v079-source/bsnes/ui/general/main-window.cpp.systemwide 2011-03-15
02:39:33.000000000 +0100
+++ bsnes_v079-source/bsnes/ui/general/main-window.cpp 2011-06-22 20:52:10.609866683
+0200
@@ -412,6 +412,12 @@ void MainWindow::setupFiltersAndShaders(
#endif
files = directory::files(folderPath, "*.filter");
}
+#if defined(PLATFORM_X)
+ if(files.size() == 0) {
+ folderPath = "/usr/lib/bsnes/filters/";
+ files = directory::files(folderPath, "*.filter");
+ }
+#endif
foreach(filename, files) {
settingsVideoFilterName.append({ folderPath, filename });
}
@@ -458,6 +464,12 @@ void MainWindow::setupFiltersAndShaders(
#endif
files = directory::files(folderPath, { "*.", config.video.driver,
".shader" });
}
+#if defined(PLATFORM_X)
+ if(files.size() == 0) {
+ folderPath = "/usr/share/bsnes/shaders/";
+ files = directory::files(folderPath, {"*.", config.video.driver,
".shader" });
+ }
+#endif
foreach(filename, files) {
settingsVideoShaderName.append({ folderPath, filename });
}
diff -up bsnes_v079-source/bsnes/ui/Makefile.systemwide
bsnes_v079-source/bsnes/ui/Makefile
--- bsnes_v079-source/bsnes/ui/Makefile.systemwide 2011-03-15 00:58:22.000000000 +0100
+++ bsnes_v079-source/bsnes/ui/Makefile 2011-06-22 20:52:08.648872996 +0200
@@ -96,9 +96,6 @@ ifeq ($(platform),x)
endif
install -D -m 644 data/bsnes.png $(DESTDIR)$(prefix)/share/pixmaps/bsnes.png
install -D -m 644 data/bsnes.desktop
$(DESTDIR)$(prefix)/share/applications/bsnes.desktop
- mkdir -p ~/.config/bsnes
- cp data/cheats.xml ~/.config/bsnes/cheats.xml
- chmod 777 ~/.config/bsnes ~/.config/bsnes/cheats.xml
uninstall:
ifeq ($(platform),x)
Index: .cvsignore
===================================================================
RCS file: /cvs/free/rpms/bsnes/F-14/.cvsignore,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -r1.29 -r1.30
--- .cvsignore 21 Nov 2010 19:39:52 -0000 1.29
+++ .cvsignore 22 Jun 2011 20:05:33 -0000 1.30
@@ -1 +1 @@
-bsnes_v072.tar.bz2
+bsnes_v079-source.tar.bz2
Index: README.bsnes
===================================================================
RCS file: /cvs/free/rpms/bsnes/F-14/README.bsnes,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- README.bsnes 14 Jul 2009 11:35:19 -0000 1.3
+++ README.bsnes 22 Jun 2011 20:05:33 -0000 1.4
@@ -1,18 +1,12 @@
RPM Fusion bsnes package
==============================================================================
-1. Problems with PulseAudio
+RPM Fusion bsnes package is patched to install cheat.xml, filters and shaders
+in system-wide location. If you run into issues using these, please don't
+complain to upstream, but use RPM Fusion bugzilla first.
+
+Moreover, due to [1] newer versions of bsnes are more strict when it comes to
+file formats accepted. The snespurify-qt utility can be used to convert the
+images. They have to be uncompressed.
-There are slight problems with some of the bsnes audio drivers and PulseAudio. Namely,
the libao driver will not work, and the OSS driver will not work with padsp. Other drivers
work with the default Fedora configuration. Please note that the emulator author
recommends using the ALSA driver over the native PulseAudio one due to limitations in the
latter. bsnes audio drivers can be changed by going to Settings -> Configuration ->
Advanced. Program needs to be restarted for the changes to have effect.
-
-
-2. Using system zlib
-
-This is the post byuu made on zsnes boards when asked to merge the system-zlib patch (it
was more complex at that stage, using system libs was optional, but since it was not going
to be merged anyway, I decided to make it simpler):
-
-
-I don't really want to add this change to bsnes, no. A system-wide zlib would require
a DLL for Windows, and I see no reason to provide a lean, stripped down zlib along with
bsnes for Windows users, yet have an option to use the system version for Linux
(especially when there is no similar lib for JMA), just to appease a few people with
nothing better to do than complain about random garbage.
-
-However, feel free to appease the Fedora development team by changing that in your source
tree if you like. My sincere apologies that you'll have to keep backporting the
change.
-
-I don't want any part in trying to appease these people. They constantly bring up
crap about non-commercial clauses, about using a 64-byte IPLROM, about compiling in
support for OSS by default, and now about a massive ~80kb that can be shaved off the bsnes
binary by adding extra dependencies to the emulator. Perhaps I should just start offering
a raw Linux binary on my website ala nVidia, Macromedia et al.
+[1]
http://byuu.org/bsnes/legacy-formats
Index: bsnes.spec
===================================================================
RCS file: /cvs/free/rpms/bsnes/F-14/bsnes.spec,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -r1.40 -r1.41
--- bsnes.spec 21 Nov 2010 19:39:52 -0000 1.40
+++ bsnes.spec 22 Jun 2011 20:05:33 -0000 1.41
@@ -1,4 +1,4 @@
-%global vernumber 072
+%global vernumber 079
Name: bsnes
Version: 0.%{vernumber}
@@ -8,12 +8,11 @@
Group: Applications/Emulators
License: GPLv2
URL:
http://byuu.org/bsnes/
-Source0:
http://bsnes.googlecode.com/files/%{name}_v%{vernumber}.tar.bz2
+Source0:
http://bsnes.googlecode.com/files/%{name}_v%{vernumber}-source.tar.bz2
Source2: README.bsnes
-Patch0: bsnes-0.072-nocheats.patch
-Patch1: bsnes-0.068-newppcelf.patch
-Patch2: bsnes-0.068-noppcelfppc64.patch
-Patch3: bsnes-0.064-systemlibs.patch
+Patch0: bsnes-0.079-gcc46.patch
+Patch1: bsnes-0.079-systemwide.patch
+Patch2: bsnes-0.079-gtk.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
#bsnes does not use system snes_ntsc because the modified video processing
@@ -21,13 +20,16 @@
#isn't available when the library is built stand alone
BuildRequires: desktop-file-utils
BuildRequires: freealut-devel
+BuildRequires: gtk2-devel
BuildRequires: libao-devel
BuildRequires: libXv-devel
BuildRequires: pulseaudio-libs-devel
BuildRequires: SDL-devel
-BuildRequires: qt-devel
Obsoletes: %{name}-pixelshaders < 0.064
+Obsoletes: %{name}-snesfilter < 0.079
+Obsoletes: %{name}-snesreader < 0.079
+Obsoletes: %{name}-supergameboy < 0.079
%description
bsnes is an emulator that began development on 2004-10-14. The purpose of the
@@ -37,77 +39,48 @@
includes speed and game-specific hacks for compatibility. As a result, the
minimum system requirements for bsnes are quite high.
-%package snesfilter
-Summary: Visual filters for %{name}
-Group: Applications/Emulators
-Requires: %{name} = %{version}-%{release}
-
-%description snesfilter
-This subpackage contains various video filters for bsnes.
-
-%package snesreader
-Summary: Compressed ROM images support for %{name}
-Group: Applications/Emulators
-Requires: %{name} = %{version}-%{release}
-
-%description snesreader
-This subpackage enables support for various compressed images, like .zip, .7z,
-.rar and others.
-
-%package supergameboy
-Summary: Super Game Boy emulation for %{name}
-Group: Applications/Emulators
-Requires: %{name} = %{version}-%{release}
-
-%description supergameboy
-This package includes gambatte-based Super Game Boy emulation.
-
%prep
-%setup -qc
-%patch0 -p1 -b .nocheats
-%patch1 -p1 -b .newppcelf
-%patch2 -p1 -b .noppcelfppc64
-%patch3 -p1 -b .systemlibs
+%setup -q -n %{name}_v%{vernumber}-source
+%patch0 -p1 -b .gcc46
+%patch1 -p1 -b .systemwide
+%patch2 -p1 -b .gtk
#fix permissions
find . -type f -not -name \*.sh -exec chmod 644 {} \;
#use system optflags
-for sourcedir in snesfilter snesreader bsnes supergameboy
-do
- pushd $sourcedir
- sed -i "s#-O3#$RPM_OPT_FLAGS#" Makefile
- popd
-done
+sed -i "s/-O3/$RPM_OPT_FLAGS/" bsnes/Makefile
+sed -i "s/-O3/$RPM_OPT_FLAGS -fPIC/" snesfilter/Makefile
+sed -i "s/-O3/$RPM_OPT_FLAGS/" snespurify/cc-gtk.sh
#don't strip the binaries prematurely
-for sourcedir in snesfilter snesreader bsnes supergameboy
-do
- pushd $sourcedir
- sed -i "s/link += -s/link +=/" Makefile
- popd
-done
+sed -i "s/link += -s/link +=/" bsnes/Makefile
+sed -i "s/link := -s/link :=/" snesfilter/Makefile
+sed -i "s/-s //" snespurify/cc-gtk.sh
+
+#use the proper compiler and moc commands
+sed -i "s/g++-4.5/g++/" snespurify/cc-gtk.sh
#install fedora-specific readme
install -pm 644 %{SOURCE2} README.Fedora
-#pulseaudio on fedora 11 is too old
-%if 0%{?fedora} < 12
-sed -i "s(a)audio.pulseaudio @@" bsnes/ui_qt/Makefile
-%endif
+#use proper system-wide paths for filters and cheats.xml
+sed -i
's@path.home("cheats.xml")@"/usr/share/bsnes/cheats.xml"(a)' \
+ bsnes/ui/tools/cheat-database.cpp
+sed -i 's@/usr/lib@%{_libdir}@' bsnes/ui/general/main-window.cpp
%build
-for sourcedir in snesfilter snesreader supergameboy
-do
- pushd $sourcedir
- make %{?_smp_mflags} moc=moc-qt4 compiler=gcc
- popd
-done
-
pushd bsnes
-make %{?_smp_mflags} platform=x compiler=gcc moc=moc-qt4 profile=compatibility ui=ui-qt
+make %{?_smp_mflags} compiler=gcc
+popd
+pushd snesfilter
+make %{?_smp_mflags} compiler=gcc
+popd
+pushd snespurify
+./cc-gtk.sh
+popd
%install
@@ -118,61 +91,39 @@
--delete-original --dir $RPM_BUILD_ROOT%{_datadir}/applications \
$RPM_BUILD_ROOT%{_datadir}/applications/bsnes.desktop
popd
-install -d $RPM_BUILD_ROOT%{_libdir}
install -d $RPM_BUILD_ROOT%{_datadir}/%{name}
-for sourcedir in snesfilter snesreader supergameboy
-do
- pushd $sourcedir
- install -pm 755 lib$sourcedir.so $RPM_BUILD_ROOT%{_libdir}/lib$sourcedir.so
- popd
-done
-
+install -pm 644 bsnes/data/cheats.xml $RPM_BUILD_ROOT%{_datadir}/%{name}
+install -d $RPM_BUILD_ROOT%{_libdir}/%{name}/filters
+install -pm 755 snesfilter/out/*.filter $RPM_BUILD_ROOT%{_libdir}/%{name}/filters
+install -pm 755 snespurify/snespurify-gtk $RPM_BUILD_ROOT%{_bindir}
+install -d $RPM_BUILD_ROOT%{_datadir}/%{name}/shaders
+install -pm 644 snesshader/*.shader $RPM_BUILD_ROOT%{_datadir}/%{name}/shaders
%clean
rm -rf $RPM_BUILD_ROOT
-%post snesfilter -p /sbin/ldconfig
-
-
-%postun snesfilter -p /sbin/ldconfig
-
-
-%if %{with snesreader}
-%post snesreader -p /sbin/ldconfig
-
-
-%postun snesreader -p /sbin/ldconfig
-%endif
-
-
-%post supergameboy -p /sbin/ldconfig
-
-
-%postun supergameboy -p /sbin/ldconfig
-
-
%files
%defattr(-,root,root,-)
-%doc README.Fedora bsnes/ui-qt/data/*.html
+%doc README.Fedora
%{_bindir}/bsnes
+%{_bindir}/snespurify-gtk
+%{_libdir}/bsnes
+%{_datadir}/bsnes
%{_datadir}/pixmaps/bsnes.png
%{_datadir}/applications/rpmfusion-bsnes.desktop
-%files snesfilter
-%defattr(-,root,root,-)
-%{_libdir}/libsnesfilter.so
-
-%files snesreader
-%defattr(-,root,root,-)
-%{_libdir}/libsnesreader.so
-
-%files supergameboy
-%defattr(-,root,root,-)
-%{_libdir}/libsupergameboy.so
-
%changelog
+* Tue Jun 21 2011 Julian Sikorski <belegdol(a)fedoraproject.org> - 0.079-1
+- Updated to 0.079
+- Dropped subpackages, they are too small to be worth it
+- Updated the Fedora readme
+- Added gcc-4.6 and systemwide patches by Themaister
+- Try to handle system-wide cheats, filters and shaders properly
+- Switched to accuracy profile (slower)
+- Switched to gtk ui
+
* Sun Nov 21 2010 Julian Sikorski <belegdol(a)fedoraproject.org> - 0.072-1
- Updated to 0.072
- Dropped gconf patch, added cheats one
Index: sources
===================================================================
RCS file: /cvs/free/rpms/bsnes/F-14/sources,v
retrieving revision 1.29
retrieving revision 1.30
diff -u -r1.29 -r1.30
--- sources 21 Nov 2010 19:39:52 -0000 1.29
+++ sources 22 Jun 2011 20:05:33 -0000 1.30
@@ -1 +1 @@
-dcbd0f2a88682fb25d409a8276576983 bsnes_v072.tar.bz2
+22513f713e29824a85a0fe193298f9f2 bsnes_v079-source.tar.bz2
--- bsnes-0.064-systemlibs.patch DELETED ---
--- bsnes-0.068-newppcelf.patch DELETED ---
--- bsnes-0.068-noppcelfppc64.patch DELETED ---
--- bsnes-0.072-nocheats.patch DELETED ---