summaryrefslogtreecommitdiffstats
path: root/oss-hg/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'oss-hg/PKGBUILD')
-rw-r--r--oss-hg/PKGBUILD83
1 files changed, 49 insertions, 34 deletions
diff --git a/oss-hg/PKGBUILD b/oss-hg/PKGBUILD
index 0267f56..79f1ad9 100644
--- a/oss-hg/PKGBUILD
+++ b/oss-hg/PKGBUILD
@@ -1,70 +1,85 @@
-# Contributor: lh <jarryson#gmail.com>
+# Archlive <http://archlive-pkg.googlecode.com>
+
pkgname=oss-hg
-pkgver=666
+pkgver=907
pkgrel=1
pkgdesc="Open Sound System UNIX audio architecture"
arch=('i686' 'x86_64')
-url="http://developer.opensound.com/"
+url="http://www.opensound.com/"
license=('GPL2')
-depends=('gcc' 'make' 'kernel-headers' 'module-init-tools' 'libtool' 'sed')
-makedepends=('pkgconfig' 'gawk' 'gtk2' 'mercurial')
-provides=('oss')
+depends=('module-init-tools' 'libtool' 'sed')
+makedepends=('pkgconfig' 'gawk' 'gtk2' 'mercurial' 'gcc' 'make')
+provides=('oss' 'oss4')
conflicts=('oss-linux' 'oss-linux-free' 'oss-testing' 'oss' 'oss-mercurial')
install='oss.install'
-source=('oss.rm-init-scripts.patch' 'oss.rc' 'oss.install')
-md5sums=('b9a380a0ac8896390d71ac13676f27e1'
- '8ca7cdf94c56ab02890eb4aba6a4995f'
- '1494a2304a1eb7a1979e7e83d894c67a')
+backup=('usr/lib/oss/soundon.user')
+source=('oss.rm-init-scripts.patch' 'oss.soundon.patch' 'oss.rc' 'oss.install'
+ 'ossxmix.png' 'ossxmix.desktop')
+md5sums=()
optdepends=('gtk2: for graphical mixer (ossxmix)'
- 'hal: for automatic USB audio configuration'
- 'libflashsupport-oss: for Flash plugin support')
+ 'hal: for automatic USB audio configuration')
-[ "$CARCH" = "x86_64" ] && optdepends[2]='lib32-libflashsupport-oss: for Flash plugin support'
+_hgroot="http://opensound.hg.sourceforge.net:8000/hgroot/opensound/opensound"
+_hgrepo="oss"
-_hgroot=http://mercurial.opensound.com
-_hgrepo=oss
build() {
- cd $srcdir
+ cd $startdir
if [ -d ${_hgrepo} ]; then
- cd ${srcdir}/${_hgrepo}
- hg pull -u
+ cd ${_hgrepo} && hg pull -u -r ${pkgver}
else
hg clone ${_hgroot} ${_hgrepo} || return 1
- cd ${srcdir}/${_hgrepo}
fi
+
+ [ -d $srcdir/${_hgrepo} ] && rm -rf $srcdir/${_hgrepo}
+ hg clone $startdir/${_hgrepo} $srcdir/${_hgrepo}
+ cd $srcdir/${_hgrepo}
+ zsh
# Avoid these flags conflicting with OSS build system.
unset CFLAGS
unset OSFLAGS
unset LIBRARIES
export NO_WARNING_CHECKS=yes
-
- # Remove libflashsupport, as it belongs to a separate package.
- rm -f "$srcdir/$_hgrepo/oss/lib/flashsupport.c" &> /dev/null
- msg "Preparing the build environment."
+ # Compile libflashsupport.so only in packaging time, so we avoid
+ # conflicts with other packages and ease package management.
+ msg "Building libflashsupport.so."
+ cd "oss/lib"
+ gcc -shared -fPIC -O2 -Wall -Werror flashsupport.c -o libflashsupport.so || return 1
+ install -Dm755 libflashsupport.so "${pkgdir}/usr/lib/libflashsupport.so" || return 1
+ #rm -f "flashsupport.c" "libflashsupport.so" &> /dev/null
- # have to remove this dir. because maybe the scource is different now.
- rm -rf $srcdir/$_hgrepo-build
- # Create build directory and configure
- mkdir $srcdir/$_hgrepo-build && cd srcdir/$_hgrepo-build
- "$srcdir/$_hgrepo/configure" --enable-libsalsa=NO || return 1
+ msg "Preparing the build environment."
+ cd $srcdir/${_hgrepo}
+ [ -d build ] && rm -rf build
+ mkdir build && cd build
+ ../configure --regparm --config-midi=YES --enable-timings --portable-build || return 1
+ #../configure --enable-libsalsa=YES || return 1
msg "Building OSS."
make build || return 1
msg "Patching init scripts."
- cd "$srcdir/build/prototype"
+ cd prototype
rm usr/lib/oss/etc/S89oss
- patch -b -p0 < "$srcdir/oss.rm-init-scripts.patch" || return 1
+ patch -Np0 -i "$srcdir/oss.rm-init-scripts.patch" || return 1
+ patch -Np0 -i "$srcdir/oss.soundon.patch" || return 1
msg "Copying files."
- cp -R * "$pkgdir"
- chmod 755 "$pkgdir/usr/sbin/" "$pkgdir/usr/lib/oss/etc/" "$pkgdir/usr/lib/oss/build/"
+ cp -a * "${pkgdir}"
+ chmod -R a+r "${pkgdir}"
+ find "${pkgdir}" -type d -exec chmod a+x '{}' \;
install -D -m755 "$srcdir/oss.rc" "$pkgdir/etc/rc.d/oss"
-
+ install -D -m755 "$srcdir/ossxmix.desktop" "$pkgdir/usr/share/applications/ossxmix.desktop"
+ install -D -m644 "$srcdir/ossxmix.png" "$pkgdir/usr/share/pixmaps/ossxmix.png"
}
-
+md5sums=('b9a380a0ac8896390d71ac13676f27e1'
+ '65f07fe241bfbf912f76d8b6d8f276b5'
+ 'b70f139f73c2f1ee9db2680ce48121fb'
+ '1494a2304a1eb7a1979e7e83d894c67a'
+ 'f6a0fa9d274d21ab92cd03fca885add7'
+ '81e0f51ec04379dee64c31c32b045028')
+# vim: set ft=zsh: