aboutsummaryrefslogblamecommitdiffstats
path: root/community/snapcast/APKBUILD
blob: 23f0499a414c36ca493059a8b17a8243ee4bef0a (plain) (tree)
1
2
3
4
5
6
7
8
9
                                                     
                                                 
                
             
        



                                             
                                         
                                                                                     

                          
                                                                 
                                                          
                                                                                           

                                        



                             
         
                                   
 




                      





                                            




                                                          
          
                                 

                
                                     
 





                                                      


          
                                 

                
                                     
 





                                                      

 
                                                                                                                                                                    
                                                                                                                                                                  
                                                                                                                                                       
                                                                                                                                                       
                                                                                                                                                       
                                                                                                                                                        
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=snapcast
pkgver=0.15.0
pkgrel=4
pkgdesc="Synchronous multi-room audio player"
url="https://github.com/badaix/snapcast"
arch="all"
license="GPL-3.0"
depends="$pkgname-client $pkgname-server"
makedepends="asio-dev bash avahi-dev flac-dev libvorbis-dev alsa-lib-dev aixlog popl"
pkgusers="$pkgname"
pkggroups="$pkgname audio"
install="$pkgname-client.pre-install $pkgname-server.pre-install"
subpackages="$pkgname-doc $pkgname-client $pkgname-server"
source="$pkgname-$pkgver.tar.gz::https://github.com/badaix/$pkgname/archive/v$pkgver.tar.gz
	respect-optimization-level.patch

	$pkgname-client.initd
	$pkgname-client.confd
	$pkgname-server.initd
	$pkgname-server.confd
	"
builddir="$srcdir/$pkgname-$pkgver"

build() {
	cd "$builddir"
	make
}

check() {
	cd "$builddir"
	client/snapclient --help > /dev/null
	server/snapserver --help > /dev/null
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" installclient installserver
}

client() {
	pkgdesc="$pkgname client"
	depends=

	mkdir -p "$subpkgdir"/usr/bin

	mv "$pkgdir"/usr/bin/snapclient \
		"$subpkgdir"/usr/bin/
	install -Dm755 "$srcdir"/"$subpkgname.initd" \
		"$subpkgdir"/etc/init.d/"$subpkgname"
	install -Dm644 "$srcdir"/"$subpkgname.confd" \
		"$subpkgdir"/etc/conf.d/"$subpkgname"
}

server() {
	pkgdesc="$pkgname server"
	depends=

	mkdir -p "$subpkgdir"/usr/bin

	mv "$pkgdir"/usr/bin/snapserver \
		"$subpkgdir"/usr/bin/
	install -Dm755 "$srcdir"/"$subpkgname.initd" \
		"$subpkgdir"/etc/init.d/"$subpkgname"
	install -Dm644 "$srcdir"/"$subpkgname.confd" \
		"$subpkgdir"/etc/conf.d/"$subpkgname"
}

sha512sums="3751eeaa9be4ffd5c7633b8770f36e87360ab83004f090a8350e377f60a79d9502b92b92c5c9c35f513705e6484d113de9942f0a896824d7c5f806ba0010e84e  snapcast-0.15.0.tar.gz
85792a3edf8de76228d8114992f6fdfba6321aeca29d1f773038e88b96e1d6cdf9b6e3993eb09da934c8f561977827cb57f4b435c99405e5a2b4645edd2b5bd2  respect-optimization-level.patch
833ce6a5fecb023f32df340df98b5cfbecc765735d7133228dd703a6a0c7f2b67ac95aa787ac7119a2eb87e768e5c4deb12738d0b0354db3510d9047f9e9b24f  snapcast-client.initd
fa353d7974d3a8b3b22ff009b762c7c4ee318f9f83e22762a9ebf550484b9fc3cc4dffd389b6d756630dc035cb86d5c5643541957785f8bbf71fe4915691c337  snapcast-client.confd
ff610e08274d317e0df9590de47f3425d23a38528f82b9998de04d73cf2167ddb6aad237ddce9864b6c36fff959afb6a892c554ce40fd3e3d62c1308b022b2bb  snapcast-server.initd
48d494143d044a413b414b32cd8be51d4242234b6d7cb03102914a42b1ea6b1913c2c31b223c23c6be316918e731875149a2505daa03165659d0a1be3ca7e75c  snapcast-server.confd"