summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 3ff5c125dd832e764963fbe736a509fbd31756df (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Maintainer: tytan652 <tytan652@tytanium.xyz>
pkgname=obs-text-pango
pkgver=1.0
pkgrel=2
pkgdesc="This plugin provides a text source for OBS Studio which is layed out and rendered using Pango"
arch=('x86_64')
url="https://github.com/kkartaltepe/obs-text-pango"
license=("GPL2")
depends=("obs-studio")
makedepends=('cmake')
source=(
  "$pkgname-$pkgver.tar.gz::https://github.com/kkartaltepe/obs-text-pango/archive/v$pkgver.tar.gz"
  "updated_french.patch::https://patch-diff.githubusercontent.com/raw/kkartaltepe/obs-text-pango/pull/12.patch"
)
sha256sums=(
  '07bc145256393a902637ade6820d03988b655796748733ecec53790d370d2e4e'
  "SKIP"
)

prepare() {
  rm -rf fakeroot
}

build() {
  cd "$pkgname-$pkgver"
  patch -Np1 < "$srcdir"/updated_french.patch
  cmake -B build \
  -DOBS_INCLUDE_DIRS='/usr/include/obs' \
  -DCMAKE_INSTALL_PREFIX='/'
  make -C build
}

package() {
  mkdir -p "$pkgdir"/usr/lib/obs-plugins
  mkdir -p "$pkgdir"/usr/share/obs/obs-plugins

  cd "$pkgname-$pkgver"
  make -C build DESTDIR="$srcdir/fakeroot/" install

  cp -a "$srcdir"/fakeroot/obs-plugins/64bit/libtext-pango.so "$pkgdir"/usr/lib/obs-plugins
  cp -a "$srcdir"/fakeroot/data/obs-plugins/text-pango "$pkgdir"/usr/share/obs/obs-plugins/
}