diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b6f54a0 --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +/xu4-20150221svn.tar.xz +u4/ +*.rpm diff --git a/dead.package b/dead.package deleted file mode 100644 index 5204a84..0000000 --- a/dead.package +++ /dev/null @@ -1 +0,0 @@ -Orphaned for 6+ weeks diff --git a/sources b/sources new file mode 100644 index 0000000..dba925f --- /dev/null +++ b/sources @@ -0,0 +1 @@ +a1457b1e403d573e3323da0961708824 xu4-20150221svn.tar.xz diff --git a/u4download.txt b/u4download.txt new file mode 100644 index 0000000..3148701 --- /dev/null +++ b/u4download.txt @@ -0,0 +1,89 @@ + +(Punt's note: "Boomer" is Mike McCoy of Origin / Jane's Combat sims +he's often seen posting to rec.games.computer.ultima.*, +comp.sys.ibm.pc.games.rpg and possibly others. Full headers and + "extra recipients" snipped for brevity and privacy.) + +---mailed to moi. Some non-Ultima-download stuff snipped-- +Date: Tue, 21 Oct 1997 07:18:26 -0500 +To: mfleming@powerup.com.au +From: Mike McCoy +Subject: Re: UIV - you mean we can *distribute* it? +Mime-Version: 1.0 +Content-Type: text/plain; charset="us-ascii" +Status: O + +At 07:37 AM 10/19/97 +1000, you wrote: +>Boomer, +> +>I've been the recipient of a forward from Edward Franks (Fortran) +>regarding the distribution of Ultima IV and I'm mighty confused.. + +sorry for the confusion... let's see if I can clarify + +1. the U4 distribution in the magazine was intended to be an 'exclusive' +for the mag. +2. Once the mag distribution was over, it was felt nothing much could be +done to stop redistribution of U4 after that +3. KickAss was offering U4 for d/l, but the Dragons couldn't (per a +previous 'restriction' by Origin?) +4. I said, that's not fair to the Dragons... They've been honest about +this. Why not let them offer it as well.. Answer: Your absolutely right.. +5. Ergo: email to Fortran Dragon 'OK'ing' the ability to offer U4 for free +d/l by Dragons + + +----forward from Fortran---- +From: Edward Franks +Subject: Fwd: Ultima IV +Cc: mfleming@powerup.com.au, + + + +Mime-Version: 1.0 +Content-Type: text/plain; charset="iso-8859-1" +Content-Transfer-Encoding: quoted-printable +Status: O + +>Return-Path: +>Received: from darius.concentric.net by sleepy.ponyexpress.net +(SMI-8.6/SMI-SVR4) +>id RAA20780; Fri, 17 Oct 1997 17:42:48 -0500 +>Received: from mcfeely.concentric.net (mcfeely.concentric.net +[207.155.184.83]) +>by darius.concentric.net (8.8.7/(97/09/12 5.7)) +>id SAA13835; Fri, 17 Oct 1997 18:45:53 -0400 (EDT) +>[1-800-745-2747 The Concentric Network] +>Errors-To: +>Received: from crc3.concentric.net (ts001d03.aus-tx.concentric.net +[206.173.144.15]) +>by mcfeely.concentric.net (8.8.7) +>id SAA24560; Fri, 17 Oct 1997 18:45:51 -0400 (EDT) +>Message-Id: <3.0.32.19971017174430.0086b100@pop3.cris.com> +>X-Sender: boomer@pop3.cris.com +>X-Mailer: Windows Eudora Pro Version 3.0 (32) +>Date: Fri, 17 Oct 1997 17:44:32 -0500 +>To: xyzzy@ponyexpress.net +>From: Mike McCoy +>Subject: Ultima IV +>Mime-Version: 1.0 +>Content-Type: text/plain; charset=3D"us-ascii" +>Content-Length: 285 +>Status: =A0=A0 +> +> +>Frotran, +> +>Not sure if this should go to you or not. If not, please forward it to the +>appropriate Dragon. +> +>I just got a decision about allowing the Dragons to offer Ultima IV as a +>free d/l (i.e. re-distributing the game on the CGW CD). +> +>Go for it (and kick ass on KickAss ;) +> +>Boomer + +Fortran Dragon | "There isn't enough darkness in the world +-=3D=3D{MDLAM}=3D=3D- | to quench the light of one small candle." +Hidalgo Trading Company: http://www.ponyexpress.net/~xyzzy/index.html diff --git a/xu4-1.0beta3-desktop.patch b/xu4-1.0beta3-desktop.patch new file mode 100644 index 0000000..5c6b64c --- /dev/null +++ b/xu4-1.0beta3-desktop.patch @@ -0,0 +1,14 @@ +--- u4/u4.desktop~ 2007-04-29 20:36:20.000000000 +0200 ++++ u4/u4.desktop 2007-04-29 20:37:20.000000000 +0200 +@@ -2,8 +2,8 @@ + Encoding=UTF-8 + Name=Ultima 4 + Comment=Ultima 4 (xu4) +-Exec=u4 ++Exec=u4 -f + Icon=u4.png +-Terminal=0 ++Terminal=false + Type=Application +-Categories=Application;Game;RolePlaying; ++Categories=Game;RolePlaying; diff --git a/xu4-1.1-format-security.patch b/xu4-1.1-format-security.patch new file mode 100644 index 0000000..87d7d77 --- /dev/null +++ b/xu4-1.1-format-security.patch @@ -0,0 +1,12 @@ +diff -u -r u4-format-security/src/screen_sdl.cpp u4/src/screen_sdl.cpp +--- u4-format-security/src/screen_sdl.cpp 2015-01-23 21:44:46.000000000 -0600 ++++ u4/src/screen_sdl.cpp 2015-02-22 15:59:04.665560535 -0600 +@@ -257,7 +257,7 @@ + + screenRefreshThread = SDL_CreateThread(screenRefreshThreadFunction, NULL); + if (!screenRefreshThread) { +- errorWarning(SDL_GetError()); ++ errorWarning("%s", SDL_GetError()); + return; + } + } diff --git a/xu4-1.1-unbundle.patch b/xu4-1.1-unbundle.patch new file mode 100644 index 0000000..d6a63b6 --- /dev/null +++ b/xu4-1.1-unbundle.patch @@ -0,0 +1,38 @@ +diff -u -r u4-unbundle/src/Makefile.common u4/src/Makefile.common +--- u4-unbundle/src/Makefile.common 2012-03-18 06:32:01.000000000 -0500 ++++ u4/src/Makefile.common 2015-02-22 15:23:52.420625704 -0600 +@@ -6,7 +6,6 @@ + CSRCS=\ + lzw/hash.c \ + lzw/lzw.c \ +- unzip.c \ + $(NULL) + + CXXSRCS=\ +diff -u -r u4/src/Makefile.unbundle u4/src/Makefile +--- u4/src/Makefile.unbundle 2010-12-13 16:50:58.000000000 -0600 ++++ u4/src/Makefile 2011-03-29 20:23:10.861965251 -0500 +@@ -15,7 +15,7 @@ FEATURES=-DHAVE_BACKTRACE=1 -DHAVE_VARIA + DEBUGCXXFLAGS=-ggdb1 -rdynamic -g -O0 -fno-inline -fno-eliminate-unused-debug-types -gstabs -g3 + CXXFLAGS=$(FEATURES) -Wall -I. $(UIFLAGS) $(shell xml2-config --cflags) -DICON_FILE=\"$(datadir)/pixmaps/u4.bmp\" -DVERSION=\"$(VERSIO + CFLAGS=$(CXXFLAGS) +-LIBS=$(UILIBS) $(shell xml2-config --libs) -lpng -lz ++LIBS=$(UILIBS) $(shell xml2-config --libs) -lpng -lz $(EXTRALIBS) + INSTALL=install + + ifeq ($(STATIC_GCC_LIBS),true) +diff -u -r u4-unbundle/src/u4file.cpp u4/src/u4file.cpp +--- u4-unbundle/src/u4file.cpp 2015-02-22 15:22:38.738442217 -0600 ++++ u4/src/u4file.cpp 2015-02-22 15:28:54.605175840 -0600 +@@ -5,9 +5,9 @@ + #include + #include + #include ++#include + + #include "u4file.h" +-#include "unzip.h" + #include "debug.h" + #ifdef MACOSX + #include + diff --git a/xu4-svn-checkout.sh b/xu4-svn-checkout.sh new file mode 100755 index 0000000..54eed8a --- /dev/null +++ b/xu4-svn-checkout.sh @@ -0,0 +1,10 @@ +#!/bin/bash +DATE=$(date +%Y%m%d) + +set -x + +rm -rf u4 +svn export https://xu4.svn.sourceforge.net/svnroot/xu4/trunk/u4 u4 +tar cJf xu4-${DATE}svn.tar.xz u4 + +rm -rf u4 diff --git a/xu4.autodlrc b/xu4.autodlrc new file mode 100644 index 0000000..d409db5 --- /dev/null +++ b/xu4.autodlrc @@ -0,0 +1,37 @@ +[MESSAGELIST] +[MESSAGE] + [TITLE]Please click 'Accept' to allow internet access.[/TITLE] + [TEXT]XU4 is a remake of the computer game Ultima IV. This game requires the original Ultima IV datafiles, which can be freely downloaded from the internet but may not be (re)distributed. + +Please click Accept to allow XU4 to access the internet to download the necessary datafiles.[/TEXT] +[/MESSAGE] +[MESSAGE] + [TITLE]License Information[/TITLE] + [TEXT]Ultima4 is released as Dragonware by Origin, this means that it may only be distributed by Ultima DragonsĀ® through Ultima DragonsĀ® websites. + +For the original permission notice from Origin for this see: +http://martin.brenner.de/ultima/u4download.txt +or: +/usr/share/doc/xu4-1.1/u4download.txt[/TEXT] +[/MESSAGE] +[/MESSAGELIST] + +[FILELIST] +[FILE] + [FILENAME]ultima4.zip[/FILENAME] + [MD5]5092e11579f2093bca2d67c1d1788c88[/MD5] + [PATH]$HOME/.xu4[/PATH] + [MIRRORS] + [URL]http://martin.brenner.de/ultima/ultima4.zip[/URL] + [URL]http://www.thatfleminggent.com/ultima/ultima4.zip[/URL] + [/MIRRORS] +[/FILE] +[FILE] + [FILENAME]u4upgrad.zip[/FILENAME] + [MD5]4ce9c9cd9dab111275e0ebfde7a482c4[/MD5] + [PATH]$HOME/.xu4[/PATH] + [MIRRORS] + [URL]http://www.moongates.com/u4/upgrade/files/u4upgrad.zip[/URL] + [/MIRRORS] +[/FILE] +[/FILELIST] diff --git a/xu4.sh b/xu4.sh new file mode 100644 index 0000000..d315841 --- /dev/null +++ b/xu4.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +set -e + +if [ ! -f $HOME/.xu4/ultima4.zip -o \ + ! -f $HOME/.xu4/u4upgrad.zip ]; then + if [ -f /usr/lib64/u4/xu4.autodlrc ]; then + /usr/share/autodl/AutoDL.py /usr/lib64/u4/xu4.autodlrc + else + /usr/share/autodl/AutoDL.py /usr/lib/u4/xu4.autodlrc + fi +fi + +cd $HOME/.xu4 +exec /usr/bin/u4.bin "$@" diff --git a/xu4.spec b/xu4.spec new file mode 100644 index 0000000..f7f9e27 --- /dev/null +++ b/xu4.spec @@ -0,0 +1,201 @@ +%define svndate 20150221 +%define svnrev 3087 + +Name: xu4 +Version: 1.1 +Release: 0.25.%{svndate}svn%{svnrev}%{?dist} +Summary: Ultima IV recreated +Group: Amusements/Games +License: GPLv2+ +URL: http://xu4.sourceforge.net/ +# This was generated by running the xu4-svn-checkout.sh script +Source0: xu4-%{svndate}svn.tar.xz +Source1: xu4.sh +Source2: xu4.autodlrc +Source3: u4download.txt +Patch0: xu4-1.0beta3-desktop.patch +Patch1: xu4-1.1-unbundle.patch +Patch2: xu4-1.1-format-security.patch +BuildRequires: SDL_mixer-devel libxml2-devel minizip-devel +BuildRequires: libicns-utils libpng-devel desktop-file-utils +Requires: hicolor-icon-theme autodownloader + +%description +XU4 is a remake of the computer game Ultima IV. This game requires the +original Ultima IV datafiles, which can be freely downloaded from the internet +but may not be (re)distributed. When you start xu4 for the first time it will +offer to download the datafiles for you. + +XU4 isn't a new game based on the Ultima IV story -- it is a faithful +recreation of the old game, right up to the crappy graphics. If you +are looking for a game with modern gameplay and graphics, this is not +it -- yet. New features that improve the gameplay and keep with the +spirit of the original game will be added. + + +%prep +%autosetup -p1 -n u4 +if [ "%{_lib}" = "lib64" ]; then + sed -i 's|/usr/lib|%{_libdir}|g' src/u4file.cpp +fi +cp %{SOURCE3} . + + +%build +pushd src +make DEBUGCXXFLAGS="%{optflags}" EXTRALIBS=-lminizip\ + bindir=%{_bindir} datadir=%{_datadir} libdir=%{_libdir} %{?_smp_mflags} +popd + +# The apple icns file has a higher resolution icon, but still not 256x256. +pushd icons +icns2png -x xu4.icns +popd + +%install +pushd src +# Note: make install DESTDIR=%%{buildroot}, doesn't work +%{makeinstall} +find %{buildroot}/%{_libdir}/u4 -name '*.xml' -o -name '*.dtd'|xargs chmod -x +popd +cp -p mid/*.it %{buildroot}/%{_libdir}/u4/music + +# mv u4 to u4.bin and install our autodl wrapper script +mv %{buildroot}/%{_bindir}/u4 %{buildroot}/%{_bindir}/u4.bin +install -p -m 755 %{SOURCE1} %{buildroot}/%{_bindir}/u4 +install -p -m 644 %{SOURCE2} %{buildroot}/%{_libdir}/u4 + +# below is the desktop file and icon stuff. +desktop-file-install \ + --dir %{buildroot}/%{_datadir}/applications \ + --delete-original \ + %{buildroot}/%{_datadir}/applications/u4.desktop + +mkdir -p %{buildroot}/%{_datadir}/icons/hicolor/128x128/apps +install -p -m 655 icons/xu4_128x128x32.png \ + %{buildroot}/%{_datadir}/icons/hicolor/128x128/apps/u4.png +rm -rf %{buildroot}/%{_datadir}/pixmaps + + +%post +touch --no-create %{_datadir}/icons/hicolor &>/dev/null || : + +%postun +if [ $1 -eq 0 ]; then + touch --no-create %{_datadir}/icons/hicolor &>/dev/null || : + gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : +fi + +%posttrans +gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : + +%files +%doc AUTHORS COPYING README doc/Algorithms.* doc/*FileFormats.txt +%doc doc/U4Notes.txt doc/tools.txt u4download.txt +%{_bindir}/u4* +%{_libdir}/u4 +%{_datadir}/applications/u4.desktop +%{_datadir}/icons/hicolor/128x128/apps/u4.png + + +%changelog +* Fri Jun 19 2015 Fedora Release Engineering - 1.1-0.25.20150221svn3087 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + +* Sat May 02 2015 Kalev Lember - 1.1-0.24.20150221svn3087 +- Rebuilt for GCC 5 C++11 ABI change + +* Tue Feb 24 2015 Jason L Tibbitts III - 1.1-0.23.20150221svn3087 +- Oops, I screwed up and made the version go backwards. + +* Sat Feb 21 2015 Jason L Tibbitts III - 1.1-0.1.20150221svn3087 +- Update from SVN. +- Extract higher resulution icon from macos .icns archive. +- Fix a format-security error. + +* Mon Aug 18 2014 Fedora Release Engineering - 1.1-0.22.20120106svn2999 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + +* Sun Jun 08 2014 Fedora Release Engineering - 1.1-0.21.20120106svn2999 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + +* Sun Aug 04 2013 Fedora Release Engineering - 1.1-0.20.20120106svn2999 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + +* Sun Feb 10 2013 Parag Nemade - 1.1-0.19.20120106svn2999 +- Remove vendor tag from desktop file as per https://fedorahosted.org/fesco/ticket/1077 +- Cleanup spec as per recently changed packaging guidelines + +* Sun Jul 22 2012 Fedora Release Engineering - 1.1-0.18.20120106svn2999 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Fri Jan 06 2012 Jason L Tibbitts III - 1.1-0.17.20120106svn2999 +- Update to latest SVN. + +* Thu Dec 15 2011 Jason L Tibbitts III - 1.1-0.16.20111215svn2997 +- Update to new snapshot, fixing (among other things) the libpng build issue. +- Remove unneeded zipfile patch. +- Use recommended gtk icon cache scriptlets. + +* Tue Dec 06 2011 Adam Jackson - 1.1-0.15.20110329svn2873 +- Rebuild for new libpng + +* Tue Mar 29 2011 Jason L Tibbitts III - 1.1-0.14.20110329svn2873 +- Slightly newer snapshot with more fixes. +- Use the system minizip library instead of the ancient bundled version. + +* Tue Mar 29 2011 Jason L Tibbitts III - 1.1-0.13.20110329svn2869 +- Update to latest SVN snapshot. +- Drop gcc46 patch; no longer needed. +- Add buildfix patch. +- Install the .it music files manually so that music works again. +- Switch from $RPM_* to macros with less yelling. + +* Tue Feb 08 2011 Fedora Release Engineering - 1.1-0.12.20110124svn2792 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Mon Jan 24 2011 Jason L Tibbitts III - 1.1-0.11.20110124svn2792 +- Update to latest SVN, just past the beta4 tag made by upstream. +- Add patch for building with gcc46. + +* Wed Jan 19 2011 Jason L Tibbitts III - 1.1-0.10.20110119svn2776 +- Update to current SVN. Upstream indicates that this should fix bug 666631. + +* Thu Jan 06 2011 Jason L Tibbitts III - 1.1-0.9.20110106svn2767 +- Update to current SVN now that development has picked back up. +- Update to current Fedora packaging guidelines. +- Turn on parallel make. +- Update download links in autodlrc. + +* Tue Jan 19 2010 Jason L Tibbitts III - 1.1-0.8.20100119svn2725 +- Upstream revived! Now uses SVN; switch everything over to that. +- Provide a checkout script instead of requiring cut-n-paste. +- Use correct versioning (date comes first). +- Drop gcc44 patch; upstream has fixed the issues. + +* Mon Jul 27 2009 Fedora Release Engineering - 1.1-0.7.cvs20090209 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Thu Feb 26 2009 Fedora Release Engineering - 1.1-0.6.cvs20090209 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Mon Feb 09 2009 Jason L Tibbitts III - 1.1-0.5.cvs20090209 +- Update to latest CVS snapshot - it contains a few minor bugfixes. +- Tweak for gcc 4.4. + +* Tue Feb 19 2008 Fedora Release Engineering - 1.1-0.4.cvs20070510 +- Autorebuild for GCC 4.3 + +* Fri Jan 11 2008 Hans de Goede 1.1-0.3.cvs20070510 +- Fix compilation with gcc 4.3 + +* Wed Aug 15 2007 Hans de Goede 1.1-0.2.cvs20070510 +- Update License tag for new Licensing Guidelines compliance + +* Fri May 11 2007 Hans de Goede 1.1-0.1.20070510 +- Update to latest CVS, as this actually makes the game finishable +- Add missing BuildRequires: desktop-file-utils +- Add u4download.txt to the docs + +* Thu Feb 1 2007 Hans de Goede 1.0-0.1.beta3 +- Initial Fedora Extras package