Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

rtaudio PKGBUILD

By: neuromancer85 on Feb 26th, 2012  |  syntax: Bash  |  size: 1.60 KB  |  views: 38  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. # Maintainer: SpepS <dreamspepser at yahoo dot it>
  2.  
  3. pkgname=rtaudio
  4. pkgver=4.0.10
  5. pkgrel=2
  6. pkgdesc="A set of C++ classes that provide a common API for realtime audio input/output."
  7. arch=(i686 x86_64)
  8. url="http://www.music.mcgill.ca/~gary/rtaudio/"
  9. license=('GPL')
  10. depends=('jack')
  11. makedepends=('python2-distribute')
  12. optdepends=('python2: python bindings')
  13. source=("${url}release/${pkgname}-${pkgver}.tar.gz")
  14. md5sums=('68fc7fead74762e5fa3e8aa69ae1c10d')
  15.  
  16. build() {
  17.   cd "$srcdir/$pkgname-$pkgver"
  18.  
  19.   ./configure --prefix=/usr --with-alsa --with-oss --with-jack && make
  20.  
  21.   cd tests && make
  22.  
  23.   # python bindings
  24.   cd ../contrib/python/pyrtaudio
  25.   CFLAGS="$CFLAGS -I../../../include" \
  26.   python2 setup.py build
  27. }
  28.  
  29. package() {
  30.   cd "$srcdir/$pkgname-$pkgver"
  31.  
  32.   # lib
  33.   install -Dm755 librtaudio.so "$pkgdir/usr/lib/librtaudio.so"
  34.  
  35.   # configuration utility
  36.   install -Dm755 rtaudio-config "$pkgdir/usr/bin/rtaudio-config"
  37.  
  38.   # docs
  39.   install -d "$pkgdir"/usr/{include,share/doc}/$pkgname
  40.   cp -a doc/{html,images,release.txt} "$pkgdir/usr/share/doc/$pkgname"
  41.  
  42.   # headers
  43.   install *.h include/* "$pkgdir/usr/include/$pkgname"
  44.  
  45.   # utilities and tests
  46.   for _ex in `find tests -maxdepth 1 -perm 755 -type f`; do
  47.     install -Dm755 $_ex "$pkgdir/usr/bin/$pkgname-${_ex/*\//}"
  48.   done
  49.  
  50.   # python bindings
  51.   cd contrib/python/pyrtaudio && python2 setup.py install --root="$pkgdir/"
  52.  
  53.   # python sample
  54.   install -Dm644 PyRtAudioTest.py "$pkgdir/usr/share/doc/$pkgname/"
  55.  
  56.   # gcc 4.6 header fix
  57.   sed -i "/inline/s/;$//" "$pkgdir/usr/include/$pkgname/RtAudio.h"
  58. }
  59.  
  60. # vim:set ts=2 sw=2 et: