aboutsummaryrefslogtreecommitdiffstats
path: root/audio/audiere/Makefile
blob: c510f1b342ce38c8ddad7faceb8353a7d9ce5070 (plain) (blame)
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
# Created by: Dmitry Marakasov <amdmi3@FreeBSD.org>
# $FreeBSD$

PORTNAME=   audiere
PORTVERSION=    1.9.4
PORTREVISION=   6
CATEGORIES= audio
MASTER_SITES=   SF

MAINTAINER= amdmi3@FreeBSD.org
COMMENT=    High-level audio API

LICENSE=    LGPL21
LICENSE_FILE=   ${WRKSRC}/doc/license.txt

GNU_CONFIGURE=  yes
USES=       autoreconf gmake libtool
WANT_WX=    yes
USE_LDCONFIG=   yes

CONFIGURE_ENV=  PTHREAD_LIBS="-lpthread"
CPPFLAGS+=  -I${LOCALBASE}/include/speex -I${LOCALBASE}/include
LDFLAGS+=   -L${LOCALBASE}/lib

PORTDOCS=   changelog.txt cvs.txt dependencies.txt faq.txt glossary.txt \
        license.txt overview.txt readme.txt release-howto.txt \
        tutorial.txt

OPTIONS_DEFINE=     DUMB CDAUDIO VORBIS SPEEX DOCS
OPTIONS_DEFAULT=    DUMB CDAUDIO VORBIS SPEEX

DUMB_DESC=  DUMB support
CDAUDIO_DESC=   libcdaudio support

# since dumb is a static lib and it depends on ogg, we should
# link audiere with ogg as well
DUMB_IMPLIES=   VORBIS

DUMB_BUILD_DEPENDS= ${LOCALBASE}/lib/libdumb.a:audio/dumb
CDAUDIO_LIB_DEPENDS=    libcdaudio.so:audio/libcdaudio
VORBIS_LIB_DEPENDS= libvorbis.so:audio/libvorbis \
            libogg.so:audio/libogg
SPEEX_LIB_DEPENDS=  libspeex.so:audio/speex

post-patch:
# could be an option, but build is broken with recent FLAC
    @${REINPLACE_CMD} -e '/AC_CHECK_LIB/ s|FLAC|no_&|; \
        s|wx_config|no_&|' \
        ${WRKSRC}/configure.in

post-patch-DUMB-off:
    @${REINPLACE_CMD} -e '/AC_CHECK_LIB/ s|dumb|no_&|' \
        ${WRKSRC}/configure.in

post-patch-CDAUDIO-off:
    @${REINPLACE_CMD} -e '/AC_CHECK_LIB/ s|cdaudio|no_&|' \
        ${WRKSRC}/configure.in

post-patch-VORBIS-off:
    @${REINPLACE_CMD} -e '/AC_CHECK_HEADER/ s|vorbis|no_&|' \
        ${WRKSRC}/configure.in

post-patch-SPEEX-off:
    @${REINPLACE_CMD} -e '/AC_CHECK_HEADER/ s|speex|no_&|' \
        ${WRKSRC}/configure.in

post-install:
    @${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libaudiere.so

post-install-DOCS-on:
    @${MKDIR} ${STAGEDIR}${DOCSDIR}
.for f in ${PORTDOCS}
    ${INSTALL_DATA} ${WRKSRC}/doc/${f} ${STAGEDIR}${DOCSDIR}
.endfor

.include <bsd.port.mk>