Build problem on Raspberry Pi 2 (new FFT module)


#1

Building audio apps on a new Raspberry Pi 2 is giving problems.

I know how to "fix" it (replace all occurences of Complex and Factor types with jComplex/jFactor) - which implies a namespace/qualifier issue with the FFT module

I suspect that the names are clashing with Wolfram libraries (pre-installed AFAICT)

Jules suggested #undefing Complex & Factor at the start, but I haven't tried this yet

But has anyone else tried/noticed this?

 

Compiling juce_VST_Wrapper.cpp
../../../../modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp:276:29: warning: multi-character character constant [-Wmultichar]
In file included from ../../../../modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp:83:0:
/home/pi/SDKs/vstsdk2.4/public.sdk/source/vst2.x/audioeffectx.cpp: In member function ‘virtual void AudioEffectX::resume()’:
/home/pi/SDKs/vstsdk2.4/public.sdk/source/vst2.x/audioeffectx.cpp:307:69: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
In file included from ../../../../modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp:84:0:
/home/pi/SDKs/vstsdk2.4/public.sdk/source/vst2.x/audioeffect.cpp: In member function ‘virtual void AudioEffect::int2string(VstInt32, char*, VstInt32)’:
/home/pi/SDKs/vstsdk2.4/public.sdk/source/vst2.x/audioeffect.cpp:512:43: warning: narrowing conversion of ‘(((int)((char)digit)) + 48)’ from ‘int’ to ‘char’ inside { } [-Wnarrowing]
In file included from ../../../../modules/juce_audio_plugin_client/VST/../utility/../../juce_audio_basics/juce_audio_basics.h:40:0,
                 from ../../../../modules/juce_audio_plugin_client/VST/../utility/../juce_audio_plugin_client.h:29,
                 from ../../../../modules/juce_audio_plugin_client/VST/../utility/juce_IncludeModuleHeaders.h:25,
                 from ../../../../modules/juce_audio_plugin_client/VST/juce_VST_Wrapper.cpp:108:
../../../../modules/juce_audio_plugin_client/VST/../utility/../../juce_audio_basics/effects/juce_FFT.h: At global scope:
../../../../modules/juce_audio_plugin_client/VST/../utility/../../juce_audio_basics/effects/juce_FFT.h:49:12: error: expected identifier before numeric constant
../../../../modules/juce_audio_plugin_client/VST/../utility/../../juce_audio_basics/effects/juce_FFT.h:49:12: error: expected unqualified-id before numeric constant
../../../../modules/juce_audio_plugin_client/VST/../utility/../../juce_audio_basics/effects/juce_FFT.h:60:19: error: ISO C++ forbids declaration of ‘parameter’ with no type [-fpermissive]
../../../../modules/juce_audio_plugin_client/VST/../utility/../../juce_audio_basics/effects/juce_FFT.h:60:25: error: expected ‘,’ or ‘...’ before numeric constant
Makefile:159: recipe for target 'build/intermediate/Release/juce_VST_Wrapper_8aa348b1.o' failed
make: *** [build/intermediate/Release/juce_VST_Wrapper_8aa348b1.o] Error 1

#2

OK, adding

#undef Complex

#undef Factor

to the start of juce_FFT.h & juce_FFT.cpp seems to have done the trick.

Cheers, Jules


#3

So which crazy library is responsible for that?? Goddamn C programmers! I'll add some undefs to the headers, thanks for the heads-up.


#4

I'm a bit rubbish at Linux/GCC - How could I find out? Is there a sneaky compiler option which generates fully qualified post-pre-processed symbols? (I'll probably google this later)  

 


#5

grep for "define Complex"? Doesn't really matter anyway. I've modified it now to undef those symbols.