Projucer generated plugin will not build with latest develop


#1

I just did a git pull on the develop branch, rebuilt the Projucer, generated a new Audio Plugin project and on building get the following errors:

Compiling PluginProcessor.cpp
Compiling PluginEditor.cpp
Compiling juce_audio_formats.cpp
Compiling juce_audio_plugin_client_utils.cpp
In file included from ../../Source/PluginProcessor.cpp:11:0:
../../Source/PluginProcessor.h:32:10: error: ‘bool TestPluginAudioProcessor::setPreferredBusArrangement(bool, int, const juce::AudioChannelSet&)’ marked ‘override’, but does not override
     bool setPreferredBusArrangement (bool isInput, int bus, const AudioChannelSet& preferredSet) override;
          ^
../../Source/PluginProcessor.cpp: In member function ‘bool TestPluginAudioProcessor::setPreferredBusArrangement(bool, int, const juce::AudioChannelSet&)’:
../../Source/PluginProcessor.cpp:107:11: error: ‘setPreferredBusArrangement’ is not a member of ‘juce::AudioProcessor’
     if (! AudioProcessor::setPreferredBusArrangement (! isInput, bus, preferredSet))
           ^
../../Source/PluginProcessor.cpp:111:12: error: ‘setPreferredBusArrangement’ is not a member of ‘juce::AudioProcessor’
     return AudioProcessor::setPreferredBusArrangement (isInput, bus, preferredSet);
            ^
In file included from ../../Source/PluginEditor.cpp:11:0:
../../Source/PluginProcessor.h:32:10: error: ‘bool TestPluginAudioProcessor::setPreferredBusArrangement(bool, int, const juce::AudioChannelSet&)’ marked ‘override’, but does not override
     bool setPreferredBusArrangement (bool isInput, int bus, const AudioChannelS
          ^
Compiling juce_audio_plugin_client_VST2.cpp
Makefile:100: recipe for target 'build/intermediate/Debug/PluginProcessor_a059e380.o' failed
make: *** [build/intermediate/Debug/PluginProcessor_a059e380.o] Error 1
make: *** Waiting for unfinished jobs....
Makefile:105: recipe for target 'build/intermediate/Debug/PluginEditor_94d4fb09.o' failed
make: *** [build/intermediate/Debug/PluginEditor_94d4fb09.o] Error 1
rory@rory-linux-pc:~/sourcecode/TestPlugin/Builds/LinuxMakefile$

#2

This is embarrassing. I just tried this again from my work PC and it works fine. Looks like my home PC has different versions of JUCE lying aroundstill). This is the second time in a few weeks I’ve cried wolf on this list. I better be careful I don’t get eaten. :neutral_face:


#3

I run into this problem myself every now and then. So often, I still have an old JUCE folder lying around in my Downloads folder somewhere which I forget about. It’s quite annoying that it seems completely random (at least on mac) which Projucer it will open when double-clicking a .jucer file. It would be good, for example, if os x would always prioritise the apps in the /Applications folder.


#4

Glad to hear I’m not the only person who gets bitten by this on occasion. I’ve started to rely more and more on the Projucer for project management. it’s already saving me quite a lot of work. And I really like that I don’t need to include any xcode/VS projects in my repos.


#5

I keep getting this error? Any ideas what it might be.

My project compiles on Both OSX and Windown, but on Linux it just keeps popping out this error?


#6

Are you generating the linux makefiles locally on your Linux machine? Perhaps try to generate them from your OSX or WIndow partitions and then try. Otherwise, try removing the JUCE repo from your Linux machine and re-cloning. Hopefully that should do the trick.


#7

That error will happen if there is a mix-up of Projucer binaries and the sources (i.e. the Projucer binary is from master and the JUCE source code is on develop). When switching branches you must rebuild the Projucer.


#8

I’m getting bit by this setPreferredBusArrangement error. It must have something to do with the move to 4.3.0 today.

I don’t have more than one JUCE folder and it’s definitely at 4.3.0 from the master branch. I rebuilt Projucer and it’s at 4.3.0. I then started up Projucer and saved my project…opened it in Xcode and cleaned it and tried to compile it…and still the same error.

Suggestions?


#9

I tried commenting out my overriding setPreferredBusArrangement in my AudioProcessor and rebuilt, seems to work fine.

Except…now my plugin shows up in PluginHost with 2 audio inputs and 2 audio outputs, but in Projucer I’ve specified {0, 2}. Don’t understand that.

Also, it seems that setPreferredBusArrangement is a virtual function in the AudioProcessor docs, but it doesn’t seem to be in the AudioProcessor.h at all.


#10

I noticed that too. In the end I generated a new plugin using the projucer and updated my plugin code accordingly. I’m not really sure what’s going on with the bus stuff. It seems to be in a state of flux, or perhaps we are just a bit slow in staying up to date with all the changes.


#11

In my previous post I mentioned that everything was now fine once I removed the setPreferredBusArrangement, but I was wrong. It just compiled, but now my plugin is failing in PluginHost with a ValidFormat error. Something is fishy. I’m going to try going back to 4.2.4 and see what happens.


#12

If possible, then please feel free to pm me a stripped down version of your plug-in and I can take a look.