On Wed, 2 Apr 2014 09:19:38 +0000, Krause, Mathias wrote > Hi Thiago, > > > Do you know if there is some rule to compiling using librtaudio? > > Because, there is an error..and i don't know what's wrong. I'm using g++ 4.7.2 and i'm compiling using: > > > > $ g++<programname.cpp> -o <programname> > > > > The error is: undefined reference to 'RtAudio::RtAudio(RtAudio::Api)' > > i'm including the lib in the program, normally! > > you need to add the library to the linker with the -l option.
And on most distros you might want to use rtaudio-config to find out the appropriate linker and compiler flags: LIBS=`rtaudio-config --libs` CFLAGS=`rtaudio-config --cxxflags` etc. And then use these in your compiler invocation/makefile. BTW, hint to the portaudio developers: there's a rather standard tool for such tasks called pkg-config. It might be a good idea to supply a portaudio.pc file instead of/together with the rtaudio-config program. Cheers Ralf Mattes > Regards, > Mathias > > _______________________________________________ > Linux-audio-dev mailing list > [email protected] > http://lists.linuxaudio.org/listinfo/linux-audio-dev -- R. Mattes - Hochschule fuer Musik Freiburg [email protected] _______________________________________________ Linux-audio-dev mailing list [email protected] http://lists.linuxaudio.org/listinfo/linux-audio-dev
