summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 860e74ad8e86476311dec03757f908863db6f3e4 (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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# Maintainer: Radioactiveman <thomas-lange2@gmx.de>
# Contributor: Sven-Hendrik Haase <sh@lutzhaase.com>
# Contributor: Lauri Niskanen <ape@ape3000.com>
# Contributor: Sebastian.Salich@gmx.de
# Contributor: Doc Angelo

# If you want support for your G15 Keyboard, please add 'g15daemon'
# to the depends and delete "no-g15" in the configure line below

pkgname=mumble-git
pkgver=2019.10.22
_pkgver=1.4.0
pkgrel=1
arch=('i686' 'x86_64')
pkgdesc='A voice chat application similar to TeamSpeak'
url='https://www.mumble.info/'
license=('BSD')
depends=('qt5-base' 'qt5-svg' 'speex' 'lsb-release' 'avahi' 'protobuf' 'libpulse' 'opus'
         'xdg-utils' 'libspeechd' 'libpng' 'freetype2' 'fontconfig' 'libxrender')
makedepends=('boost' 'git' 'jack' 'mesa' 'python' 'qt5-tools')
optdepends=('jack: JACK audio output'
            'espeak-ng: Text to Speech support'
            'speech-dispatcher: Text to Speech support')
conflicts=('mumble')
provides=('mumble')
source=('git://github.com/mumble-voip/mumble.git' 'https://git.xiph.org/celt.git'
        'git://github.com/mumble-voip/fx11.git' 'git://github.com/mumble-voip/opus.git'
        'git://github.com/mumble-voip/sbcelt.git' 'https://git.xiph.org/speex.git')
sha256sums=('SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP' 'SKIP')

pkgver() {
  cd "$srcdir/mumble"
  git log -n 1 --pretty=format:"%cd" --date=short | sed "s/-/./g"
}

prepare() {
  cd "$srcdir/mumble"

  git submodule init
  git config submodule.3rdparty/fx11-src.url "$srcdir/fx11"
  git config submodule.3rdparty/celt-0.7.0-src.url "$srcdir/celt"
  git config submodule.3rdparty/opus-src.url "$srcdir/opus"
  git config submodule.3rdparty/sbcelt-src.url "$srcdir/sbcelt"
  git config submodule.3rdparty/speex-src.url "$srcdir/speex"
  git submodule update
}

build() {
  cd "$srcdir/mumble"

  # Building mumble
  qmake-qt5 main.pro \
    CONFIG+="bundled-celt no-bundled-opus no-bundled-speex no-g15 no-xevie \
             no-server no-embed-qt-translations no-update packaged" \
    DEFINES+="PLUGIN_PATH=/usr/lib/mumble" \
    INCLUDEPATH+="/usr/include/speech-dispatcher" \
    LIBS+="-lpng16 -lfreetype -lXrender -lfontconfig"

  make release
}

package() {
  cd "$srcdir/mumble"

  # bin stuff
  install -m755 -D ./release/mumble "$pkgdir"/usr/bin/mumble
  install -m755 -D ./scripts/mumble-overlay "$pkgdir"/usr/bin/mumble-overlay

  # lib stuff
  install -m755 -D ./release/libmumble.so.$_pkgver "$pkgdir"/usr/lib/mumble/libmumble.so.$_pkgver
  ln -s libmumble.so.$_pkgver "$pkgdir"/usr/lib/mumble/libmumble.so
  ln -s libmumble.so.$_pkgver "$pkgdir"/usr/lib/mumble/libmumble.so.1
  ln -s libmumble.so.$_pkgver "$pkgdir"/usr/lib/mumble/libmumble.so.${_pkgver:0:3}
  install -m755 -D ./release/plugins/liblink.so "$pkgdir"/usr/lib/mumble/liblink.so
  install -m755 -D ./release/libcelt* "$pkgdir"/usr/lib/mumble/

  # other stuff
  install -m644 -D ./scripts/mumble.desktop "$pkgdir"/usr/share/applications/mumble.desktop
  install -m755 -d "$pkgdir"/usr/share/man/man1
  install -m644 -D ./man/mum* "$pkgdir"/usr/share/man/man1/
  install -m644 -D ./icons/mumble.svg "$pkgdir"/usr/share/icons/hicolor/scalable/apps/mumble.svg
  install -m644 -D ./LICENSE "$pkgdir"/usr/share/licenses/mumble/LICENSE
}