Ticket #12802: Portfile

File Portfile, 2.9 KB (added by themiwi@…, 17 years ago)
Line 
1# $Id$
2# -*- Mode: Tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
3PortSystem       1.0
4name             PortAudio
5version          19.061121
6revision         0
7categories       audio devel
8maintainers      themiwi@users.sourceforge.net
9description      PortAudio is a free, cross platform, open-source, audio I/O library.
10long_description PortAudio is a free, cross platform, open-source, audio I/O library. \
11                 It lets you write simple audio programs in 'C' that will compile and \
12                 run on many platforms including Windows, Macintosh (8,9,X), Unix (OSS), \
13                 SGI, and BeOS. PortAudio is intended to promote the exchange of audio \
14                 synthesis software between developers on different platforms. \
15                 PortAudio provides a very simple API for recording and/or playing sound \
16                 using a simple callback function.  Example programs are included that \
17                 synthesize sine waves and pink noise, perform fuzz distortion on a guitar, \
18                 list available audio devices, etc.
19master_sites     http://www.portaudio.com/archives
20distname         pa_stable_v19_061121
21checksums        md5 f2ceca92b3bfc206abccfb439c169a3c \
22                 sha1 798fc900251e2df423ba9e60b832ca76f85c3ad0 \
23                 rmd160 f7b6a83ad6b120b9c3b7736b86231e88d709ee7f
24
25use_configure    no
26worksrcdir       portaudio
27
28pre-build {
29  reinplace -E "s|/usr/local|${prefix}|g" ${worksrcpath}/Makefile.darwin
30}
31
32build.cmd        make -f Makefile.darwin -j3
33
34post-build {
35  copy ${worksrcpath}/portaudio-2.0.pc.in ${worksrcpath}/portaudio.pc
36  reinplace -E "s|\@prefix\@|${prefix}|g" ${worksrcpath}/portaudio.pc
37  reinplace -E "s|\@exec_prefix\@|${prefix}/bin|g" ${worksrcpath}/portaudio.pc
38  reinplace -E "s|\@libdir\@|${prefix}/lib|g" ${worksrcpath}/portaudio.pc
39  reinplace -E "s|\@includedir\@|${prefix}/include|g" ${worksrcpath}/portaudio.pc
40  reinplace -E "s|\@LIBS\@|-framework CoreAudio -framework AudioToolbox -framework AudioUnit -framework -framework CoreServices|g" ${worksrcpath}/portaudio.pc
41  reinplace -E "s|\@THREAD_CFLAGS\@||g" ${worksrcpath}/portaudio.pc
42}
43
44destroot {
45  xinstall -c -m 644 ${worksrcpath}/include/portaudio.h ${destroot}/${prefix}/include
46  xinstall -c -m 644 ${worksrcpath}/lib/libportaudio.a ${worksrcpath}/lib/libportaudio.0.0.19.dylib ${destroot}/${prefix}/lib
47  system "(cd ${destroot}/${prefix}/lib && ln -s libportaudio.0.0.19.dylib libportaudio.dylib)"
48  xinstall -c -${destroot}/${prefix}/lib/pkgconfig
49  xinstall -c -m 644 ${worksrcpath}/portaudio.pc ${destroot}/${prefix}/lib/pkgconfig
50  xinstall -c -${destroot}/${prefix}/share/doc/${name}
51  xinstall -c -m 644 ${worksrcpath}/README.txt  \
52                     ${worksrcpath}/COMPILING.DARWIN \
53                     ${worksrcpath}/LICENSE.txt \
54                     ${worksrcpath}/V19-devel-readme.txt \
55                     ${destroot}/${prefix}/share/doc/${name}
56}
57