Undefined symbols in JuceAudioPlugin Demo


I downloaded the current JuceAudioPlugin @ http://www.rawmaterialsoftware.com/juce/downloads/JuceAudioPlugin_1_15.zip. When I try to build using the Xcode project at JuceAudioPlugin/demo/build/AudioUnit/JuceDemoAU.xcodeproj I get a complaint of undefined symbols:

ld: Undefined symbols:
/Users/ThaneQ/Develop/JuceAudioPlugin/demo/build/AudioUnit/build/JuceDemoAU.build/Debug/JuceAU.build/Objects-normal/ppc/juce_AudioUnitWrapper-6180B671.o reference to undefined __Z45juce_setCurrentExecutableFileNameFromBundleIdRKN4juce6StringE

I am using the latest version of Xcode (2.4.1).

It appears to want the juce_setCurrentExecutableFileNameFromBundleId() function in juce/build/macosx/platform_specific_code/juce_mac_Files.cpp. But, when I add that file to that file to my JuceDemoAU Xcode project, it still doesn’t find the symbol.

Perhaps I’m missing something obvious… is it a namespace issue?

Any other ideas?

Thane Heninger


I think I realized the problem.

juce_AudioUnitWrapper.cpp contains a reference to juce_setCurrentExecutableFileNameFromBundleId() which is not inside a namespace. The function in juce_mac_Files.cpp puts it inside the namespace.

So, I changed the declaration to show:


extern void juce_setCurrentExecutableFileNameFromBundleId (const String& bundleId);


And it now seems to build correctly.



Ah, yes. That was a silly mistake, thanks for spotting it!