2

I am following this blog to set up JNI with android ndk on my box which runs ubuntu 11.10... In this program I am integrating speex with my existing application which streams the audio. So far everything was working fine but things destroyed as I integrated speex_echo_cancelation... Now I get following error... any help ?

jni/./libspeex/mdf.c:78:21: error: windows.h: No such file or directory
jni/./libspeex/mdf.c: In function 'speex_echo_cancellation':
jni/./libspeex/mdf.c:1195: error: invalid operands to binary + (have 'float' and 'spx_float_t')
jni/./libspeex/mdf.c:1216: error: invalid operands to binary + (have 'float' and 'spx_float_t')
make: *** [obj/local/armeabi/objs/speex/./libspeex/mdf.o] Error 1
Amit
  • 13,134
  • 17
  • 77
  • 148
  • Hello, your link is dead. is this at least similar to the original blog post? [http://www.badlogicgames.com/wordpress/?p=1726](http://www.badlogicgames.com/wordpress/?p=1726) Here is a more code-comprehensive question for a similar problem: [http://stackoverflow.com/questions/9092415/speex-support-in-android](http://stackoverflow.com/questions/9092415/speex-support-in-android) – ocramot Jun 29 '16 at 08:22

1 Answers1

5

Well, it's not finding windows.h because you're not on a Windows system. It shouldn't be looking for windows.h because you're not targeting a Windows system. Are you sure that you have downloaded the right package and that all of your environment variables set correctly?

CaseyB
  • 24,780
  • 14
  • 77
  • 112
  • +1 thanks that really helped, act I was using a previous version of speex which was being used on windows machines....I replaced that with newer version and it compiled successfully.. Is their any way I can port that old code to android environment ? I have some old code which I don't want to change.. – Amit Mar 17 '12 at 08:05
  • If they have kept their API the same then you should be able to port it without much trouble. If not then no. – CaseyB Mar 19 '12 at 14:15