Juce 1.29 example project errors

I’m compiling Juce 1.29 on an intel iMac, and get two build errors
from Main.cpp: neither windowAppearsOnTaskbar nor windowHasDropShadow are defined.

What’s the correct way to fix this issue?

That’s not intel specific - I moved all the window style flags into the ComponentPeer class in the last build - just add ComponentPeer:: in front of the names and it’ll be fine.

Great! That took care of that problem.

Then there were a bunch of missing AGL symbols, so I added the AGL framework. Could this be added to the mac juce_application project by default?

Now juce::component::createNewPeer() is undefined in the juce_application demo project. What’s the best way to resolve that missing symbol?

createNewPeer just lives in the mac platform specific code - sounds like a link error to me, or something not rebuilt correctly?

I’m a new user to your framework, so I’m still figuring out how the platform specific code is handled. Perhaps that’s the root of my problem.

In the mac application example, the class HelloWorldWindow is defined
as a Component. Component.h defines createNewPeer(), but doesn’t have an implementation, hence the link error.

Should the mac demo app use the MacWindowComponentPeer class instead of the Component class? The mac specific version has createNewPeer() implemented.

The example app should work fine, this isn’t a bug in the code, it sounds more like the juce library itself hasn’t compiled properly, or you’re linking to an older version, perhaps? Try cleaning and rebuilding the juce project completely, in both debug and release configs.

I’ve noticed that if I rebuild the JUCE library and then rebuild my project, the updated JUCE library doesn’t get linked in. So make sure you also do a clean and rebuild of your project as well. That works for me.

OK, I cleaned and recompiled both the JUCE subproject and the juce_application example project for the mac, and I still get an undefined symbol error for createNewPeer().

The build is taking place inside the juce folder I downloaded from the website with 1.29. If I were having versioning problems, wouldn’t I see additional link errors, beyond this one missing symbol?

The JUCE library subproject compiles without a problem.

The method is defined in juce_mac_Windowing.cpp. If that file isn’t compiled, there’s a hell of a lot of other things that won’t link too!

Could you have perhaps damaged the file? It should contain:

ComponentPeer* Component::createNewPeer (int styleFlags, void* windowToAttachTo) { return new MacWindowComponentPeer (this, styleFlags, (WindowRef) windowToAttachTo); }

I think I’ve fixed the problem.

I downloaded 1.29 again, and this time didn’t change the name of
the juce folder. Now all is well in juce_application land.

Just for kicks I changed the name of the containing juce folder, and that
cause a number of problems, so it seems that there are some paths that aren’t completely project relative, but that’s another issue.

Thanks for all the help!

probably your library search path that’s not relative, so it’d be using the old library…

I think that was it. I two juce folders, one named “juce” with an older version of the library, and a new one that I had renamed “juce 1.29”. Both were living on my desktop. Because the path for the library search paths is “…/…/…/juce/bin”, it was picking up the older library.

I tried changing that path to “…/…/bin”, but it didn’t work. Why’s that? Is there a way to remove “juce” from the library path name?