From 1366a0556beb82b819a45991133507fba678fd70c2b260069a8e4964d836e6dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Mail=C3=A4nder?= Date: Mon, 8 Jun 2015 19:00:50 +0000 Subject: [PATCH] Accepting request 311184 from home:nemysis Please accept this new RPM. This is one good cult game. OBS-URL: https://build.opensuse.org/request/show/311184 OBS-URL: https://build.opensuse.org/package/show/games/wumpus?expand=0&rev=1 --- .gitattributes | 23 +++++++++++ .gitignore | 1 + superhack.desktop | 9 ++++ wumpus-1.6.tar.gz | 3 ++ wumpus-Makefile.patch | 32 +++++++++++++++ wumpus-rpmlintrc | 2 + wumpus-superhack.c.patch | 20 +++++++++ wumpus-wumpus.c.patch | 12 ++++++ wumpus.changes | 5 +++ wumpus.desktop | 9 ++++ wumpus.png | 3 ++ wumpus.spec | 89 ++++++++++++++++++++++++++++++++++++++++ 12 files changed, 208 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 superhack.desktop create mode 100644 wumpus-1.6.tar.gz create mode 100644 wumpus-Makefile.patch create mode 100644 wumpus-rpmlintrc create mode 100644 wumpus-superhack.c.patch create mode 100644 wumpus-wumpus.c.patch create mode 100644 wumpus.changes create mode 100644 wumpus.desktop create mode 100644 wumpus.png create mode 100644 wumpus.spec diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/superhack.desktop b/superhack.desktop new file mode 100644 index 0000000..9d0b123 --- /dev/null +++ b/superhack.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=Superhack +GenericName=Wumpus satire +Comment=Superhack is a satire, structurally quite similar to Wumpus +Icon=wumpus +Exec=superhack +Type=Application +Categories=Game;StrategyGame; +Terminal=true diff --git a/wumpus-1.6.tar.gz b/wumpus-1.6.tar.gz new file mode 100644 index 0000000..a01c489 --- /dev/null +++ b/wumpus-1.6.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:965e49b3e53f44023994b42b3aa568ad79d3a2287bb0a07460b601500c9ae16d +size 11694 diff --git a/wumpus-Makefile.patch b/wumpus-Makefile.patch new file mode 100644 index 0000000..b5e949f --- /dev/null +++ b/wumpus-Makefile.patch @@ -0,0 +1,32 @@ +--- Makefile.orig 2015-04-04 12:38:03.000000000 +0200 ++++ Makefile 2015-06-08 20:36:13.445880866 +0200 +@@ -27,12 +27,25 @@ + SOURCES = README COPYING NEWS Makefile wumpus.c superhack.c wumpus.xml + + install: wumpus.6 +- cp wumpus superhack /usr/bin/ +- cp wumpus.6 /usr/share/man/man6/ ++ install -m 0755 -d $(DESTDIR)/usr/bin/ ++ install -m 0755 -d $(DESTDIR)/usr/share/man/man6/ ++ install -m 0755 -d $(DESTDIR)//usr/share/applications/ ++ install -m 0755 -d $(DESTDIR)/usr/share/icons/hicolor/48x48/apps/ ++ install -m 0755 -d $(DESTDIR)/usr/share/appdata/ ++ install -m 0755 superhack wumpus $(DESTDIR)/usr/bin/ ++ install -m 0644 wumpus.6 $(DESTDIR)/usr/share/man/man6/ ++ install -m 0644 wumpus.desktop $(DESTDIR)/usr/share/applications/ ++ install -m 0644 superhack.desktop $(DESTDIR)/usr/share/applications/ ++ install -m 0644 wumpus.png $(DESTDIR)/usr/share/icons/hicolor/48x48/apps/ ++ install -m 0644 wumpus.xml $(DESTDIR)/usr/share/appdata/ + + uninstall: +- rm /usr/bin/wumpus /usr/bin/superhack +- rm /usr/share/man/man6/wumpus.6 ++ rm -f /usr/bin/superhack /usr/bin/wumpus ++ rm -f /usr/share/man/man6/wumpus.6 ++ rm -f /usr/share/applications/wumpus.desktop ++ rm -f /usr/share/applications/superhack.desktop ++ rm -f /usr/share/icons/hicolor/48x48/apps/wumpus.png ++ rm -f /usr/share/appdata/wumpus.xml + + CPPCHECKOPTS = + cppcheck: diff --git a/wumpus-rpmlintrc b/wumpus-rpmlintrc new file mode 100644 index 0000000..ba74f8e --- /dev/null +++ b/wumpus-rpmlintrc @@ -0,0 +1,2 @@ +# # This is needed Wumpus name in summary +addFilter("name-repeated-in-summary") diff --git a/wumpus-superhack.c.patch b/wumpus-superhack.c.patch new file mode 100644 index 0000000..810d1fe --- /dev/null +++ b/wumpus-superhack.c.patch @@ -0,0 +1,20 @@ +--- superhack.c.orig 2015-04-04 12:36:55.000000000 +0200 ++++ superhack.c 2015-06-08 18:29:28.574280952 +0200 +@@ -13,6 +13,9 @@ + #include + #include + #include ++#include ++#include ++#include + + static int path[5]; + static int j, k, scratchloc, pies; +@@ -423,6 +426,7 @@ + break; + } + } ++ return 0; + } + + /* superhack.c ends here */ diff --git a/wumpus-wumpus.c.patch b/wumpus-wumpus.c.patch new file mode 100644 index 0000000..4e3c879 --- /dev/null +++ b/wumpus-wumpus.c.patch @@ -0,0 +1,12 @@ +--- wumpus.c.orig 2015-04-04 12:31:47.000000000 +0200 ++++ wumpus.c 2015-06-08 18:43:34.738979482 +0200 +@@ -30,6 +30,9 @@ + #include + #include + #include ++#include ++#include ++#include + + /* 5 REM *** HUNT THE WUMPUS *** */ + diff --git a/wumpus.changes b/wumpus.changes new file mode 100644 index 0000000..a2efda8 --- /dev/null +++ b/wumpus.changes @@ -0,0 +1,5 @@ +------------------------------------------------------------------- +Mon Jun 8 18:26:47 UTC 2015 - nemysis@gmx.ch + +- Initial package creation + diff --git a/wumpus.desktop b/wumpus.desktop new file mode 100644 index 0000000..47bb268 --- /dev/null +++ b/wumpus.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Name=Wumpus +GenericName=Hunt the Wumpus +Comment=The classic game of Hunt the Wumpus +Icon=wumpus +Exec=wumpus +Type=Application +Categories=Game;StrategyGame; +Terminal=true diff --git a/wumpus.png b/wumpus.png new file mode 100644 index 0000000..bd0e284 --- /dev/null +++ b/wumpus.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:77b7b8696ef13915332b8278f3d5be4082eaa5c68a2632ad9eb22d720f5b8950 +size 2952 diff --git a/wumpus.spec b/wumpus.spec new file mode 100644 index 0000000..2f87db1 --- /dev/null +++ b/wumpus.spec @@ -0,0 +1,89 @@ +# +# spec file for package wumpus +# +# Copyright (c) 2015 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 oname superhack + +Name: wumpus +Version: 1.6 +Release: 0 +Summary: Faithful transcription of the 1974 Atari Wumpus game +License: BSD-3-Clause +Group: Amusements/Games/Action/Race +Url: http://www.catb.org/~esr/wumpus/ +Source0: http://www.catb.org/~esr/%{name}/%{name}-%{version}.tar.gz +Source1: %{name}-rpmlintrc +Source2: %{name}.desktop +Source3: %{oname}.desktop +Source4: %{name}.png +# PATCH-FIX-UPSTREAM - wumpus-Makefile.patch -- Fix paths and installation +Patch0: %{name}-Makefile.patch +# PATCH-FIX-UPSTREAM - wumpus-superhack.c.patch -- Fix bad C++ code +Patch1: %{name}-superhack.c.patch +# PATCH-FIX-UPSTREAM - wumpus-wumpus.c.patch -- Fix bad C++ code +Patch2: %{name}-wumpus.c.patch +%if 0%{?suse_version} +BuildRequires: hicolor-icon-theme +BuildRequires: update-desktop-files +%endif +BuildRequires: ncurses-devel +BuildRoot: %{_tmppath}/%{name}-%{version}-build + +%description +WUMPUS is a bit of retrocomputing nostalgia. It is an *exact* clone, +even down to the godawful user interface, of an ancient classic game. +This version fixes two minor bugs in my original 1992 USENET posting +of the source. Superhack is a structurally similar game with a +different premise. + +%prep +%setup -q +%patch0 +%patch1 +%patch2 + +cp -af %{S:2} . +cp -af %{S:3} . +cp -af %{S:4} . + +%build +make %{?_smp_mflags} CFLAGS="%{optflags}" + +%install +%make_install + +# Symlink Manpage +ln -sf %{_mandir}/man6/%{name}.6%{ext_man} %{buildroot}%{_mandir}/man6/%{oname}.6%{ext_man} + +%if 0%{?suse_version} + %suse_update_desktop_file %{name} +%endif + +%files +%defattr(-,root,root,-) +%doc COPYING README +%{_bindir}/%{name} +%{_bindir}/%{oname} +%{_mandir}/man6/%{name}.6%{ext_man} +%{_mandir}/man6/%{oname}.6%{ext_man} +%dir %{_datadir}/appdata +%{_datadir}/appdata/%{name}.xml +%{_datadir}/applications/%{name}.desktop +%{_datadir}/applications/%{oname}.desktop +%{_datadir}/icons/hicolor/ + +%changelog