Xcode 4.3


#1

Well, looks like Apple have been moving things around again, and if you upgrade to Xcode 4.3 you’re going to find that you can’t build AU plugins any more because they’ve removed the old /Developer folder that contained all the headers.

What you now need to do is:

  • In Xcode, choose “Open Developer Tool” / “More Developer Tools…”, and download the audio package.
  • Go to the Xcode.app, view its contents, and find the Developer folder inside it.
  • Create an Extras folder inside the Developer folder, and copy the CoreAudio folder that you downloaded into it
  • When you compile, you’ll hit some errors in Apple’s code which you’ll need to fix. Nothing big, just add some casts and disambiguation for the latest version of Clang to accept it. (I had to do this in TextEdit because Xcode crashed when I tried to edit these files. Nice.)

…HTH!


#2

I hear that XCode 4.3 crashes more often than a blind man driving on the freeway.


#3

I had it in a state today where as soon as I ran Xcode, it crashed. Took me an hour to find a way to stop it happening. 4.3 is a dreadful update - avoid it if possible.


#4

Yeah that’s what everyone is saying, wait for a bugfix before upgrading.


#5

Always build error because of “Command /Applications/Xcode.app/Contents/Developer/usr/bin/Rez failed with exit code 2”, and there’s no Rez under this dir.

How to solve this?


#6

[quote=“xsd121”]Always build error because of “Command /Applications/Xcode.app/Contents/Developer/usr/bin/Rez failed with exit code 2”, and there’s no Rez under this dir.

How to solve this?[/quote]

No idea, sorry! My installation does have that tool, so if yours doesn’t, maybe re-install?


#7

I’ve fixed that.
The problem seems to be under the config “Build Phases -> Build Carbon Resources”, there should only be one file existing: juce_AU_Resources.r. But after I perform an update prompted by xcode, it changed to two items: it adds the AUResources.r in this section, then I got this error. Remove that AUResources.r will do.

This 4.3 update is really a catastrophe for au plugin(I need to use the new iOS today so I update from 4.2 to 4.3.1).

I need to relocate all Apple AU Files that were included by IntroJucer. But how could I relocate them with ease?
The only way I found is to store the CoreAudio dir in a dir other than inside the Xcode.app so I could add them by using the “Add Files to XXX(projectname)” function.


#8

Though I’ve got a successful build now (after 1 hour’s arranging), my condition that “no Rez under usr/bin” hasn’t changed…
I don’t know if it is weird.
Anyway, a successful build is the most important…


#9

Just had to log in to strongly agree with this. I like a lot of Apple’s products but Xcode sure as hell isn’t one of them. I’ve moved entirely to Jetbrains’ AppCode for my Objective-C work, and it’s 100x better in just about every respect. Unfortunately it doesn’t handle C++ very well so I’m stuck with Xcode for my C++ projects.

Apple’s neglect of Xcode and of the entire CoreAudio/AudioUnit SDK really makes me wonder how seriously they take their developers.


#10

There’s always IntroJucer + Makefiles. No?


#11

For what its worth 4.3.2 is a lot more stable. Make sure you use GDB instead of the LLDB debugger though because variables can be displayed incorrectly in that.


#12

[quote=“TheVinn”]
There’s always IntroJucer + Makefiles. No?[/quote]
As bad as Xcode is it’s still better than a plain text editor or something like Vim/Emacs (IMO).

And yes, 4.3.2 doesn’t crash as much as previous versions. Only 2-3x times a day for me now.


#13

[quote=“kuniklo”][quote=“TheVinn”]
There’s always IntroJucer + Makefiles. No?[/quote]
As bad as Xcode is it’s still better than a plain text editor or something like Vim/Emacs (IMO).[/quote]

Have you seen Sublime Text ?

This editor is amazing! Its got some serious data structures behind it. Try opening up a 20 megabyte text file, it handles it no problem, including the thumbnail preview! You can insert lines right in the middle of the file and it updates FAST as if it was nothing, the thumbnail updates instantly! And this includes all the syntax highlighting, etc…

This is one of the pieces of the huge-text editing puzzle:
Rope Data Structure

If the juce TextEditor component could be as good as SublimeText … whoa!!!


#14

In my opinion the “Rez” is going to be deprecated and this is why Apple replace the .r files in favor of the .plist
Take a look here
The new “AUPlugIn” do not use resource files (.r files) or the ‘thng’ resource to define properties.


#15

hi there
i’m absolutely new to mac and xcode. i’d like to compile the audio-plugin i just finished within vc2010 in xcode on a lion-mac. can someone please give me a step by step explanation how to get juce 2.0 compiling my plugin in xcode?? i just don’t get it working!!

thanks a lot!!
pascal


#16

[quote=“brp”]hi there
i’m absolutely new to mac and xcode. i’d like to compile the audio-plugin i just finished within vc2010 in xcode on a lion-mac. can someone please give me a step by step explanation how to get juce 2.0 compiling my plugin in xcode?? i just don’t get it working!!

thanks a lot!!
pascal[/quote]

I think you need to give more details about exactly what problems you’re having.


#17

[quote=“xsd121”]Always build error because of “Command /Applications/Xcode.app/Contents/Developer/usr/bin/Rez failed with exit code 2”, and there’s no Rez under this dir.

How to solve this?[/quote]

Depending on your version of XCode, you may get another error about an ambiguous function call. If this happens, open the file AUMidiEffectBase.cpp in the folder Juce AU Wrapper/Apple AU Files. This file should contain the error in compilation (it’s on line 154 in my system). Change the offending line to read as follows:
result = ((AUMIDIBase*)This)->MIDIEvent(inStatus, inData1, inData2,
inOffsetSampleFrame);
From here you should be able to successfully build the project.


#18

Thanks so much for this sinaclamet. Your instructions worked perfectly for me


#19

Does anyone else get this error when building with RTAS?

.../ASConnUtil.h:25:10: fatal error: 'Components.h' file not found

This happens to me with XCode 4.3 building the juce’s example plugin with latest tip (b6211f01c871a0317ab98dd9e6f10caa04535530) …


#20

Update: the project builds when commenting out the line

#include <Components.h>

from ASConnUtil.h from the RTAS SDK.
Of course, changing the SDK files isn’t a nice solution…