Ticket #19158: Portfile

File Portfile, 1.7 KB (added by lperry (Perry Lee), 15 years ago)
Line 
1# $Id: Portfile 48101 2009-03-14 09:40:17Z perry@macports.org $
2
3PortSystem          1.0
4
5name                libsndfile
6version             1.0.19
7revision            2
8categories          audio
9maintainers         perry
10platforms           darwin
11
12description         libsndfile is a C library for reading and writing files \
13                    containing sampled sound (such as MS Windows WAV and the \
14                    Apple/SGI AIFF format) through one standard library interface.
15long_description    ${description}
16homepage            http://www.mega-nerd.com/libsndfile/
17
18depends_build       port:pkgconfig
19depends_lib         port:flac port:libogg port:libvorbis
20
21master_sites        ${homepage}
22
23checksums           rmd160 027d53e55b6d01c78aba31ed239fd2f0d2f752b5
24
25configure.args \
26    --disable-alsa --disable-octave --disable-sqlite --enable-external-libs
27
28post-configure {
29    system "ed - ${worksrcpath}/src/config.h < ${filespath}/src__config.h.ed"
30}
31
32if {[variant_isset no_external_libs] && ![variant_isset sqlite]} {
33    depends_build-delete port:pkgconfig
34}
35
36variant no_external_libs description {Disable support for FLAC, Ogg and Vorbis} {
37    depends_lib-delete port:flac port:libogg port:libvorbis
38
39    configure.args-append --disable-external-libs
40    configure.args-delete --enable-external-libs
41}
42
43variant octave description {Build support for GNU Octave} {
44    depends_build-append port:gsed
45    depends_lib-append   port:octave
46
47    configure.args-append --enable-octave
48    configure.args-delete --disable-octave
49}
50
51variant sqlite description {Enable support for SQLite} {
52    depends_lib-append port:sqlite3
53
54    configure.args-append --enable-sqlite
55    configure.args-delete --disable-sqlite
56}