Reverted packaging changes from launchers.
This commit is contained in:
committed by
Paul Chote
parent
a81c865620
commit
4eaf97f90e
@@ -1,35 +1,26 @@
|
||||
#!/bin/bash
|
||||
# OpenRA packaging master script for linux packages
|
||||
|
||||
if [ $# -ne "4" ]; then
|
||||
echo "Usage: `basename $0` version files-dir outputdir arch"
|
||||
if [ $# -ne "3" ]; then
|
||||
echo "Usage: `basename $0` version files-dir outputdir"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
VERSION=$1
|
||||
BUILTDIR=$2
|
||||
PACKAGEDIR=$3
|
||||
ROOTDIR=root$4
|
||||
ROOTDIR=root
|
||||
|
||||
# Clean up
|
||||
rm -rf $ROOTDIR
|
||||
|
||||
# Game files
|
||||
mkdir -p $ROOTDIR/usr/bin/
|
||||
if [ $4 = "x64" ]; then
|
||||
cp -T $BUILTDIR/gtklaunch $ROOTDIR/usr/bin/openra
|
||||
else
|
||||
cp -T $BUILTDIR/gtklaunch32 $ROOTDIR/usr/bin/openra
|
||||
fi
|
||||
cp -T openra-bin root/usr/bin/openra
|
||||
|
||||
mkdir -p $ROOTDIR/usr/share/openra/
|
||||
cp -R $BUILTDIR/* "$ROOTDIR/usr/share/openra/" || exit 3
|
||||
|
||||
# Remove unneeded files
|
||||
rm $ROOTDIR/usr/share/openra/OpenRA.Launcher.exe
|
||||
rm $ROOTDIR/usr/share/openra/gtklaunch
|
||||
rm $ROOTDIR/usr/share/openra/gtklaunch32
|
||||
|
||||
# Desktop Icons
|
||||
mkdir -p $ROOTDIR/usr/share/applications/
|
||||
sed "s/{VERSION}/$VERSION/" openra.desktop > $ROOTDIR/usr/share/applications/openra.desktop
|
||||
@@ -47,28 +38,25 @@ cp -r hicolor $ROOTDIR/usr/share/icons/
|
||||
(
|
||||
echo "Building Debian package."
|
||||
cd deb
|
||||
./buildpackage.sh "$VERSION" ../$ROOTDIR "$PACKAGEDIR" $4 &> package.log
|
||||
./buildpackage.sh "$VERSION" ../$ROOTDIR "$PACKAGEDIR" &> package.log
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "Debian package build failed, refer to $PWD/package.log."
|
||||
fi
|
||||
) &
|
||||
|
||||
if [ $4 = 'x86' ]
|
||||
then
|
||||
(
|
||||
echo "Building Arch-Linux package."
|
||||
cd pkgbuild
|
||||
sh buildpackage.sh "$VERSION" ../$ROOTDIR "$PACKAGEDIR" $4 &> package.log
|
||||
sh buildpackage.sh "$VERSION" ../$ROOTDIR "$PACKAGEDIR" &> package.log
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "Arch-Linux package build failed, refer to $PWD/package.log."
|
||||
fi
|
||||
) &
|
||||
fi
|
||||
|
||||
(
|
||||
echo "Building RPM package."
|
||||
cd rpm
|
||||
sh buildpackage.sh "$VERSION" ../$ROOTDIR ~/rpmbuild "$PACKAGEDIR" $4 &> package.log
|
||||
sh buildpackage.sh "$VERSION" ../$ROOTDIR ~/rpmbuild "$PACKAGEDIR" &> package.log
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "RPM package build failed, refer to $PWD/package.log."
|
||||
fi
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
Package: openra
|
||||
Version: {VERSION}
|
||||
Architecture: {ARCH}
|
||||
Architecture: all
|
||||
Maintainer: Matthew Bowra-Dean <matthew@ijw.co.nz>
|
||||
Uploaders: Maikel van den Hout <ma1kelvdh@gmail.com>, Paul Chote <sleipnir@sleipnirstuff.com>
|
||||
Installed-Size: {SIZE}
|
||||
Depends: libopenal1, mono-runtime, libmono-winforms2.0-cil, libfreetype6, libsdl1.2debian, libgl1-mesa-glx, libgl1-mesa-dri, libmono-i18n2.0-cil, libgtk2.0-0, libwebkit-1.0-2
|
||||
Depends: libopenal1, mono-runtime, libmono-winforms2.0-cil, libfreetype6, libsdl1.2debian, libgl1-mesa-glx, libgl1-mesa-dri, libmono-i18n2.0-cil
|
||||
Section: games
|
||||
Priority: extra
|
||||
Homepage: http://www.open-ra.org/
|
||||
Description: A multiplayer reimplementation of the Command & Conquer: Red Alert game engine in .NET/Mono, OpenGL, OpenAL and SDL. Has extensive modding support and includes Command & Conquer as an official mod.
|
||||
Description: A multiplayer reimplementation of the Command & Conquer: Red Alert game engine in .NET/Mono.
|
||||
.
|
||||
Please note: OpenRA is currently at an alpha release stage. Releases may be buggy
|
||||
or unstable. If you have any problems, please report them to the IRC channel (#openra on
|
||||
|
||||
@@ -1,40 +1,34 @@
|
||||
#!/bin/bash
|
||||
# OpenRA packaging script for Debian based distributions
|
||||
E_BADARGS=85
|
||||
if [ $# -ne "4" ]
|
||||
if [ $# -ne "3" ]
|
||||
then
|
||||
echo "Usage: `basename $0` version root-dir outputdir arch"
|
||||
echo "Usage: `basename $0` version root-dir outputdir"
|
||||
exit $E_BADARGS
|
||||
fi
|
||||
VERSION=$1
|
||||
rootdir=`readlink -f $2`
|
||||
PACKAGE_SIZE=`du --apparent-size -c $rootdir/usr | grep "total" | awk '{print $1}'`
|
||||
if [ $4 = "x64" ]
|
||||
then
|
||||
ARCH=amd64
|
||||
else
|
||||
ARCH=i386
|
||||
fi
|
||||
|
||||
# Copy template files into a clean build directory (required)
|
||||
mkdir root$ARCH
|
||||
cp -R DEBIAN root$ARCH
|
||||
cp -R $rootdir/usr root$ARCH
|
||||
mkdir root
|
||||
cp -R DEBIAN root
|
||||
cp -R $rootdir/usr root
|
||||
|
||||
# Create the control and changelog files from templates
|
||||
sed "s/{VERSION}/$VERSION/" DEBIAN/control | sed "s/{SIZE}/$PACKAGE_SIZE/" | sed "s/{ARCH}/$ARCH/" > root$ARCH/DEBIAN/control
|
||||
sed "s/{VERSION}/$VERSION/" DEBIAN/changelog > root$ARCH/DEBIAN/changelog
|
||||
sed "s/{VERSION}/$VERSION/" DEBIAN/control | sed "s/{SIZE}/$PACKAGE_SIZE/" > root/DEBIAN/control
|
||||
sed "s/{VERSION}/$VERSION/" DEBIAN/changelog > root/DEBIAN/changelog
|
||||
|
||||
# Build it in the temp directory, but place the finished deb in our starting directory
|
||||
pushd root$ARCH
|
||||
pushd root
|
||||
|
||||
# Calculate md5sums and clean up the /usr/ part of them
|
||||
md5sum `find . -type f | grep -v '^[.]/DEBIAN/'` | sed 's/\.\/usr\//usr\//g' > DEBIAN/md5sums
|
||||
|
||||
# Start building, the file should appear in the output directory
|
||||
dpkg-deb -b . $3/openra-$VERSION-$ARCH.deb
|
||||
dpkg-deb -b . $3/openra-$VERSION.deb
|
||||
|
||||
# Clean up
|
||||
popd
|
||||
rm -rf root$ARCH
|
||||
rm -rf root
|
||||
|
||||
|
||||
3
packaging/linux/openra-bin
Normal file
3
packaging/linux/openra-bin
Normal file
@@ -0,0 +1,3 @@
|
||||
#!/bin/sh
|
||||
cd /usr/share/openra
|
||||
mono /usr/share/openra/OpenRA.Game.exe SupportDir=~/.openra "$@"
|
||||
@@ -3,13 +3,14 @@ pkgname=openra
|
||||
pkgver={VERSION}
|
||||
pkgrel=1
|
||||
pkgdesc="Open Source rebuild of the Red Alert game engine using Mono/OpenGL."
|
||||
arch=('{ARCH}')
|
||||
arch=('any')
|
||||
url="http://open-ra.org"
|
||||
license=('GPL3')
|
||||
groups=()
|
||||
depends=('mono' 'openal' 'mesa' 'freetype2' 'sdl' 'gtk2' 'libwebkit')
|
||||
depends=('mono' 'openal' 'mesa' 'freetype2' 'sdl')
|
||||
makedepends=('git' 'unzip' 'wget')
|
||||
optdepends=()
|
||||
optdepends=('gksu: Elevation for installing game packages on Gnome platforms'
|
||||
'kdesudo: Elevation for installing game packages on KDE platforms')
|
||||
provides=()
|
||||
conflicts=()
|
||||
replaces=()
|
||||
|
||||
@@ -1,32 +1,22 @@
|
||||
#!/bin/bash
|
||||
E_BADARGS=85
|
||||
if [ $# -ne "4" ]
|
||||
if [ $# -ne "3" ]
|
||||
then
|
||||
echo "Usage: `basename $0` version root-dir outputdir arch"
|
||||
echo "Usage: `basename $0` version root-dir outputdir"
|
||||
exit $E_BADARGS
|
||||
fi
|
||||
|
||||
if [ $4 = "x64" ]
|
||||
then
|
||||
ARCH=x86_64
|
||||
else
|
||||
ARCH=i686
|
||||
fi
|
||||
|
||||
# Replace any dashes in the version string with periods
|
||||
PKGVERSION=`echo $1 | sed "s/-/\\./g"`
|
||||
|
||||
cp PKGBUILD PKGBUILD$ARCH
|
||||
|
||||
sed -i "s/{VERSION}/$PKGVERSION/" PKGBUILD$ARCH
|
||||
sed -i "s/{VERSION}/$PKGVERSION/" PKGBUILD
|
||||
rootdir=`readlink -f $2`
|
||||
sed -i "s|{ROOT}|$rootdir|" PKGBUILD$ARCH
|
||||
sed -i "s/{ARCH}/$ARCH/" PKGBUILD$ARCH
|
||||
sed -i "s|{ROOT}|$rootdir|" PKGBUILD
|
||||
|
||||
makepkg --holdver -p PKGBUILD$ARCH
|
||||
makepkg --holdver -p PKGBUILD
|
||||
if [ $? -ne 0 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
mv openra-$PKGVERSION-1-$ARCH.pkg.tar.xz $3
|
||||
mv openra-$PKGVERSION-1-any.pkg.tar.xz $3
|
||||
|
||||
|
||||
@@ -1,42 +1,33 @@
|
||||
#!/bin/bash
|
||||
E_BADARGS=85
|
||||
if [ $# -ne "5" ]
|
||||
if [ $# -ne "4" ]
|
||||
then
|
||||
echo "Usage: `basename $0` version root-dir packaging-dir outputdir arch"
|
||||
echo "Usage: `basename $0` version root-dir packaging-dir outputdir"
|
||||
exit $E_BADARGS
|
||||
fi
|
||||
|
||||
if [ $5 = "x64" ]
|
||||
then
|
||||
ARCH=x86_64
|
||||
else
|
||||
ARCH=i386
|
||||
fi
|
||||
|
||||
# Replace any dashes in the version string with periods
|
||||
PKGVERSION=`echo $1 | sed "s/-/\\./g"`
|
||||
|
||||
cp openra.spec openra$ARCH.spec
|
||||
|
||||
sed -i "s/{VERSION_FIELD}/$PKGVERSION/" openra$ARCH.spec
|
||||
sed -i "s/{VERSION_FIELD}/$PKGVERSION/" openra.spec
|
||||
rootdir=`readlink -f $2`
|
||||
sed -i "s|{ROOT_DIR}|$rootdir|" openra$ARCH.spec
|
||||
sed -i "s|{ROOT_DIR}|$rootdir|" openra.spec
|
||||
|
||||
for x in `find $rootdir -type f`
|
||||
do
|
||||
y="${x#$rootdir}"
|
||||
sed -i "/%files/ a $y" openra$ARCH.spec
|
||||
sed -i "/%files/ a $y" openra.spec
|
||||
done
|
||||
|
||||
cp openra$ARCH.spec "$3/SPECS/"
|
||||
cp openra.spec "$3/SPECS/"
|
||||
|
||||
cd "$3"
|
||||
|
||||
rpmbuild --target $ARCH --buildroot /tmp/openra$ARCH/ -bb SPECS/openra$ARCH.spec
|
||||
rpmbuild --target noarch --buildroot /tmp/openra/ -bb SPECS/openra.spec
|
||||
if [ $? -ne 0 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cd RPMS/$ARCH/
|
||||
mv openra-$PKGVERSION-1.$ARCH.rpm $4
|
||||
cd RPMS/noarch/
|
||||
mv openra-$PKGVERSION-1.noarch.rpm $4
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ License: GPL3
|
||||
URL: http://open-ra.org
|
||||
Group: Amusements/Games
|
||||
Packager: Matthew Bowra-Dean <matthew@ijw.co.nz>
|
||||
Requires: mono-core mono-devel SDL openal mesa-dri-drivers-experimental gtk2 webkitgtk
|
||||
Requires: mono-core mono-devel SDL openal mesa-dri-drivers-experimental
|
||||
Prefix: /usr
|
||||
Source: %{name}-%{version}.tar.gz
|
||||
Buildroot: /tmp/openra
|
||||
|
||||
Reference in New Issue
Block a user