I want to use the VAD webrtc module compiling on Cygwin. Cygwin has several packages for this: packages
I installed the selected packages and want to figure out how to compile them. I have included what I have tried so far. Am I right about this? Or should I continue in a different way? I am a fan when it comes to c code.
main.cpp
int main() {
AudioProcessing* apm;
}
compilation
$ g++ main.cpp
main.cpp: In function ‘int main()’:
main.cpp:3:2: error: ‘AudioProcessing’ was not declared in this scope
AudioProcessing* apm;
^
main.cpp:3:19: error: ‘apm’ was not declared in this scope
AudioProcessing* apm;
Therefore, I need to include some headers and link the DLL to provide the implementation that I am assuming.
$ ls /usr/include/webrtc_audio_processing/webrtc/
base/ common_types.h system_wrappers/
common.h modules/ typedefs.h
$ find / -name "*rtc*dll"
/bin/cygsmartcols-1.dll
/bin/cygwebrtc_audio_processing-1.dll
/usr/bin/cygsmartcols-1.dll
/usr/bin/cygwebrtc_audio_processing-1.dll
I found a header containing the AudioProcessing class in audio_processing.h
main.cpp
#include "audio_processing.h"
int main() {
AudioProcessing* apm;
}
compilation
$ g++ main.cpp -o main -L/bin/ -lcygwebrtc_audio_processing-1 -I/usr/include/webrtc_audio_processing/webrtc/modules/audio_processing/include/
In file included from main.cpp:1:0:
/usr/include/webrtc_audio_processing/webrtc/modules/audio_processing/include/audio_processing.h:22:35: fatal error: webrtc/base/arraysize.h: No such file or directory
compilation terminated.
Sorry if this seems obvious, we all have to start something.
Discussion Results:
libwertc-audio-processing-devel Cygwin.
$ cat main.cpp
#include "webrtc/modules/audio_processing/include/audio_processing.h"
int main() {
webrtc::AudioProcessing* apm;
}
$ g++ main.cpp -o main -I/usr/include/webrtc_audio_processing/ -DWEBRTC_WIN -std=gnu++11 -L/bin/ -lcygwebrtc_audio_processing-1