I am also trying to build SOFIE on macOS Monterey 12.3 with Apple Silicon and experiencing issues.
I am having the same issue as described here.
This is my build command:
cmake -DCMAKE_INSTALL_PREFIX=../root_install ../ -Dtmva-sofie=ON -Dtmva-pymva=On -DPython3_EXECUTABLE=/opt/homebrew/Caskroom/miniforge/base/envs/rootcern/bin/python
And similarly I get
[ 0%] Creating directories for 'FREETYPE'
[ 0%] Performing download step (verify and extract) for 'FREETYPE'
-- FREETYPE download command succeeded. See also /root_src/root_build/FREETYPE-prefix/src/FREETYPE-stamp/FREETYPE-download-*.log
[ 0%] No update step for 'FREETYPE'
[ 0%] No patch step for 'FREETYPE'
[ 0%] Performing configure step for 'FREETYPE'
CMake Error at /root_src/root_build/FREETYPE-prefix/src/FREETYPE-stamp/FREETYPE-configure-.cmake:49 (message):
Command failed: 2
'./configure' '--prefix' '/root_src/root_build/FREETYPE-prefix' '--with-pic' '--disable-shared' '--with-png=no' '--with-bzip2=no' '--with-harfbuzz=no' 'CC=/opt/homebrew/Caskroom/miniforge/base/envs/rootcern/bin/arm64-apple-darwin20.0.0-clang -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk' 'CFLAGS=-O'
See also
/root_src/root_build/FREETYPE-prefix/src/FREETYPE-stamp/FREETYPE-configure-*.log
make[2]: *** [FREETYPE-prefix/src/FREETYPE-stamp/FREETYPE-configure] Error 1
make[1]: *** [CMakeFiles/FREETYPE.dir/all] Error 2
And in the log file:
Invalid configuration `arm64-apple-darwin20.0.0': machine `arm64-apple' not recognized
configure: error: /bin/sh ./config.sub arm64-apple-darwin20.0.0 failed
make[3]: *** [setup] Error 1
Any ideas how to work around this?
I see the same issue reported here: Build error on M1 Macbook (while building freetype): "Invalid configuration `arm64-apple-darwin20.5.0': machine `arm64-apple' not recognized" · Issue #20661 · matplotlib/matplotlib · GitHub
Any tips appreciated!
Based on a chat with @sdwalker I tried -Dbuiltin_freetype=OFF
, but this did not prevent ROOT from trying to build FreeType somehow.