Building Max externals in JUCE


#1

Hi, I’ve moved over to building Max externals inside JUCE (well, trying). On Windows this is pretty straightforward, but on OSX the Max API requires the Carbon framework to be included (i.e. #include <Carbon/Carbon.h>). Once I do that I start to get clashes with Point and Component classes which are defined in Carbon and JUCE.

Anyone done similar and have any solutions that don’t involve me explicitly scoping all my JUCE classes?

thx


#2

Hi, turns out the explicit typing of Component was fairly trivial to allow Carbon to be included so not really in need of another solution.

However, generating an ‘mxo’ for Max is proving quite troublesome. If anyone has any hints on this, they would be much appreciated.

thx


#3

If I get it right, a .mxo is a bundle (like .vst and .component) that requires specific entries in its Info.plist file and a bunch of weird linker flags to link.

If you can read CMake code, I think you’ll find all you need in https://github.com/Cycling74/max-api/tree/master/script, but if you don’t, I’ll be happy to help you decipher.


#4

hi, yes, that’s correct. I have all the details as I’ve built the mxo by hand for other devices. I guess the bit I’m not sure about is how to get Projucer to generate a bundle setup, or if this is even possible. I’ve used the dynamic library template. This is fine for Windows as it produces the desired .dll as it’s output, but on OSX it’s creating a .dylib as it’s target.


#5

That’s why I pointed out that .mxo is similar to .vst and .component, the template that would match the most is the Audio Plugin. I guess it should be possible to customize the VST target within Projucer to make it produce a .mxo (add WRAPPER_EXTENSION = mxo to the Custom Xcode flags, use a Custom PList, add the required linker flags, …).


#6

Rather obsolete but it could help < https://github.com/frantic0/Jojo >.


#7

sorry, I missed that point… cheers, I’ll explore that…