# $Id: Portfile 109342 2013-08-13 17:48:30Z jmr@macports.org $

PortSystem      1.0

name            libsdl2_mixer
set my_name     SDL2_mixer
version         2.0.0
categories      audio devel
platforms       darwin
license         zlib
maintainers     jmr openmaintainer
description     Audio mixer library for SDL

long_description \
    A sample multi-channel audio mixer library. It supports any number of \
    simultaneously playing channels of 16 bit stereo audio, plus a single \
    channel of music.

homepage        http://www.libsdl.org/projects/SDL_mixer/
master_sites    ${homepage}release/
distname        ${my_name}-${version}

checksums       rmd160 a49884a68351f77fefe76c2fcf8ee317e6d971e2 \
                sha256 a8ce0e161793791adeff258ca6214267fdd41b3c073d2581cd5265c8646f725b

depends_build   port:pkgconfig
depends_lib     port:libsdl2 \
                port:smpeg2 \
                port:flac \
                port:libvorbis \
                port:libmikmod

configure.args  --disable-sdltest \
                --disable-smpegtest \
                --disable-music-mod-modplug \
                --disable-music-midi-fluidsynth \
                --enable-music-mod-mikmod \
                --disable-music-mod-mikmod-shared \
                --disable-music-ogg-shared \
                --disable-music-flac-shared \
                --disable-music-mp3-smpeg-shared

post-destroot {
    set docdir ${prefix}/share/doc/${name}
    xinstall -d ${destroot}${docdir}
    xinstall -m 0644 -W ${worksrcpath} CHANGES.txt COPYING.txt README.txt \
        ${destroot}${docdir}
}

livecheck.type  regex
livecheck.url   ${homepage}
livecheck.regex ${my_name}-(\\d+(?:\\.\\d+)*)
