[brutalchess] 0.5.2-0.5.alpha
Raphael Groner
raphgro at fedoraproject.org
Mon Dec 29 20:02:09 UTC 2014
commit 3dc1a9fc53e033cd5ef34a85f75af6a6c2d25cb7
Author: Raphael Groner <projects.rg at smart.ms>
Date: Mon Dec 29 21:02:01 2014 +0100
0.5.2-0.5.alpha
brutalchess-noquake.patch | 44 +++++++++++++++++++++++++
brutalchess.spec | 78 +++++++++++++++++++-------------------------
2 files changed, 78 insertions(+), 44 deletions(-)
---
diff --git a/brutalchess-noquake.patch b/brutalchess-noquake.patch
new file mode 100644
index 0000000..bc37065
--- /dev/null
+++ b/brutalchess-noquake.patch
@@ -0,0 +1,44 @@
+From: Markus Koschany <apo at gambaru.de>
+Date: Sat, 21 Dec 2013 13:56:00 +0100
+Subject: disable quake pieces
+
+The quake pieces were never officially shipped by upstream because they are
+copyrighted. This patch disables the -p quake option because it is useless and
+causes a segmentation fault.
+
+Bug: http://bugs.debian.org/732227
+---
+ src/utils.cpp | 6 ------
+ 1 file changed, 6 deletions(-)
+
+diff --git a/src/utils.cpp b/src/utils.cpp
+index e1ccb4b..8138118 100644
+--- a/src/utils.cpp
++++ b/src/utils.cpp
+@@ -38,8 +38,6 @@ void printUsage()
+ cerr << " -l PLAYER1 PLAYER2 --player1=PLAYER1\t\t Set your player and opponent. Choices are brutal,\n";
+ cerr << " --player2=PLAYER2\t\t faile, human, random, test, xboard.";
+ cerr << endl << endl;
+- cerr << " -p PIECE_SET --pieces=PIECE_SET\t\t Select the piece set. Choices are basic, quake.";
+- cerr << endl << endl;
+ cerr << " -r --reflections=on|off\t\t\t Turn off reflections, on by default.";
+ cerr << endl << endl;
+ cerr << " -s --shadows=on|off\t\t\t\t Turn off shadows, on by default.";
+@@ -156,8 +154,6 @@ void parseCommandLine(int argc, char* argv[])
+ opts->pieces = BASIC;
+ } else if(args[i+1] == "debug") {
+ opts->pieces = DEBUG;
+- } else if(args[i+1] == "quake") {
+- opts->pieces = QUAKE;
+ } else {
+ printUsage();
+ }
+@@ -167,8 +163,6 @@ void parseCommandLine(int argc, char* argv[])
+ opts->pieces = BASIC;
+ } else if(args[i].substr(9, args[i].size()) == "debug") {
+ opts->pieces = DEBUG;
+- } else if(args[i].substr(9, args[i].size()) == "quake") {
+- opts->pieces = QUAKE;
+ } else {
+ printUsage();
+ }
diff --git a/brutalchess.spec b/brutalchess.spec
index 4a06d2b..4bd3f96 100644
--- a/brutalchess.spec
+++ b/brutalchess.spec
@@ -1,26 +1,27 @@
%global pre alpha
-%global title BrutalChess
Name: brutalchess
Version: 0.5.2
-Release: 0.4.%{pre}%{?dist}
+Release: 0.5.%{pre}%{?dist}
Summary: Chess game with impressive 3D graphics
License: GPLv2+
URL: http://sf.net/projects/%{name}
-##we don't want the original fonts due to legal reasoning
-#http://sf.net/projects/%{name}/files/%{name}-%{pre}/%{name}-%{pre}-%{version}/%{name}-%{pre}-%{version}-src.tar.gz
+# we don't want the original fonts due to legal reasoning
+# http://sf.net/projects/%{name}/files/%{name}-%{pre}/%{name}-%{pre}-%{version}/%{name}-%{pre}-%{version}-src.tar.gz
Source0: %{name}-%{pre}-%{version}-nofonts.tar.xz
Source1: %{name}-nofonts.sh
Patch0: https://sf.net/p/%{name}/patches/8/attachment/%{name}-freetype2.patch
# fonts: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=584416
Patch1: https://sf.net/p/%{name}/patches/7/attachment/%{name}-fonts.diff
+# quake pieces are not available, http://bugs.debian.org/732227
+Patch2: brutalchess-noquake.patch
# features later:
-# FIXME crafty https://sourceforge.net/p/brutalchess/patches/4/
-# FIXME PGN https://sourceforge.net/p/brutalchess/patches/3/
-# FIXME -l option https://sourceforge.net/p/brutalchess/patches/2/
+# FIXME crafty https://sf.net/p/brutalchess/patches/4/
+# FIXME PGN https://sf.net/p/brutalchess/patches/3/
+# FIXME -l option https://sf.net/p/brutalchess/patches/2/
Source10: http://slackbuilds.org/slackbuilds/14.1/games/%{name}/%{name}.desktop
Source11: http://slackbuilds.org/slackbuilds/14.1/games/%{name}/%{name}.png
@@ -28,90 +29,79 @@ Patch10: http://slackbuilds.org/slackbuilds/14.1/games/%{name}/%{name}-%{
Patch11: http://slackbuilds.org/slackbuilds/14.1/games/%{name}/%{name}-%{version}-gcc4.3.patch
Patch12: http://slackbuilds.org/slackbuilds/14.1/games/%{name}/%{name}-%{version}-gcc4.7.patch
-BuildRequires: libXt-devel mesa-libGL-devel libXi-devel libXmu-devel
BuildRequires: SDL-devel SDL_image-devel
+BuildRequires: mesa-libGL-devel
BuildRequires: freetype-devel
-BuildRequires: gnu-free-mono-fonts gnu-free-sans-fonts gnu-free-serif-fonts
-BuildRequires: dos2unix doxygen
+BuildRequires: doxygen
BuildRequires: desktop-file-utils
-Requires: gnu-free-mono-fonts gnu-free-sans-fonts gnu-free-serif-fonts
+Requires: gnu-free-sans-fonts
# -doc subpkg was < 100k, not worth splitting out (yet) -- rex
Obsoletes: brutalchess-doc < 0.5.2-0.4
Provides: %{name}-doc = %{version}-%{release}
%description
-%{title} features full 3D graphics, an advanced particle engine,
+BrutalChess features full 3D graphics, an advanced particle engine,
and several different levels of intelligent AI, inspired by the once
popular "Battle Chess" released by Interplay circa 1988.
%prep
%setup -q
-sed -i s,fonts,, Makefile.in
%patch0 -p0
%patch1 -p1
+%patch2 -p1
%patch10
%patch11
%patch12 -p1
-dos2unix NEWS README
# update Doxyfile
doxygen -u
+# proper font license
+sed -i s,fonts,, Makefile.in
+sed -i 's,\(fontsdir=\).*,\1"\${datadir}/fonts/",' configure
+sed -i s,ZEROES__.TTF,gnu-free/FreeSans.ttf, src/gamecore.cpp
+# W: wrong-file-end-of-line-encoding
+sed -i 's/\r$//' NEWS README
%build
-
-##FIXME libXt support is a feature
-%configure --with-x
+%configure
make %{?_smp_mflags}
-
doxygen
%install
%make_install
-##misplaced content
+# misplaced content
rm -rv %{buildroot}%{_datadir}/%{name}/doc
-##desktop
+# desktop
desktop-file-install --dir=%{buildroot}%{_datadir}/applications %{SOURCE10}
install -d %{buildroot}%{_datadir}/pixmaps
cp -p %{SOURCE11} %{buildroot}%{_datadir}/pixmaps
-##fonts configuration made legally
-##FIXME ugly hackery with symlinks for fixed file names,
-##could change in future, maybe better ask upstream to patch source
-install -d %{buildroot}%{_datadir}/%{name}/fonts
-pushd %{buildroot}%{_datadir}/%{name}/fonts
-find -name \*.TTF -or -name \*.tff -delete
-ln -s ../../fonts/gnu-free/FreeSerifBold.ttf COOLVETI.TTF
-ln -s ../../fonts/gnu-free/FreeSerif.ttf Ghostwri.ttf
-ln -s ../../fonts/gnu-free/FreeMono.ttf VeraMono.ttf
-ln -s ../../fonts/gnu-free/FreeSans.ttf ZERO__.TTF
-popd
-
%files
%doc AUTHORS COPYING ChangeLog NEWS README
%doc doc/html
-# engine
-%{_bindir}/%{name}
-%{_libexecdir}/md3view
-%{_libexecdir}/objview
-# desktop & icon
-%{_datadir}/applications/%{name}.desktop
-%{_datadir}/pixmaps/%{name}.png
-# data
+%{_bindir}/*
+%{_libexecdir}/*
+%{_datadir}/applications/*
+%{_datadir}/pixmaps/*
%{_datadir}/%{name}/
-#%{_datadir}/%{name}/art/
-#%{_datadir}/%{name}/models/
-# fonts
-#%{_datadir}/%{name}/fonts/
%changelog
+* Mon Dec 29 2014 Raphael Groner <projects.rg [AT] smart.ms> - 0.5.2-0.5.alpha
+- remove wrong and improve fonts logic
+- general files section
+- remove useless title macro
+- add noquake patch
+- preserve timestamps of doc files
+- remove confusing with-x flag
+
* Sun Dec 28 2014 Rex Dieter <rdieter at fedoraproject.org> - 0.5.2-0.4.alpha
- drop -doc subpkg (too small, not worth it)
- omit non-html doc generation
More information about the scm-commits
mailing list