You are not logged in.

#1 2012-07-20 00:15:52

latjay
Member
Registered: 2012-06-30
Posts: 7

[REQUEST] smokinguns, smokinguns-data, smokinguns-mappack

There already is a "smokinguns" package in the AUR, but it's a 32-bit binary and it's the same as the smokinguns-bin package, and unmantained. What's needed is a smokinguns package built from source, smokinguns-data and additionaly smokinguns-mappack.

The game engine's source code:
http://smokinguns.svn.sourceforge.net/v … guns/tags/

The data files:
http://www.smokin-guns.org/downloads/Sm … ns_1.1.zip

The map pack:
http://q3alive.net/deb/main/smokinguns- … -1_all.deb

The list of maps contained in the map pack:
http://forum.smokin-guns.org/viewtopic. … 507#p24507

All the above-mentioned packages built for Debian (both 32-bit and 64-bit):
http://q3alive.net/deb/main/

Offline

#2 2012-07-20 20:35:21

leper
Member
Registered: 2011-02-17
Posts: 5

Re: [REQUEST] smokinguns, smokinguns-data, smokinguns-mappack

Note: The 1.1 release compiles just fine on x86_64, but executing the resulting binary leads to a segmentation fault (and an error message 'ERROR: opStack corrupted in compiled code (offset 4)'). This is caused by the removal of some code upstream.
So smokinguns won't run on x86_64 natively without some patching (from ioquake3 svn).

i686 isn't tested and there is a TODO in the PKGBUILD.

smokinguns

pkgname=smokinguns
pkgver=1.1
pkgrel=1
pkgdesc='A semi-realistic simulation of the "old west" great atmosphere built on id Tech 3.'
url="http://www.smokin-guns.org"
arch=('x86_64' 'i686')
license=('GPL2')
depends=('sdl' 'openal' 'curl' 'zlib' 'libjpeg' 'speex' 'libgl' 'smokinguns-data')
makedepends=('subversion')
conflicts=('smokinguns-bin')
replaces=('westernquake3')
source=()

svntrunk=https://smokinguns.svn.sourceforge.net/svnroot/smokinguns/tags/release_${pkgver}
svnmod=tag

build() {
  cd "$srcdir"
  msg "Connecting to SVN server...."

  if [[ -d "$svnmod/.svn" ]]; then
    (cd "$svnmod" && svn up)
  else
    svn co "$svntrunk" --config-dir ./ "$svnmod"
  fi

  msg "SVN checkout done or server timeout"
  msg "Starting build..."

  rm -rf "$srcdir/$svnmod-build"
  cp -r "$srcdir/$svnmod" "$srcdir/$svnmod-build"
  cd "$srcdir/$svnmod-build"

  # Build
  # Set basedir
  echo "DEFAULT_BASEDIR = /usr/share/${pkgname}" >> "$srcdir/$svnmod-build/Makefile.local"
  # Use system libraries
  echo "USE_INTERNAL_ZLIB=0" >> "$srcdir/$svnmod-build/Makefile.local"
  echo "USE_INTERNAL_JPEG=0" >> "$srcdir/$svnmod-build/Makefile.local"
  echo "USE_INTERNAL_SPEEX=0" >> "$srcdir/$svnmod-build/Makefile.local"
  make -j3
}

package() {
  cd "${srcdir}/${svnmod}-build"

  # TODO Check if $arch works on i686 as the folder could be called i386
  # and fix it if it doesn't work.
  install -Dm 755 "$srcdir/$svnmod-build/build/release-linux-$arch/$pkgname.$arch" "$pkgdir/usr/bin/$pkgname"
  install -Dm 755 "$srcdir/$svnmod-build/build/release-linux-$arch/${pkgname}_dedicated.$arch" "$pkgdir/usr/bin/${pkgname}_dedicated"
}

# vim:set ts=2 sw=2 et:

smokinguns-data

pkgname=smokinguns-data
pkgver=1.1
pkgrel=1
pkgdesc='A semi-realistic simulation of the "old west" great atmosphere built on id Tech 3. (data files)'
url="http://www.smokin-guns.org"
arch=('any')
license=('custom')
depends=()
makedepends=()
source=('http://www.smokin-guns.org/downloads/Smokin_Guns_1.1.zip')
md5sums=('f6eac64fa534fa9ff121dda5fd2dba44')

package() {
  cd "$srcdir/Smokin' Guns $pkgver"
  install -d "$pkgdir/usr/share/${pkgname%%-*}/baseq3"
  install -m 644 baseq3/* "$pkgdir/usr/share/${pkgname%%-*}/baseq3"
  install -d "$pkgdir/usr/share/${pkgname%%-*}/smokinguns"
  install -m 644 smokinguns/* "$pkgdir/usr/share/smokinguns/smokinguns"
}

# vim:set ts=2 sw=2 et:

EDIT: namcap lists zlib as already satisfied, and openal and curl as unneeded but the makefile indicates that both of them are loaded during runtime (USE_OPENAL_DLOPEN=1).

Last edited by leper (2012-07-20 20:41:22)

Offline

#3 2012-07-22 18:23:43

latjay
Member
Registered: 2012-06-30
Posts: 7

Re: [REQUEST] smokinguns, smokinguns-data, smokinguns-mappack

The beta_1.1b4 tag runs fine on Linux after compiling for x86_64, so maybe the patch should be taken from the last SVN revision before the removal of the backport for the x86_64 support, or alternatively from the last beta tag.

Offline

#4 2012-07-22 19:18:23

leper
Member
Registered: 2011-02-17
Posts: 5

Re: [REQUEST] smokinguns, smokinguns-data, smokinguns-mappack

I adopted smokinguns and updated it with a refined version of the previously posted PKGBUILD. I also added a patch for x86_64 (backported from ioquake3 trunk). i686 isn't tested and not present in the new PKGBUILD.

Offline

#5 2012-07-22 21:44:50

latjay
Member
Registered: 2012-06-30
Posts: 7

Re: [REQUEST] smokinguns, smokinguns-data, smokinguns-mappack

$arch doesn't work on i686.

Please add a .desktop file. There is one in the smokinguns-bin package.

I added the package of maps:
https://aur.archlinux.org/packages.php?ID=61121

I wonder if it's possible to use a direct link to the tarball from the SVN repo to avoid the subversion dependency.

I also wonder if it would be better to install files to /usr/share/games... instead of /usr/share...

Last edited by latjay (2012-07-22 21:45:18)

Offline

#6 2012-07-23 15:38:11

leper
Member
Registered: 2011-02-17
Posts: 5

Re: [REQUEST] smokinguns, smokinguns-data, smokinguns-mappack

1.1-5 should now work on i686. I added a slightly modified desktop file and thanks for the tip regarding the tarball.

The Arch Packaging Standards tells us to use /usr/share and not /usr/share/games. (Just take a look at other games in the official repositories.)

btw: It would be great if you could adopt the maps package (again). I'll probably add it as an optdepend to smokinguns in the next few days.

Offline

Board footer

Powered by FluxBB