J'ai donc décidé de reprendre le PKGBUILD de Celmir, pour l'adapter aux machines x86_64.
Etant mon premier PKGBUILD, je vous le propose en correction, car je ne sais si il fonctionne sur toutes les machines 64 bits, et je sais pas trops rédiger les entètes des scripts....
Le voilà tel quel
Code : Tout sélectionner
pkgname=landes-eternelles
pkgver=1.5
pkgrel=1
pkgdesc="French spoken MMORPG"
arch=(x86_64)
license=('custom:eternal_lands_license')
url="http://www.landes-eternelles.com"
makedepends=('make')
depends=('sdl_net' 'libxml2' 'cal3d' 'freealut' 'libvorbis' 'mesa' 'sdl_image')
install=('landes-eternelles.install')
source=( http://www.landes-eternelles.com/client/LandesEternellesLinux-$pkgver.tgz http://www.landes-eternelles.com/client/Sources_Client_1_5.zip http://www.landes-eternelles.com/client/music.zip http://www.landes-eternelles.com/client/el.X86_64.linux.bin http://www.landes-eternelles.com/client/mapedit.x86_64.linux.bin)
md5sums=('a4376a5c1d7e1fc9ea06b029b86e20de'
'eb426bdb62ef591a65b089601ad17306'
'4ebd92279b4b813ad176bc78331b8a3a'
'5dc1f1043b478e0582c7d1354e92bc5a'
'15d32045350015fa4fedcc74bcc2b393')
build() {
sed 's/PLATFORM=-march=i686/PLATFORM=-mtune=x86-64/' -i $startdir/src/sources/make.defaults
sed 's/#FEATURES += X86_64/FEATURES += X86_64/' -i $startdir/src/sources/make.defaults
sed 's/EXE=el.x86.linux.bin/EXE=el.X86_64.linux.bin/' -i $startdir/src/sources/Makefile.linux
cd $startdir/src/sources
make -f Makefile.linux || return 1
rm -f $startdir/src/LandesEternellesLinux/{el.x86.linux.bin,mapedit.x86.linux.bin}
cp -f $startdir/el.X86_64.linux.bin $startdir/src/LandesEternellesLinux
cp -f $startdir/mapedit.x86_64.linux.bin $startdir/src/LandesEternellesLinux
chmod +x $startdir/src/LandesEternellesLinux/el.X86_64.linux.bin
chmod +x $startdir/src/LandesEternellesLinux/mapedit.x86_64.linux.bin
cd $startdir/src
cp -fr music $startdir/src/LandesEternellesLinux
mkdir -p $startdir/pkg/usr/share/{games,licenses}/$pkgname
mv $startdir/src/LandesEternellesLinux/eternal_lands_license.txt $startdir/pkg/usr/share/licenses/$pkgname
cp -fr $startdir/src/LandesEternellesLinux/* $startdir/pkg/usr/share/games/$pkgname
chmod -R 0755 $startdir/pkg/usr/share/games/$pkgname
chown -R root:root $startdir/pkg/usr/share/games/$pkgname
}
Code : Tout sélectionner
post_install() {
echo "cd /usr/share/games/landes-eternelles && ./el.X86_64.linux.bin &" > /usr/bin/landes
chmod 0755 /usr/bin/landes
}
post_remove() {
rm -f /usr/bin/landes
}