diff options
author | Mikołaj "D1SoveR" Banasik | 2022-11-19 23:16:55 +0000 |
---|---|---|
committer | Mikołaj "D1SoveR" Banasik | 2022-11-19 23:19:42 +0000 |
commit | f5013cb34dae0ed0a82cea1072a4365e562fc5d3 (patch) | |
tree | 63db544f95b2aeb5466d530f35e28bf4dc698556 | |
parent | 543b284d9ca5dde2ef1cefbd1f13515598eeecf5 (diff) | |
download | aur-f5013cb34dae0ed0a82cea1072a4365e562fc5d3.tar.gz |
Updates to build process from AUR feedback.
* Added clang to make dependencies
* Replaced unzip with bsdtar to reduce the amount of build dependencies
* Godot requires X11 for builds, added conditional dependency on xvfb-run when running makepkg in headless environment
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 26 |
2 files changed, 24 insertions, 6 deletions
@@ -1,7 +1,7 @@ pkgbase = luxtorpeda-git pkgdesc = Steam Play compatibility tool to run games using native Linux engines pkgver = 60.0.0.r370.2c040cd - pkgrel = 1 + pkgrel = 2 url = https://github.com/luxtorpeda-dev/luxtorpeda arch = x86_64 arch = i686 @@ -9,7 +9,9 @@ pkgbase = luxtorpeda-git makedepends = git makedepends = rust makedepends = godot + makedepends = clang optdepends = steam: The Steam client + optdepends = xorg-server-xvfb: For building in headless environments provides = luxtorpeda conflicts = luxtorpeda source = git+https://github.com/luxtorpeda-dev/luxtorpeda.git @@ -1,16 +1,27 @@ # Maintainer: Mikołaj "D1SoveR" Banasik <d1sover@gmail.com> pkgname='luxtorpeda-git' pkgver=60.0.0.r370.2c040cd -pkgrel=1 +pkgrel=2 pkgdesc='Steam Play compatibility tool to run games using native Linux engines' arch=('x86_64' 'i686') url='https://github.com/luxtorpeda-dev/luxtorpeda' license=('GPL2') depends=() -makedepends=('git' 'rust' 'godot') +makedepends=('git' 'rust' 'godot' 'clang') optdepends=('steam: The Steam client') provides=("${pkgname%-git}") conflicts=("${pkgname%-git}") +options=('!lto') + +# Godot requires X11 for its builder even with '--no-window' option; +# if we operate under X11-less environment, we will need to add framebuffer wrapper +# so that the build can still run correctly +if [ ! -v DISPLAY ]; then + makedepends+=('xorg-server-xvfb') + godot_command=('xvfb-run' "--auth-file=$(mktemp -u)" '--error-file=/dev/stderr' 'make') +else + godot_command=('make') +fi source=("git+${url}.git" 'reproducible-build.patch' @@ -69,8 +80,13 @@ build() { echo "SHA512 checksums verified" # Unpack the godot templates into user-local directory - mkdir -p "$godot_template_dir" - unzip -j "$godot_download_loc" -d "$godot_template_dir" + ( + echo "Unpacking export templates into user directory..." && + mkdir -p "$godot_template_dir" && + cd "$godot_template_dir" && + bsdtar -xf "$godot_download_loc" && + mv templates/* . && rmdir templates + ) fi # Perform build and track what its success/failure is; @@ -79,7 +95,7 @@ build() { if ( cd "$srcdir/${pkgname%-git}" && mkdir -p "target/release" && - make GODOT=/usr/bin/godot luxtorpeda + "${godot_command[@]}" GODOT=/usr/bin/godot luxtorpeda ); then build_exitcode=0 else |