Skip to content
Snippets Groups Projects
PKGBUILD 1.48 KiB
Newer Older
Eric Vidal's avatar
Eric Vidal committed
# Maintainer: Eric Vidal <eric@obarun.org>
# based on the original https://git.archlinux.org/svntogit/community.git/log/trunk?h=packages/weston
# 						Maintainer: Sébastien Luttringer
# 						Contributor: Joel Teichroeb <joel@teichroeb.net>

pkgname=weston
Eric Vidal's avatar
Eric Vidal committed
pkgver=6.0.1
Eric Vidal's avatar
Eric Vidal committed
pkgrel=2
Eric Vidal's avatar
Eric Vidal committed
pkgdesc='Reference implementation of a Wayland compositor'
Eric Vidal's avatar
Eric Vidal committed
arch=('x86_64')
Eric Vidal's avatar
Eric Vidal committed
url='https://wayland.freedesktop.org/'
license=('MIT')
depends=('glibc' 'wayland' 'libxkbcommon' 'libinput' 'libunwind' 'pixman'
         'libdrm' 'pam' 'cairo' 'libpng' 'libjpeg-turbo' 'libwebp'
         'mesa' 'libegl' 'libgles' 'glib2' 'pango' 'lcms2' 'mtdev' 'libx11'
Eric Vidal's avatar
Eric Vidal committed
         'libxcb' 'dbus' 'libva' 'libxcursor' 'colord' 'freerdp')
makedepends=('wayland-protocols' 'meson' 'ninja')
Eric Vidal's avatar
Eric Vidal committed
source=("https://wayland.freedesktop.org/releases/$pkgname-$pkgver.tar.xz")
md5sums=('e7b10710ef1eac82258f97bfd41fe534')
Eric Vidal's avatar
Eric Vidal committed

Eric Vidal's avatar
Eric Vidal committed
prepare() {
Eric Vidal's avatar
Eric Vidal committed
  cd $pkgname-$pkgver
Eric Vidal's avatar
Eric Vidal committed
  # apply patch from the source array (should be a pacman feature)
  local src
  for src in "${source[@]}"; do
    src="${src%%::*}"
    src="${src##*/}"
    [[ $src = *.patch ]] || continue
    msg2 "Applying patch $src..."
    patch -Np1 < "../$src"
  done
}

build() {
  meson $pkgname-$pkgver build \
Eric Vidal's avatar
Eric Vidal committed
    --prefix=/usr \
Eric Vidal's avatar
Eric Vidal committed
    --libexec=lib/weston \
    -Dsimple-dmabuf-drm=auto \
    -Dsystemd=false \
    -Dlauncher-logind=false
  ninja -C build
Eric Vidal's avatar
Eric Vidal committed
}

package() {
Eric Vidal's avatar
Eric Vidal committed
  DESTDIR="$pkgdir" ninja -C build install
Eric Vidal's avatar
Eric Vidal committed
  # license
Eric Vidal's avatar
Eric Vidal committed
  install -Dm644 $pkgname-$pkgver/COPYING "$pkgdir/usr/share/licenses/$pkgname/COPYING"