|
| 1 | +# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 |
| 2 | +# $Id: Portfile 102452 2013-02-03 15:01:23Z larryv@macports.org $ |
| 3 | + |
| 4 | +PortSystem 1.0 |
| 5 | + |
| 6 | +name libsndfile |
| 7 | +version 1.0.25 |
| 8 | +revision 1 |
| 9 | +categories audio |
| 10 | +maintainers stare.cz:hans |
| 11 | +platforms darwin |
| 12 | + |
| 13 | +description libsndfile is a C library for reading and writing files \ |
| 14 | + containing sampled sound (such as MS Windows WAV and the \ |
| 15 | + Apple/SGI AIFF format) through one standard library \ |
| 16 | + interface. |
| 17 | +long_description ${description} |
| 18 | +license LGPL-2.1+ |
| 19 | +homepage http://www.mega-nerd.com/libsndfile/ |
| 20 | + |
| 21 | +livecheck.regex {Updates for (\d+\.\d+\.\d+)} |
| 22 | +livecheck.type regex |
| 23 | +livecheck.url ${homepage}ChangeLog |
| 24 | + |
| 25 | +depends_build port:pkgconfig |
| 26 | +depends_lib port:flac port:libogg port:libvorbis |
| 27 | + |
| 28 | +master_sites ${homepage}files/ |
| 29 | + |
| 30 | +checksums rmd160 7330ea9fc1cfa3809fa7d2a6e2a0593b6e0233c7 \ |
| 31 | + sha256 59016dbd326abe7e2366ded5c344c853829bebfd1702ef26a07ef662d6aa4882 |
| 32 | + |
| 33 | +patchfiles fix-include.patch configure.patch |
| 34 | + |
| 35 | +configure.args \ |
| 36 | + --disable-alsa \ |
| 37 | + --disable-octave \ |
| 38 | + --disable-silent-rules \ |
| 39 | + --disable-sqlite \ |
| 40 | + --enable-external-libs |
| 41 | + |
| 42 | +post-configure { |
| 43 | + system "ed - ${worksrcpath}/src/config.h < ${filespath}/src__config.h.ed" |
| 44 | +} |
| 45 | + |
| 46 | +if {[variant_isset no_external_libs] && ![variant_isset sqlite]} { |
| 47 | + depends_build-delete port:pkgconfig |
| 48 | +} |
| 49 | + |
| 50 | +variant no_external_libs description {Disable support for FLAC, Ogg and Vorbis} { |
| 51 | + depends_lib-delete port:flac port:libogg port:libvorbis |
| 52 | + |
| 53 | + configure.args-append --disable-external-libs |
| 54 | + configure.args-delete --enable-external-libs |
| 55 | +} |
| 56 | + |
| 57 | +variant octave description {Enable support for Octave} { |
| 58 | + depends_build-append port:gsed |
| 59 | + depends_lib-append path:bin/octave:octave |
| 60 | + |
| 61 | + configure.args-append --enable-octave |
| 62 | + configure.args-delete --disable-octave |
| 63 | +} |
| 64 | + |
| 65 | +variant sqlite description {Enable support for SQLite} { |
| 66 | + depends_lib-append port:sqlite3 |
| 67 | + |
| 68 | + configure.args-append --enable-sqlite |
| 69 | + configure.args-delete --disable-sqlite |
| 70 | +} |
| 71 | + |
| 72 | +variant egallager description {Use my personal fork} { |
| 73 | + PortGroup github 1.0 |
| 74 | + github.setup cooljeanius libsndfile 0.1.1 v |
| 75 | + maintainers-append gwmail.gwu.edu:egall |
| 76 | + fetch.type git |
| 77 | + git.url git://github.com/cooljeanius/libsndfile.git |
| 78 | + |
| 79 | + # Couldn't get these patches to apply correctly against my fork. |
| 80 | + patchfiles-delete fix-include.patch configure.patch |
| 81 | + |
| 82 | + depends_build-append port:autogen \ |
| 83 | + port:autoconf \ |
| 84 | + port:automake \ |
| 85 | + port:libtool \ |
| 86 | + path:bin/python:swig-python \ |
| 87 | + path:bin/ranlib:cctools \ |
| 88 | + path:bin/awk:gawk \ |
| 89 | + path:bin/make:gmake \ |
| 90 | + path:bin/install:coreutils \ |
| 91 | + port:endian |
| 92 | + |
| 93 | + pre-configure { |
| 94 | + system -W ${worksrcpath} "sh ./autogen.sh" |
| 95 | + } |
| 96 | + |
| 97 | + configure.args-delete --enable-silent-rules |
| 98 | +} |
| 99 | + |
| 100 | +variant experimental conflicts no_external_libs description {Enable experimental code} { |
| 101 | + depends_lib-append path:bin/speexenc:speex |
| 102 | + configure.args-append --enable-experimental |
| 103 | +} |
0 commit comments