# SimpleFFTExample build errors with JUCE 5.1.1

**URL:** <https://forum.juce.com/t/simplefftexample-build-errors-with-juce-5-1-1/23982>\
**Category:** General JUCE discussion\
**Created:** [August 30, 2017, 10:13pm UTC](https://forum.juce.com/t/simplefftexample-build-errors-with-juce-5-1-1/23982 "2017-08-30T22:13:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![JuJu1203](https://avatars.discourse-cdn.com/v4/letter/j/ac91a4/32.png) [@JuJu1203](https://forum.juce.com/u/JuJu1203)\
**Post date:** [August 30, 2017, 10:13pm UTC](https://forum.juce.com/t/simplefftexample-build-errors-with-juce-5-1-1/23982/1 "2017-08-30T22:13:33Z")

</div>

Hi all,

I’m fairly new to JUCE and am trying to build the ‘out-of-the-box’ SimpleFFTExample with JUCE 5.1.1 under Xcode and am getting several compile errors of the type:

/JUCE/examples/SimpleFFTExample/Source/SpectrogramComponent.h:40:9: Cannot initialize object parameter of type ‘juce::Timer’ with an expression of type ‘SpectrogramComponent’

Any ideas here? I imagine i am doing something dumb or perhaps the SimpleFFTExample is broken under JUCE 5.1.1? It builds without error under JUCE 5.0.2.

thanks in advance!

---

<div class="post-metadata">

**Author:** ![holy-city](https://avatars.discourse-cdn.com/v4/letter/h/8491ac/32.png) [@holy-city](https://forum.juce.com/u/holy-city)\
**Post date:** [August 30, 2017, 10:36pm UTC](https://forum.juce.com/t/simplefftexample-build-errors-with-juce-5-1-1/23982/2 "2017-08-30T22:36:58Z")

</div>

See this thread

> [@SimpleFFTExample doesn't build](https://forum.juce.com/t/simplefftexample-doesnt-build/23581/2):
>
> Thanks! This is fixed on develop with commit [1b964e9](https://github.com/WeAreROLI/JUCE/commit/1b964e98c20098f627538a08ee3dcb59bfb29a0e).

---

<div class="post-metadata">

**Author:** ![JuJu1203](https://avatars.discourse-cdn.com/v4/letter/j/ac91a4/32.png) [@JuJu1203](https://forum.juce.com/u/JuJu1203)\
**Post date:** [August 30, 2017, 10:41pm UTC](https://forum.juce.com/t/simplefftexample-build-errors-with-juce-5-1-1/23982/3 "2017-08-30T22:41:36Z")

</div>

I just had a JUCE-fluent friend of mine figure this out for me. Here is his solution:

1. In the Juicer, under ‘Modules’, add the juce\_dsp module. In JUCE 5.1, the FFT class has been moved here from the juce\_audio\_basics module.
2. In Project Settings, change the C++ Language Standard to C++14.
3. In SpectrogramComponent.h, change the declaration: ‘FFT forwardFFT’ to 'juce::dsp::FFT forwardFFT.
4. In SpectrogramComponent.h, in the class constructor, change forwardFFT(fftOrder, false) to only use the first parameter.

That should do it…
