File valyriatear.spec of Package valyriatear
#
# spec file for package valyriatear
#
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define real_name ValyriaTear
Name: valyriatear
Version: 1.0.0+20160126
Release: 0
Summary: Valyria Tear J-RPG game
License: GPL-2.0+
Group: Amusements/Games/RPG
Url: http://valyriatear.blogspot.de/
# ./update.sh
Source0: %{real_name}-%{version}.tar.xz
Source99: %{name}.changes
# PATCH-FEATURE-UPSTREAM use-system-luabind.patch -- use system provided luabind instead of bundled
Patch0: use-system-luabind.patch
BuildRequires: boost-devel
BuildRequires: cmake
BuildRequires: fdupes
BuildRequires: gcc-c++
BuildRequires: glibc-devel
BuildRequires: hicolor-icon-theme
BuildRequires: pkgconfig(SDL2_image)
BuildRequires: pkgconfig(SDL2_ttf)
BuildRequires: pkgconfig(glew)
BuildRequires: pkgconfig(libpng)
BuildRequires: pkgconfig(lua)
BuildRequires: pkgconfig(luabind)
BuildRequires: pkgconfig(ogg)
BuildRequires: pkgconfig(openal)
BuildRequires: pkgconfig(sdl2)
BuildRequires: pkgconfig(vorbis)
BuildRequires: pkgconfig(x11)
Recommends: %{name}-lang
%description
Valyria Tear is an open-source single-player medieval-fantasy 2D J-RPG
based on an extended [Hero of Allacrost](http://www.allacrost.org/) engine
and inspired by classic console RPGs.
%lang_package
%prep
%setup -q -n %{real_name}-%{version}
%patch0 -p1
# Fix usage of __DATE__
modified="$(sed -n '/^----/n;s/ - .*$//;p;q' "%{_sourcedir}/%{name}.changes")"
DATE="\"$(date -d "${modified}" "+%%b %%e %%Y")\""
sed -i "s@__DATE__@$DATE@g" src/modes/boot/boot.cpp
%build
%cmake -DEDITOR_SUPPORT=ON -DUSE_SYSTEM_LUABIND=ON
make %{?_smp_mflags} VERBOSE=1
%install
%cmake_install
%fdupes %{buildroot}/%{_datadir}
%find_lang %{name} %{?no_lang_C}
%files
%defattr(-,root,root)
%doc AUTHORS COPYING.CC0 COPYING.CC-BY-3 COPYING.CC-BY-SA-3 COPYING.GPL-2 COPYING.GPL-3 LICENSES MANUAL README.md README-SDL.txt
%{_bindir}/*
%dir %{_datadir}/valyriatear
%{_datadir}/valyriatear/*
%dir %{_datadir}/appdata/
%{_datadir}/appdata/valyriatear.appdata.xml
%{_datadir}/applications/valyriatear.desktop
%{_datadir}/icons/hicolor/48x48/apps/valyriatear.png
%files lang -f %{name}.lang
%defattr(-,root,root)
%changelog