The main difficulty is that the CPU architecture is ARM64, whereas Imagine++ is compiled for Intel/AMD x86_64. Fortunately, MacOS has a tool named “Rosetta” that is able to run x86_64 code.
Open a terminal application and copy-paste this:
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
It will ask your password. Nothing appears while you type, this is normal. Press key Enter when done.
Follow instructions to set the environment variable at the end.
arch -x86_64 brew install cmake
arch -x86_64 brew install qt@5
arch -x86_64 brew install --cask qt-creator
curl -O https://imagine.enpc.fr/~monasse/Imagine++/downloads/Imagine++-5.0.0-Darwin-x86_64.pkg
open Imagine++-5.0.0-Darwin-x86_64.pkg
Launching this installer may fail because of “unidentified developer”. Don’t panic: go to the Apple menu, System Settings, section Security&Privacy. It says that Imagine++.framework was blocked. Click button Open Anyway.
curl -O --output-dir Documents https://imagine.enpc.fr/~monasse/Info/TPs/01/Tp1_Final.zip
cd Documents && unzip Tp1_Final.zip && cd
launchctl setenv QT_DIR /usr/local/opt/qt@5/lib/cmake
launchctl setenv Qt5_DIR /usr/local/opt/qt@5/lib/cmake
[ -d .config ] && sudo chown -R $(logname):staff .config
See https://imagine.enpc.fr/~monasse/Imagine++/usage.html.
Troubleshooting: https://imagine.enpc.fr/~monasse/Imagine++/pdf/qtCreatorCheckMac.pdf
QtCreator will not work directly when you restart your computer. The following line will ensure it continues to work next time you reboot:
curl -O --output-dir Library/LaunchAgents https://imagine.enpc.fr/~monasse/Imagine++/qt.plist