summaryrefslogtreecommitdiff
path: root/multimedia/librespot/Makefile
blob: d201f2390f6bc0dc1cac1bc19f5fda526f5300ec (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
# $FreeBSD$

PORTNAME=	librespot
PORTVERSION=	0.1.3
DISTVERSIONPREFIX=	v
PORTREVISION=	1
CATEGORIES=	multimedia

MAINTAINER=	ehaupt@FreeBSD.org
COMMENT=	Open Source Spotify client library

LICENSE=	MIT
LICENSE_FILE=	${WRKSRC}/LICENSE

USES=		cargo

USE_GITHUB=	yes
GH_ACCOUNT=	librespot-org

CARGO_FEATURES=	--no-default-features

PLIST_FILES=	bin/librespot

OPTIONS_DEFINE=		TREMOR VORBIS
OPTIONS_DEFAULT=	PORTAUDIO TREMOR VORBIS
OPTIONS_MULTI=		BACKEND
OPTIONS_MULTI_BACKEND=	ALSA GSTREAMER JACK PORTAUDIO PULSEAUDIO SDL
ALSA_DESC=		Rodio audio backend using ALSA

ALSA_LIB_DEPENDS=	libasound.so:audio/alsa-lib
ALSA_VARS=		CARGO_FEATURES+=rodio-backend
GSTREAMER_USE=		GNOME=glib20 \
			GSTREAMER1=yes
GSTREAMER_VARS=		CARGO_FEATURES+=gstreamer-backend
JACK_LIB_DEPENDS=	libjack.so:audio/jack
JACK_VARS=		CARGO_FEATURES+=jackaudio-backend
PORTAUDIO_LIB_DEPENDS=	libportaudio.so:audio/portaudio
PORTAUDIO_VARS=		CARGO_FEATURES+=portaudio-backend
PULSEAUDIO_LIB_DEPENDS=	libpulse-simple.so:audio/pulseaudio
PULSEAUDIO_VARS=	CARGO_FEATURES+=pulseaudio-backend
SDL_USE=		SDL=sdl2
SDL_VARS=		CARGO_FEATURES+=sdl-backend
TREMOR_LIB_DEPENDS=	libvorbisidec.so:audio/libtremor
TREMOR_VARS=		CARGO_FEATURES+=with-tremor
VORBIS_LIB_DEPENDS=	libvorbisfile.so:audio/libvorbis
VORBIS_VARS=		CARGO_FEATURES+=with-vorbis

.include "Makefile.crates"

post-install:
	@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/librespot

.include <bsd.port.mk>