This file is indexed.

/usr/share/doc/portaudio19-doc/doc/html/compile_mac_coreaudio.html is in portaudio19-doc 19.6.0-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.12"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>PortAudio: Building Portaudio for Mac OS X</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">PortAudio
   &#160;<span id="projectnumber">2.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.12 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',false,false,'search.php','Search');
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">Building Portaudio for Mac OS X </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><h1><a class="anchor" id="comp_mac_ca_1"></a>
Requirements</h1>
<p>OS X 10.4 or later. PortAudio v19 currently only compiles and runs on OS X version 10.4 or later. Because of its heavy reliance on memory barriers, it's not clear how easy it would be to back-port PortAudio to OS X version 10.3. Leopard support requires the 2007 snapshot or later.</p>
<p>Apple's Xcode and its related tools installed in the default location. There is no Xcode project for PortAudio.</p>
<p>Mac 10.4 SDK. Look for "/Developer/SDKs/MacOSX10.4u.sdk" folder on your system. It may be installed with XCode. If not then you can download it from Apple Developer Connection. <a href="http://connect.apple.com/">http://connect.apple.com/</a></p>
<h1><a class="anchor" id="comp_mac_ca_2"></a>
Building</h1>
<p>To build PortAudio, simply use the Unix-style "./configure &amp;&amp; make":</p>
<div class="fragment"><div class="line">./configure &amp;&amp; make</div></div><!-- fragment --><p>You do <b>not</b> need to do "make install", and we don't recommend it; however, you may be using software that instructs you to do so, in which case you should follow those instructions. (Note from Phil: I had to do "sudo make install" after the command above, otherwise XCode complained that it could not find "/usr/local/lib/libportaudio.dylib" when I compiled an example.)</p>
<p>The result of these steps will be a file named "libportaudio.dylib" in the directory "usr/local/lib/".</p>
<p>By default, this will create universal binaries and therefore requires the Universal SDK from Apple, included with XCode 2.1 and higher.</p>
<h1><a class="anchor" id="comp_mac_ca_3"></a>
Other Build Options</h1>
<p>There are a variety of other options for building PortAudio. The default described above is recommended as it is the most supported and tested; however, your needs may differ and require other options, which are described below.</p>
<h2><a class="anchor" id=""></a>
</h2>
<p>By default, PortAudio is built as a universal binary. This includes 64-bit versions if you are compiling on 10.5, Leopard. If you want a "thin", or single architecture library, you have two options:</p>
<p>build a non-universal library using configure options. use lipo(1) on whatever part of the library you plan to use.</p>
<p>Note that the first option may require an extremely recent version of PortAudio (February 5th '08 at least).</p>
<h2><a class="anchor" id=""></a>
</h2>
<p>To build a non-universal library for the host architecture, simply use the <em>&ndash;disable-mac-universal</em> option with configure.</p>
<div class="fragment"><div class="line">./configure --disable-mac-universal &amp;&amp; make</div></div><!-- fragment --><p>The <em>&ndash;disable-mac-universal</em> option may also be used in conjunction with environment variables to give you more control over the universal binary build process. For example, to build a universal binary for the i386 and ppc architectures using the 10.4u sdk (which is the default on 10.4, but not 10.5), you might specify this configure command line:</p>
<div class="fragment"><div class="line">CFLAGS=<span class="stringliteral">&quot;-O2 -g -Wall -arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.3&quot;</span> \</div><div class="line">  LDFLAGS=<span class="stringliteral">&quot;-arch i386 -arch ppc -isysroot /Developer/SDKs/MacOSX10.4u.sdk -mmacosx-version-min=10.3&quot;</span> \</div><div class="line">  ./configure --disable-mac-universal --disable-dependency-tracking</div></div><!-- fragment --><p>For more info, see Apple's documentation on the matter:</p>
<p><a href="http://developer.apple.com/technotes/tn2005/tn2137.html">http://developer.apple.com/technotes/tn2005/tn2137.html</a> <a href="http://developer.apple.com/documentation/Porting/Conceptual/PortingUnix/intro/chapter_1_section_1.html">http://developer.apple.com/documentation/Porting/Conceptual/PortingUnix/intro/chapter_1_section_1.html</a></p>
<h2><a class="anchor" id=""></a>
</h2>
<p>The second option is to build normally, and use lipo (1) to extract the architectures you want. For example, if you want a "thin", i386 library only:</p>
<div class="fragment"><div class="line">lipo lib/.libs/libportaudio.a -thin i386 -output libportaudio.a</div></div><!-- fragment --><p>or if you want to extract a single architecture fat file:</p>
<div class="fragment"><div class="line">lipo lib/.libs/libportaudio.a -extract i386 -output libportaudio.a</div></div><!-- fragment --><h2><a class="anchor" id=""></a>
</h2>
<p>By default, PortAudio on the mac is built without any debugging options. This is because asserts are generally inappropriate for a production environment and debugging information has been suspected, though not proven, to cause trouble with some interfaces. If you would like to compile with debugging, you must run configure with the appropriate flags. For example:</p>
<div class="fragment"><div class="line">./configure --enable-mac-debug &amp;&amp; make</div></div><!-- fragment --><p>This will enable -g and disable -DNDEBUG which will effectively enable asserts.</p>
<h1><a class="anchor" id="comp_mac_ca_4"></a>
Using the Library in XCode Projects</h1>
<p>If you are planning to follow the rest of the tutorial, several project types will work. You can create a "Standard Tool" under "Command Line Utility". If you are not following the rest of the tutorial, any type of project should work with PortAudio, but these instructions may not work perfectly.</p>
<p>Once you've compiled PortAudio, the easiest and recommended way to use PortAudio in your XCode project is to add "&lt;portaudio&gt;/include/portaudio.h" and "&lt;portaudio&gt;/lib/.libs/libportaudio.a" to your project. Because "&lt;portaudio&gt;/lib/.libs/" is a hidden directory, you won't be able to navigate to it using the finder or the standard Mac OS file dialogs by clicking on files and folders. You can use command-shift-G in the finder to specify the exact path, or, from the shell, if you are in the portaudio directory, you can enter this command:</p>
<div class="fragment"><div class="line">open lib/.libs</div></div><!-- fragment --><p>Then drag the "libportaudio.a" file into your XCode project and place it in the "External Frameworks and Libraries" group, if the project type has it. If not you can simply add it to the top level folder of the project.</p>
<p>You will need to add the following frameworks to your XCode project:</p>
<ul>
<li>CoreAudio.framework</li>
<li>AudioToolbox.framework</li>
<li>AudioUnit.framework</li>
<li>CoreServices.framework</li>
<li>Carbon.framework</li>
</ul>
<h1><a class="anchor" id="comp_mac_ca_5"></a>
Using the Library in Other Projects</h1>
<p>For gcc/Make style projects, include "include/portaudio.h" and link "libportaudio.a", and use the frameworks listed in the previous section. How you do so depends on your build.</p>
<h1><a class="anchor" id="comp_mac_ca_6"></a>
Using Mac-only Extensions to PortAudio</h1>
<p>For additional, Mac-only extensions to the PortAudio interface, you may also want to grab "include/pa_mac_core.h". This file contains some special, mac-only features relating to sample-rate conversion, channel mapping, performance and device hogging. See "src/hostapi/coreaudio/notes.txt" for more details on these features.</p>
<h1><a class="anchor" id="comp_mac_ca_7"></a>
What Happened to Makefile.darwin?</h1>
<p>Note, there used to be a special makefile just for darwin. This is no longer supported because you can build universal binaries from the standard configure routine. If you find this file in your directory structure it means you have an outdated version of PortAudio.</p>
<div class="fragment"><div class="line">make -f Makefile.darwin</div></div><!-- fragment --><p>Back to the Tutorial: <a class="el" href="tutorial_start.html">PortAudio Tutorials</a> </p>
</div></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.12
</small></address>
</body>
</html>