Author: martinkg
Update of /cvs/nonfree/rpms/openclonk/devel
In directory old02.ovh.rpmfusion.lan:/tmp/cvs-serv14828/devel
Modified Files:
.cvsignore sources
Added Files:
openclonk-5.5.1-git-Fix-extraction-of-language-names-and-Misc.patch
openclonk-5.5.1-tinyxml-shared.patch openclonk-docs.png
openclonk-html-de.desktop openclonk-html-en.desktop
openclonk-target.patch openclonk.appdata.xml openclonk.spec
Log Message:
openclonk-5.5.1-git-Fix-extraction-of-language-names-and-Misc.patch:
planet/System.ocg/LanguageDE.txt | 2 +-
src/c4group/C4Language.cpp | 7 ++++++-
src/graphics/C4FontLoader.cpp | 3 ++-
3 files changed, 9 insertions(+), 3 deletions(-)
--- NEW FILE openclonk-5.5.1-git-Fix-extraction-of-language-names-and-Misc.patch ---
From 840b9cd30a437054cb584547d08c9d98b307385f Mon Sep 17 00:00:00 2001
From: Sven Eberhardt <sven2(a)goldwipf.de>
Date: Sun, 5 Oct 2014 18:10:23 +0200
Subject: [PATCH 1/3] Fix off-by-one error in text line break code (#1122)
---
src/graphics/C4FontLoader.cpp | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/src/graphics/C4FontLoader.cpp b/src/graphics/C4FontLoader.cpp
index a13c6d6..da3d4e7 100644
--- a/src/graphics/C4FontLoader.cpp
+++ b/src/graphics/C4FontLoader.cpp
@@ -760,6 +760,7 @@ int CStdFont::BreakMessage(const char *szMsg, int iWdt, StdStrBuf
*pOut, bool fC
iXBreak=0, // text width as it was at last break pos
iXEmergencyBreak = 0, // same, but at last char in case no suitable
linebreak could be found
iHgt=iLineHgt; // total height of output text
+ int iCharHOverlap = Max<int>(-iHSpace, 0); // character width exceeding placement
of next character
bool fIsFirstLineChar = true;
// ignore any markup
C4Markup MarkupChecker(false);
@@ -802,7 +803,7 @@ int CStdFont::BreakMessage(const char *szMsg, int iWdt, StdStrBuf
*pOut, bool fC
// add chars to output
pOut->Append(szLastPos, szPos - szLastPos);
// add to line; always add one char at minimum
- if ((iX+=iCharWdt) <= iWdt || fIsFirstLineChar)
+ if ((iX+=iCharWdt)+iCharHOverlap <= iWdt || fIsFirstLineChar)
{
// check whether linebreak possibility shall be marked here
// 2do: What about unicode-spaces?
From 67c0deae38c6b6552b539dbd51c7a24c80c1989e Mon Sep 17 00:00:00 2001
From: Nicolas Hake <isilkor(a)openclonk.org>
Date: Mon, 6 Oct 2014 16:03:11 +0200
Subject: [PATCH 2/3] Remove leading + from IDS_MSG_AUTOFRAMESKIP DE
translation (Github #2)
---
planet/System.ocg/LanguageDE.txt | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/planet/System.ocg/LanguageDE.txt b/planet/System.ocg/LanguageDE.txt
index f09c29c..eea90d6 100644
--- a/planet/System.ocg/LanguageDE.txt
+++ b/planet/System.ocg/LanguageDE.txt
@@ -486,7 +486,7 @@ IDS_MNU_VIEWPORT=Sichtfenster
IDS_MSG_ALLOWSYOUTOJOINADIFFERENT=Erlaubt die Auswahl eines anderen Teams.
IDS_MSG_ANTIALIASING_DESC=FSAA (MultiSampling)-Level einstellen
IDS_MSG_ANUPDATETOVERSIONISAVAILA=Ein neues Update ist verfügbar. Soll das Update
heruntergeladen und installiert werden?
-+IDS_MSG_AUTOFRAMESKIP=Automatischer Frameskip
+IDS_MSG_AUTOFRAMESKIP=Automatischer Frameskip
IDS_MSG_AUTOWINDOWED=Automagisch
IDS_MSG_BACKTOPLAYERDLG=Zurück zur Spielerauswahl.
IDS_MSG_CANNOTSTARTSCENARIO=Start nicht möglich.
From a03ec84374d8cfc4dc1c763700763f1e2312cd60 Mon Sep 17 00:00:00 2001
From: Armin Burgmeier <armin(a)arbur.net>
Date: Mon, 6 Oct 2014 13:03:32 -0400
Subject: [PATCH 3/3] Fix extraction of language names for language options
(#1127)
At least in some implementations, std::regex does not treat $ and ^ as the
beginning or end of a line but as the beginning or end of the whole string.
---
src/c4group/C4Language.cpp | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/src/c4group/C4Language.cpp b/src/c4group/C4Language.cpp
index 71dba1b..28b8b2e 100644
--- a/src/c4group/C4Language.cpp
+++ b/src/c4group/C4Language.cpp
@@ -389,7 +389,12 @@ namespace
{
std::string GetResStr(const char *id, const char *stringtbl)
{
- static re::regex line_pattern("^([^=]+)=(.*?)\r?$",
static_cast<re::regex::flag_type>(re::regex_constants::optimize |
re::regex_constants::ECMAScript));
+ // The C++11 standard does not specify whether $ and ^ match
+ // the beginning or end of a line, respectively, and it seems
+ // like in some implementations they only match the beginning
+ // or end of the whole string. See also #1127.
+ static re::regex line_pattern("(?:\n|^)([^=]+)=(.*?)\r?(?=\n|$)",
static_cast<re::regex::flag_type>(re::regex_constants::optimize |
re::regex_constants::ECMAScript));
+
assert(stringtbl);
if (!stringtbl)
{
openclonk-5.5.1-tinyxml-shared.patch:
CMakeLists.txt | 1 -
src/lib/StdMeshLoaderXml.cpp | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
--- NEW FILE openclonk-5.5.1-tinyxml-shared.patch ---
--- a/CMakeLists.txt.orig 2015-02-19 12:59:55.166490726 +0100
+++ b/CMakeLists.txt 2015-02-19 13:00:33.616492645 +0100
@@ -1270,7 +1270,6 @@
endif()
# TinyXML
-add_subdirectory(thirdparty/tinyxml)
target_link_libraries(openclonk tinyxml)
if(WIN32)
--- a/src/lib/StdMeshLoaderXml.cpp.orig 2015-02-19 13:39:47.197610077 +0100
+++ b/src/lib/StdMeshLoaderXml.cpp 2015-02-19 13:40:05.244610977 +0100
@@ -19,7 +19,7 @@
#include "C4Include.h"
#include "StdMesh.h"
#include "StdMeshLoader.h"
-#include <tinyxml/tinyxml.h>
+#include "tinyxml.h"
// Helper class to load things from an XML file with error checking
class StdMeshLoader::StdMeshXML
--- NEW FILE openclonk-html-de.desktop ---
[Desktop Entry]
Type=Application
Name=OpenClonk Documentation (German)
Name[de]=OpenClonk-Dokumentation (Deutsch)
Comment=HTML documentation for OpenClonk development.
Comment[de]=Eine HTML-Dokumentation zur OpenClonk-Entwicklung.
Icon=openclonk-docs
Exec=xdg-open file:///usr/share/doc/openclonk-devel/html/de/sdk/index.html
Categories=Development;Documentation;StrategyGame;
StartupNotify=true
--- NEW FILE openclonk-html-en.desktop ---
[Desktop Entry]
Type=Application
Name=OpenClonk Documentation (English)
Name[de]=OpenClonk-Dokumentation (Englisch)
Comment=HTML documentation for OpenClonk development.
Comment[de]=Eine HTML-Dokumentation zur OpenClonk-Entwicklung.
Icon=openclonk-docs
Exec=xdg-open file:///usr/share/doc/openclonk-devel/html/en/sdk/index.html
Categories=Development;Documentation;StrategyGame;
StartupNotify=true
openclonk-target.patch:
CMakeLists.txt | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- NEW FILE openclonk-target.patch ---
--- openclonk-release-5.5.1-src/CMakeLists.txt.orig 2015-01-27 15:40:45.564376486 +0100
+++ openclonk-release-5.5.1-src/CMakeLists.txt 2015-01-27 15:41:32.949378851 +0100
@@ -1173,7 +1173,7 @@
# Don't put this into CMAKE_CXX_FLAGS because otherwise it is cached,
# and when the path is changed both the old and new definition appears
# in the list of flags.
- add_definitions("-DOC_SYSTEM_DATA_DIR=\"${CMAKE_INSTALL_PREFIX}/share/games/openclonk\"")
+ add_definitions("-DOC_SYSTEM_DATA_DIR=\"${CMAKE_INSTALL_PREFIX}/share/openclonk\"")
endif()
if(OC_CXX_FLAGS)
list(REMOVE_DUPLICATES OC_CXX_FLAGS)
@@ -1474,7 +1474,7 @@
DEPENDS c4group
VERBATIM
)
- install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${group} DESTINATION share/games/openclonk)
+ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${group} DESTINATION share/openclonk)
endif()
endforeach()
--- NEW FILE openclonk.appdata.xml ---
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright 2015 Martin Gansser <martinkg(a)fedoraproject.org> -->
<application>
<id type="desktop">openclonk.desktop</id>
<metadata_license>CC0-1.0</metadata_license>
<project_license>ISC and CC-BY-NC</project_license>
<name>OpenClonk</name>
<summary>Fast-paced 2d genre mix</summary>
<description>
<p>
OpenClonk is a free multiplayer action game in which you control clonks,
small but witty and nimble humanoid beings. The game is mainly about mining,
settling and fast-paced melees.
OpenClonk is not just a game but also a versatile 2D game engine that allows
the creation of mods. It is the successor of the shareware game series Clonk
and thus inherits many of its features.
</p>
</description>
<screenshots>
<screenshot
type="default">http://img.informer.com/screenshots/2929/2929...
<
screenshot>http://img.informer.com/screenshots/5551/5551082_2.jpg</...
</screenshots>
<url type="homepage">http://www.openclonk.org</url>
<updatecontact>martinkg(a)fedoraproject.org</updatecontact>
</application>
--- NEW FILE openclonk.spec ---
%global develdocdir %{_docdir}/%{name}-devel/html
Name: openclonk
Version: 5.5.1
Release: 6%{?dist}
Summary: Fast-paced 2d genre mix
License: ISC and CC-BY-NC
Url:
http://www.openclonk.org/
Source0:
http://www.openclonk.org/builds/release/%{version}/%{name}-%{version}-src...
Source1: %{name}.appdata.xml
Source2: %{name}-html-de.desktop
Source3: %{name}-html-en.desktop
Source4: %{name}-docs.png
Patch0: %{name}-target.patch
Patch1: %{name}-%{version}-git-Fix-extraction-of-language-names-and-Misc.patch
#
http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/games-action/open...
Patch2: %{name}-%{version}-tinyxml-shared.patch
BuildRequires: boost-devel
BuildRequires: cmake
BuildRequires: gtest-devel
BuildRequires: libjpeg-devel
BuildRequires: tinyxml-devel
BuildRequires: pkgconfig(SDL_mixer)
BuildRequires: pkgconfig(dri)
BuildRequires: pkgconfig(freealut)
BuildRequires: pkgconfig(freetype2)
BuildRequires: pkgconfig(gl)
BuildRequires: pkgconfig(glew)
BuildRequires: pkgconfig(gtk+-2.0)
BuildRequires: pkgconfig(gtksourceview-2.0)
BuildRequires: pkgconfig(libpng12)
BuildRequires: pkgconfig(libupnp)
BuildRequires: pkgconfig(ogg)
BuildRequires: pkgconfig(sdl)
BuildRequires: pkgconfig(vorbis)
BuildRequires: pkgconfig(x11)
BuildRequires: pkgconfig(xpm)
BuildRequires: pkgconfig(xrandr)
BuildRequires: pkgconfig(xxf86vm)
BuildRequires: pkgconfig(zlib)
BuildRequires: pkgconfig(xml2po)
BuildRequires: ImageMagick
BuildRequires: desktop-file-utils
BuildRequires: libappstream-glib
BuildRequires: libxslt
BuildRequires: gettext
BuildRequires: libxml2-devel
Requires: hicolor-icon-theme
Provides: bundled(timsort)
Requires: %{name}-data = %{version}-%{release}
%description
Clonk is a multiplayer-action-tactics-skill game. It is often referred to as
a mixture of The Settlers and Worms. In a simple 2D ant-farm style landscape,
the player controls his crew of Clonks, small but robust humanoid beings.
The game encourages free play but the normal goal is to either exploit
valuable resources from the earth by building a mine or fight each other on
an arena-like map.
%package data
Summary: Graphic Objects for %{name}
BuildArch: noarch
Requires: %{name} = %{version}-%{release}
%description data
Arch-independent data files for OpenClonk.
This package contains images, themes and JavaScript.
%package devel-docs
Summary: Documentation for developing programs that will use %{name}
Group: Documentation
BuildArch: noarch
Requires: xdg-utils
%description devel-docs
This package contains documentation needed for developing with %{name}.
%prep
%setup -q -n %{name}-release-%{version}-src
%patch0 -p1 -b .target
%patch1 -p1 -b .Misc
%patch2 -p1
# remove bundled tinyyml
rm -rf thirdparty/tinyxml
# remove bundled getopt
rm -rf thirdparty/getopt
# remove bundled natupnp
rm -rf thirdparty/natupnp
rm -rf planet/Tests.c4f
# change permission in src and docs folder
find src -type f | xargs chmod -v 644
find docs -type f | xargs chmod -v 644
find docs -type d | xargs chmod -v 755
# change permission due rpmlint W: spurious-executable-perm
chmod a-x README Credits.txt thirdparty/timsort/sort.h
# change permission due rpmlint E: script-without-shebang
chmod -x COPYING TRADEMARK
chmod -x licenses/*
%build
%cmake -DUSE_STATIC_BOOST=OFF \
-DBUILD_SHARED_LIBS=OFF
make %{?_smp_mflags}
# build the German and English HTML-documentation from the English \
# XML-source files and the translation file
pushd docs
mkdir -p sdk-de/{definition,folder,material,particle,scenario,script/fn}
make %{?_smp_mflags} chm/de/Entwickler.chm
make %{?_smp_mflags} chm/en/Developer.chm
popd
%install
make DESTDIR=%{buildroot} install
mv %{buildroot}%{_prefix}/games/%{name} %{buildroot}%{_bindir}/%{name}
# install appdata.xml file
mkdir -p %{buildroot}%{_datadir}/appdata
install -Dm 0644 %{SOURCE1} %{buildroot}%{_datadir}/appdata/%{name}.appdata.xml
# install html docs to %%{_docdir}/%%{name}-devel/html
mkdir -p %{buildroot}%{develdocdir}/{de,en}
cp -pr docs/chm/de %{buildroot}/%{develdocdir}/
cp -pr docs/chm/en %{buildroot}/%{develdocdir}/
# W: wrong-file-end-of-line-encoding
sed -i 's/\r$//' %{buildroot}/%{develdocdir}/de/Output.hhp
sed -i 's/\r$//' %{buildroot}/%{develdocdir}/en/Output.hhp
# W: file-not-utf8
iconv -f iso8859-1 -t utf-8 %{buildroot}/%{develdocdir}/de/Output.hhk > \
Output.hhk.conv && mv -f Output.hhk.conv
%{buildroot}/%{develdocdir}/de/Output.hhk
# HTML desktop files
desktop-file-install --dir %{buildroot}%{_datadir}/applications %{SOURCE2}
desktop-file-install --dir %{buildroot}%{_datadir}/applications %{SOURCE3}
mkdir -p %{buildroot}%{_datadir}/pixmaps
install -D -m 0644 %{SOURCE4} $RPM_BUILD_ROOT%{_datadir}/pixmaps/%{name}-docs.png
%check
desktop-file-validate %{buildroot}%{_datadir}/applications/*.desktop
appstream-util validate-relax --nonet %{buildroot}%{_datadir}/appdata/*.appdata.xml
%post
/usr/bin/update-desktop-database &> /dev/null || :
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
%postun
/usr/bin/update-desktop-database &> /dev/null || :
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
%doc README Credits.txt
%license licenses/*.txt
%license COPYING TRADEMARK
%{_bindir}/*
%{_datadir}/icons/hicolor/*/apps/%{name}.png
%{_datadir}/applications/%{name}.desktop
%{_datadir}/appdata/%{name}.appdata.xml
%files data
%license licenses/*.txt
%license COPYING TRADEMARK
%{_datadir}/%{name}
%files devel-docs
%dir %{_docdir}/%{name}-devel
%doc %{develdocdir}
%{_datadir}/applications/%{name}-html-*.desktop
%{_datadir}/pixmaps/%{name}-docs.png
%changelog
* Tue Feb 24 2015 Martin Gansser <martinkg(a)fedoraproject.org> - 5.5.1-6
- dropped CFLAGS and CXXFLAGS flags because already sets by %%cmake macro
- dropped CMAKE_INSTALL_PREFIX because already sets by %%cmake macro
- removed bundled natupnp
- added virtual provides for tracking purposes
* Sun Feb 22 2015 Martin Gansser <martinkg(a)fedoraproject.org> - 5.5.1-5
- changed permission of files in src folder
- dropped GPLv2+ and ISC license
- correct spelling errors
- removed bundled getopt
- removed BSD license
- added ISC license
- replaced license CC-BY-SA by CC-BY-NC
- dropped GenericName entry from desktop file due display issue
* Sat Feb 21 2015 Martin Gansser <martinkg(a)fedoraproject.org> - 5.5.1-4
- added BR desktop-file-utils
- replaced tabs by space
* Fri Feb 20 2015 Martin Gansser <martinkg(a)fedoraproject.org> - 5.5.1-3
- corrected requirements to pkgconfig(xml2po)
- deleted Requieres from sub package
- added Requires to main package
- added html desktop files
- replaced tabs by space
- added RR xdg-utils to docs package
- added %%{?_smp_mflags} flag to html make
- added png file to devel-docs package
* Thu Feb 19 2015 Martin Gansser <martinkg(a)fedoraproject.org> - 5.5.1-2
- deleted group tag
- added doc tag
- added license tag
- added appdata.xml file
- changed file permission
- used macro %%cmake
- corrected RR dependencies
- added %%licenses to main package
- added %%licenses to sub package
- added BR tinyxml-devel
- added BR pkgconfig(xml2po)
- added BR libxslt
- added BR libxml2-devel
- installed html docs
* Tue Jan 27 2015 Martin Gansser <martinkg(a)fedoraproject.org> - 5.5.1-1
- initial build for Fedora 21
Index: .cvsignore
===================================================================
RCS file: /cvs/nonfree/rpms/openclonk/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 7 Mar 2015 15:13:51 -0000 1.1
+++ .cvsignore 7 Mar 2015 22:29:35 -0000 1.2
@@ -0,0 +1 @@
+openclonk-5.5.1-src.tar.bz2
Index: sources
===================================================================
RCS file: /cvs/nonfree/rpms/openclonk/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources 7 Mar 2015 15:13:52 -0000 1.1
+++ sources 7 Mar 2015 22:29:35 -0000 1.2
@@ -0,0 +1 @@
+4a988b0e24f18ca46c23686b4fe1bca9 openclonk-5.5.1-src.tar.bz2