[packages/gemrb] up to 0.8.7
atler
atler at pld-linux.org
Fri Apr 23 12:20:23 CEST 2021
commit f645b233796039f92cd30d35d61a71f5972b6027
Author: Jan Palus <atler at pld-linux.org>
Date: Fri Apr 23 12:18:41 2021 +0200
up to 0.8.7
gemrb-config_file.patch | 36 +++++++++++++-------
gemrb-useless_files.patch | 14 --------
gemrb.spec | 84 ++++++++++++++++++++++++++++++-----------------
3 files changed, 78 insertions(+), 56 deletions(-)
---
diff --git a/gemrb.spec b/gemrb.spec
index 88394e9..508080c 100644
--- a/gemrb.spec
+++ b/gemrb.spec
@@ -1,32 +1,37 @@
-# TODO:
-# - make it build on x86_64
#
# Conditional build:
-%bcond_without png # build without png
+%bcond_with gles # build GLES backend
Summary: Emulator of BioWare's Infinity game engine
Summary(pl.UTF-8): Emulator silnika gier Infinity firmy BioWare
Name: gemrb
-Version: 0.7.0
+Version: 0.8.7
Release: 0.1
License: GPL v2+
Group: Applications/Emulators
-Source0: http://downloads.sourceforge.net/gemrb/%{name}-%{version}.tar.gz
-# Source0-md5: 0bb891db41d6f69e8414bdce808b32f8
+Source0: https://downloads.sourceforge.net/gemrb/%{name}-%{version}-sources.tar.gz
+# Source0-md5: d1bf1dd8ca03ce9649b52240d363f357
Patch0: %{name}-config_file.patch
-Patch1: %{name}-useless_files.patch
URL: http://gemrb.sourceforge.net/
BuildRequires: OpenAL-devel
-BuildRequires: SDL-devel >= 1.2
-BuildRequires: autoconf
-BuildRequires: automake
-%{?with_png:BuildRequires: libpng-devel}
-BuildRequires: libstdc++-devel
-BuildRequires: libtool
+%{!?with_gles:BuildRequires: OpenGL-devel}
+%{?with_gles:BuildRequires: OpenGLESv2-devel}
+BuildRequires: SDL2-devel
+BuildRequires: SDL2_mixer-devel
+BuildRequires: cmake >= 3.1
+BuildRequires: freetype-devel
+BuildRequires: libpng-devel
+BuildRequires: libstdc++-devel >= 6:4.8.1
+BuildRequires: libvorbis-devel
BuildRequires: pkgconfig
BuildRequires: python-devel >= 1:2.3.0
BuildRequires: python-modules
+BuildRequires: rpmbuild(macros) >= 1.605
+BuildRequires: vlc-devel
BuildRequires: zlib-devel
+Requires(post,postun): desktop-file-utils
+Requires(post,postun): gtk-update-icon-cache
+Requires(post,postun): hicolor-icon-theme
Suggests: synce-unshield
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
@@ -43,41 +48,60 @@ Linux/Unix, MacOS i Windows. Silnik posiada kilka ulepszeń.
%prep
%setup -q
%patch0 -p1
-%patch1 -p1
+
+%{__sed} -i -e '1s,/usr/bin/python$,%{__python},' admin/extend2da.py
%build
-%{__libtoolize}
-%{__aclocal}
-%{__autoconf}
-%{__autoheader}
-%{__automake}
-%configure
+install -d build
+cd build
+%cmake .. \
+ -DBIN_DIR="%{_bindir}" \
+ -DSYSCONF_DIR="%{_sysconfdir}/gemrb" \
+ -DLIB_DIR="%{_libdir}" \
+ -DPLUGIN_DIR="%{_libdir}/gemrb/plugins" \
+ -DDATA_DIR="%{_datadir}/gemrb" \
+ -DMAN_DIR="%{_mandir}/man6" \
+ -DICON_DIR="%{_pixmapsdir}" \
+ -DSVG_DIR="%{_iconsdir}/hicolor/scalable/apps" \
+ -DMENU_DIR="%{_desktopdir}" \
+ -DOPENGL_BACKEND=%{!?with_gles:OpenGL}%{?with_gles:GLES} \
+ -DSDL_BACKEND=SDL2
%{__make}
%install
rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_datadir}/gemrb/Cache}
-%{__make} install \
+%{__make} install -C build \
DESTDIR=$RPM_BUILD_ROOT
-install gemrb/GemRB.cfg.sample.in $RPM_BUILD_ROOT%{_sysconfdir}/gemrb.cfg
-%{__rm} $RPM_BUILD_ROOT%{_libdir}{,/gemrb/plugins}/*.la
+%{__rm} -r $RPM_BUILD_ROOT%{_docdir}
+%{__rm} $RPM_BUILD_ROOT%{_sysconfdir}/gemrb/GemRB.cfg{.noinstall,}.sample
+%{__mv} $RPM_BUILD_ROOT%{_sysconfdir}/gemrb/{GemRB.cfg,gemrb.cfg}
%clean
rm -rf $RPM_BUILD_ROOT
-%post -p /sbin/ldconfig
-%postun -p /sbin/ldconfig
+%post
+/sbin/ldconfig
+%update_desktop_database_post
+%update_icon_cache hicolor
+
+%postun
+/sbin/ldconfig
+%update_desktop_database_postun
+%update_icon_cache hicolor
%files
%defattr(644,root,root,755)
-%doc AUTHORS ChangeLog NEWS README TODO %{name}{/docs/en/*.txt,/GemRB.cfg*.sample}
+%doc AUTHORS CONTRIBUTING.md NEWS README.md %{name}/{docs/en/*.txt,GemRB.cfg*.sample}
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/gemrb/gemrb.cfg
%attr(755,root,root) %{_bindir}/gemrb
+%attr(755,root,root) %{_libdir}/libgemrb_core.so.*.*.*
%dir %{_libdir}/gemrb
-%attr(755,root,root) %{_libdir}/lib*.so.*.*.*
%dir %{_libdir}/gemrb/plugins
-%attr(755,root,root) %{_libdir}/gemrb/plugins/*.so*
-%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/gemrb.cfg
+%attr(755,root,root) %{_libdir}/gemrb/plugins/*.so
%{_datadir}/gemrb
%{_mandir}/man6/gemrb.6*
+%{_desktopdir}/gemrb.desktop
+%{_iconsdir}/hicolor/scalable/apps/gemrb.svg
+%{_pixmapsdir}/gemrb.png
diff --git a/gemrb-config_file.patch b/gemrb-config_file.patch
index e3d0c2d..0fe71ed 100644
--- a/gemrb-config_file.patch
+++ b/gemrb-config_file.patch
@@ -1,20 +1,32 @@
---- gemrb-0.6.2/gemrb/GemRB.cfg.sample.in~ 2010-08-20 19:49:10.000000000 +0200
-+++ gemrb-0.6.2/gemrb/GemRB.cfg.sample.in 2010-08-23 09:46:33.358610584 +0200
-@@ -194,7 +194,7 @@
- # enter the full path to the GemRB executable #
+--- gemrb-0.8.7/gemrb/GemRB.cfg.sample.in.orig 2021-04-23 12:11:03.909680837 +0200
++++ gemrb-0.8.7/gemrb/GemRB.cfg.sample.in 2021-04-23 12:16:48.730617624 +0200
+@@ -157,7 +157,7 @@
+ # Remember, EE versions are not supported! #
#####################################################
--#GemRBPath=@DATA_DIR@
-+GemRBPath=@DATA_DIR@
+-GamePath=/mnt/windows/Programmi/Black Isle/BGII - SoA/
++GamePath=./
+ # only set these if the folders are not in your GamePath
+ #CD1=/mnt/windows/Programmi/Black Isle/BGII - SoA/
+ #CD2=/mnt/windows/Programmi/Black Isle/BGII - SoA/CD2/
+@@ -173,7 +173,7 @@
+ # Cache directory. #
+ #####################################################
+
+-CachePath=@DEFAULT_CACHE_DIR@
++CachePath=~/.cache/gemrb
#####################################################
- # GemRB GUI Scripts Path [String] #
-@@ -205,7 +205,7 @@
- # the 'GUIScript' subdirectory. #
+ # GemRB Save Path [String] #
+@@ -200,10 +200,7 @@
#####################################################
--#GUIScriptsPath=@DATA_DIR@
-+GUIScriptsPath=@DATA_DIR@
+ # preconfigured path
+-#GemRBPath=@DATA_DIR@
+-
+-# path for official binaries
+-GemRBPath=.
++GemRBPath=@DATA_DIR@
#####################################################
- # GemRB Plugins Path [String] #
+ # GemRB GUI Scripts Path [String] #
diff --git a/gemrb-useless_files.patch b/gemrb-useless_files.patch
deleted file mode 100644
index 1acc5e9..0000000
--- a/gemrb-useless_files.patch
+++ /dev/null
@@ -1,14 +0,0 @@
---- gemrb-0.6.2/gemrb/Makefile.am~ 2010-08-20 19:49:10.000000000 +0200
-+++ gemrb-0.6.2/gemrb/Makefile.am 2010-08-23 09:48:03.319399915 +0200
-@@ -1,10 +1,9 @@
- bin_PROGRAMS = gemrb
--sysconf_DATA = GemRB.cfg.sample.in
- gemrb_SOURCES = GemRB.cpp
-
- gemrb_LDADD = ./core/libgemrb_core.la
-
--SUBDIRS = core plugins includes GUIScripts override docs
-+SUBDIRS = core plugins includes GUIScripts override
- EXTRA_DIST = GemRB.cfg* plugins-prepare.sh CMakeLists.txt
-
- gemrb_LDFLAGS = $(all_libraries) @LIBPTHREAD@
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/gemrb.git/commitdiff/f645b233796039f92cd30d35d61a71f5972b6027
More information about the pld-cvs-commit
mailing list