1 /*! \page compiling Debugging & Compiling
3 \section debug Debugging
5 If you are having problems getting RtAudio to run on your system, make sure to pass a value of \e true to the RtAudio::showWarnings() function (this is the default setting). A variety of warning messages will be displayed which may help in determining the problem. Also, try using the programs included in the <tt>tests</tt> directory. The program <tt>audioprobe</tt> displays the queried capabilities of all hardware devices found for all APIs compiled. When using the ALSA and JACK APIs, further information can be displayed by defining the preprocessor definition __RTAUDIO_DEBUG__.
7 \section compile Compiling
9 In order to compile RtAudio for a specific OS and audio API, it is necessary to supply the appropriate preprocessor definition and library within the compiler statement:
12 <TABLE BORDER=2 COLS=5 WIDTH="100%">
14 <TD WIDTH="5%"><B>OS:</B></TD>
15 <TD WIDTH="5%"><B>Audio API:</B></TD>
16 <TD WIDTH="5%"><B>C++ Class:</B></TD>
17 <TD WIDTH="5%"><B>Preprocessor Definition:</B></TD>
18 <TD WIDTH="5%"><B>Library or Framework:</B></TD>
19 <TD><B>Example Compiler Statement:</B></TD>
25 <TD>__LINUX_ALSA__</TD>
26 <TD><TT>asound, pthread</TT></TD>
27 <TD><TT>g++ -Wall -D__LINUX_ALSA__ -o audioprobe audioprobe.cpp RtAudio.cpp -lasound -lpthread</TT></TD>
33 <TD>__LINUX_PULSE__</TD>
34 <TD><TT>pthread</TT></TD>
35 <TD><TT>g++ -Wall -D__LINUX_PULSE__ -o audioprobe audioprobe.cpp RtAudio.cpp -lpthread -lpulse-simple -lpulse</TT></TD>
41 <TD>__LINUX_OSS__</TD>
42 <TD><TT>pthread</TT></TD>
43 <TD><TT>g++ -Wall -D__LINUX_OSS__ -o audioprobe audioprobe.cpp RtAudio.cpp -lpthread</TT></TD>
46 <TD>Linux or Macintosh OS-X</TD>
47 <TD>Jack Audio Server</TD>
49 <TD>__UNIX_JACK__</TD>
50 <TD><TT>jack, pthread</TT></TD>
51 <TD><TT>g++ -Wall -D__UNIX_JACK__ -o audioprobe audioprobe.cpp RtAudio.cpp `pkg-config --cflags --libs jack` -lpthread</TT></TD>
55 <TD>Macintosh OS-X</TD>
58 <TD>__MACOSX_CORE__</TD>
59 <TD><TT>pthread, CoreAudio</TT></TD>
60 <TD><TT>g++ -Wall -D__MACOSX_CORE__ -o audioprobe audioprobe.cpp RtAudio.cpp -framework CoreAudio -lpthread</TT></TD>
66 <TD>__WINDOWS_DS__</TD>
67 <TD><TT>dsound.lib (ver. 5.0 or higher), multithreaded</TT></TD>
68 <TD><I>compiler specific</I></TD>
74 <TD>__WINDOWS_ASIO__</TD>
75 <TD><I>various ASIO header and source files</I></TD>
76 <TD><I>compiler specific</I></TD>
81 The example compiler statements above could be used to compile the <TT>audioprobe.cpp</TT> example file, assuming that <TT>audioprobe.cpp</TT>, <TT>RtAudio.h</TT>, <tt>RtError.h</tt>, and <TT>RtAudio.cpp</TT> all exist in the same directory.