Here is a little patch to make CMake build on macOS with just the CommandlineTools installed but no Xcode.
diff --git a/extras/Build/CMake/JUCEUtils.cmake b/extras/Build/CMake/JUCEUtils.cmake
index 4bf7206e5..0002899e4 100644
--- a/extras/Build/CMake/JUCEUtils.cmake
+++ b/extras/Build/CMake/JUCEUtils.cmake
@@ -413,8 +413,8 @@ function(_juce_add_au_resource_fork shared_code_target au_target)
-I "${secret_au_resource_dir}"
-I "/System/Library/Frameworks/CoreServices.framework/Frameworks/CarbonCore.framework/Versions/A/Headers"
-I "/Applications/Xcode.app/Contents/Developer/Extras/CoreAudio/AudioUnits/AUPublic/AUBase"
- -I "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/AudioUnit.framework/Headers"
- -isysroot "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
+ -I "${CMAKE_OSX_SYSROOT}/System/Library/Frameworks/AudioUnit.framework/Headers "
+ -isysroot "${CMAKE_OSX_SYSROOT}"
"${au_rez_sources}"
-useDF
-o "${au_rez_output}"
Best,
Andreas