Accepting request 397791 from home:nemysis:branches:games

Please accept these changes.

OBS-URL: https://build.opensuse.org/request/show/397791
OBS-URL: https://build.opensuse.org/package/show/games/asteroid?expand=0&rev=3
This commit is contained in:
Dmitriy Perlow 2016-05-25 07:55:52 +00:00 committed by Git OBS Bridge
parent a4b9d64dd8
commit 32de879756
6 changed files with 69 additions and 15 deletions

18
_service Normal file
View File

@ -0,0 +1,18 @@
<services>
<service name="tar_scm">
<param name="scm">git</param>
<param name="url">git://github.com/chazomaticus/asteroid.git</param>
<param name="version">1.2.1+git-4efc7fc</param>
<param name="revision">4efc7fc0a1246f023d6f96b94081678e302ab430</param>
<param name="package-meta">yes</param>
</service>
<service name="recompress">
<param name="compression">bz2</param>
<param name="file">*.tar</param>
</service>
<service name="download_files" />
</services>

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:491f2bf0c6c7f4448feb0e589498ba43df6a38e1d4ffe630a7b6923d93523d3c
size 1041350

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:8f97bfbc59fc52426fbe4ead3bff45cdd62625157eef198e678772cce239c259
size 998884

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Tue May 24 20:48:43 UTC 2016 - nemysis@openSUSE.org
- Rerolled tarball
- Add %global commit and %global shortcommit
- Add _service and generate-service-file.sh
- Remove check %if 0%{?suse_version}, because is only for openSUSE
-------------------------------------------------------------------
Thu Oct 30 15:23:11 UTC 2014 - nemysis@gmx.ch

View File

@ -1,7 +1,7 @@
#
# spec file for package asteroid
#
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
# 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
@ -16,6 +16,9 @@
#
%global commit 4efc7fc0a1246f023d6f96b94081678e302ab430
%global shortcommit %(c=%{commit}; echo ${c:0:7})
Name: asteroid
Version: 1.2.1
Release: 0
@ -25,23 +28,22 @@ Group: Amusements/Games/Action/Arcade
Url: https://chazomaticus.github.io/asteroid/
# Downloaded from https://github.com/chazomaticus/asteroid
# Packed as tar.bz2
Source0: %{name}-%{version}+git0e37197.tar.bz2
Source0: %{name}-%{version}+git-4efc7fc.tar.bz2
Source1: generate-service-file.sh
# PATCH-FEATURE-UPSTREAM Asteroid not build in openSUSE #1
Patch0: %{name}-%{version}-CMakeLists.txt.patch
%if 0%{?suse_version}
BuildRequires: fdupes
BuildRequires: update-desktop-files
%endif
BuildRequires: cmake
BuildRequires: fdupes
BuildRequires: freeglut-devel
BuildRequires: gcc-c++
BuildRequires: gtk2-devel
BuildRequires: hicolor-icon-theme
BuildRequires: update-desktop-files
BuildRequires: pkgconfig(SDL_mixer)
BuildRequires: pkgconfig(glu)
BuildRequires: pkgconfig(sdl)
BuildRequires: pkgconfig(xi)
BuildRequires: pkgconfig(xmu)
BuildRequires: pkgconfig(sdl)
%description
Asteroid (just one!) is a modern version of the arcade classic Asteroids,
@ -50,7 +52,7 @@ It features a variety of powerups, taunting aliens, 3D textured asteroids,
face-melting sound effects, and infinite playability.
%prep
%setup -q -n %{name}
%setup -q -n %{name}-%{version}+git-%{shortcommit}
%patch0
@ -67,10 +69,8 @@ make %{?_smp_mflags}
%install
%make_install
%if 0%{?suse_version}
%suse_update_desktop_file %{name}
%fdupes -s %{buildroot}%{_prefix}
%endif
%suse_update_desktop_file %{name}
%fdupes -s %{buildroot}%{_prefix}
%files
%defattr(-,root,root,-)

28
generate-service-file.sh Normal file
View File

@ -0,0 +1,28 @@
#!/bin/sh
commit=4efc7fc0a1246f023d6f96b94081678e302ab430
shortcommit=$(c=${commit}; echo ${c:0:7})
version=1.2.1+git
echo -n "Creating _service file ..."
cat << EOF > _service
<services>
<service name="tar_scm">
<param name="scm">git</param>
<param name="url">git://github.com/chazomaticus/asteroid.git</param>
<param name="version">${version}-${shortcommit}</param>
<param name="revision">${commit}</param>
<param name="package-meta">yes</param>
</service>
<service name="recompress">
<param name="compression">bz2</param>
<param name="file">*.tar</param>
</service>
<service name="download_files" />
</services>
EOF
echo done