AAX and iOS CMake conflict?

I’m running into an issue with our CMake project generation. I’m having CMake generate two projects: one Mac and one iOS.

Creating iOS project files.
-- Configuring juceaide
-- Building juceaide
-- Exporting juceaide
CMake Error at /Users/tricky/Code/uamaster/uasdk/JUCE-6.0.4/extras/Build/CMake/JUCEUtils.cmake:1511 (message):
  Use juce_set_aax_sdk_path to set up the AAX sdk before adding AAX targets
Call Stack (most recent call first):
  /Users/tricky/Code/uamaster/uasdk/JUCE-6.0.4/extras/Build/CMake/JUCEUtils.cmake:2022 (_juce_configure_plugin_targets)
  CMakeLists.txt:30 (juce_add_plugin)

I’m definitely calling juce_set_aax_sdk_path before juce_add_plugin. I’m also doing set_target_properties(${TargetName}_AAX PROPERTIES OSX_ARCHITECTURES x86_64) after that so that AAX isn’t built as a Universal Binary 2 until that SDK is ready. The Mac project works perfectly and all targets are compiling successfully. The iOS project worked and compiled until I added AAX.

I have a Python file that calls platform-appropriate CMake arguments:

os.system("cmake -Bbuild -GXcode -DCMAKE_OSX_ARCHITECTURES='arm64;x86_64'")

print("Creating iOS project files.")
os.system("cmake -Biosbuild -GXcode -DCMAKE_SYSTEM_NAME=iOS -DCMAKE_OSX_DEPLOYMENT_TARGET=9.3 -DCMAKE_XCODE_ATTRIBUTE_CODE_SIGN_IDENTITY='iPhone Developer' ")

I’m using JUCE 6.0.4, main branch (non-dev).

Just wanted to bump this. Is anyone else experiencing this?

You maybe need to exclude AAX for the iOS build.

I have something like this for linux:

# supported plugin formats
set (FormatsToBuild VST3 VST)
if (APPLE)
    list (APPEND FormatsToBuild AU)
endif()

if (MSVC OR APPLE)
    juce_set_aax_sdk_path(../AAX)
    list (APPEND FormatsToBuild AAX)
endif()

juce_add_plugin(AudioPlugin
...
        FORMATS ${FormatsToBuild}                # The formats to build. Other valid formats are: AAX Unity 
...
        )   

Not sure if something similar also works here.

VST2 and AAX formats will now be silently disabled on iOS:

2 Likes