Skip to content

Instantly share code, notes, and snippets.

@rhaleblian
Created April 10, 2022 15:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rhaleblian/5f490047a983f01188b717b2049e40ad to your computer and use it in GitHub Desktop.
Save rhaleblian/5f490047a983f01188b717b2049e40ad to your computer and use it in GitHub Desktop.
86box-apple-silicon-build.sh
cmake -B build -S . --toolchain "./cmake/llvm-macos-aarch64.cmake" \
-D VNC=OFF -D NEW_DYNAREC=ON -D QT=ON -D USE_QT6=ON \
-D Qt6QCocoaIntegrationPlugin_DIR=/opt/homebrew/Cellar/qt/6.2.3_1/lib/cmake/Qt6Gui \
-D Qt6QMacStylePlugin_DIR=/opt/homebrew/Cellar/qt/6.2.3_1/lib/cmake/Qt6Widgets \
-D Qt6QICOPlugin_DIR=/opt/homebrew/Cellar/qt/6.2.3_1/lib/cmake/Qt6Gui \
-D Qt6QICNSPlugin_DIR=/opt/homebrew/Cellar/qt/6.2.3_1/lib/cmake/Qt6Gui \
--install-prefix /Users/$USER/Developer/86Box/build/src/ -DCMAKE_BUILD_TYPE=Release -G Ninja -DFAUDIO=ON
cmake --build build --target install && codesign --force --deep -s - ./build/src/86Box.app
@brunocastello
Copy link

Hi, after getting the build dependencies, I have this error when I execute your script to build 86Box for M1:

CMake Error at src/qt/CMakeLists.txt:28 (find_package):
By not providing "FindQt6Gui/Qt6QCocoaIntegrationPlugin.cmake" in
CMAKE_MODULE_PATH this project has asked CMake to find a package
configuration file provided by "Qt6Gui/Qt6QCocoaIntegrationPlugin", but
CMake did not find one.

Could not find a package configuration file provided by
"Qt6Gui/Qt6QCocoaIntegrationPlugin" with any of the following names:

Qt6Gui/Qt6QCocoaIntegrationPluginConfig.cmake
qt6gui/qt6qcocoaintegrationplugin-config.cmake

Add the installation prefix of "Qt6Gui/Qt6QCocoaIntegrationPlugin" to
CMAKE_PREFIX_PATH or set "Qt6Gui/Qt6QCocoaIntegrationPlugin_DIR" to a
directory containing one of the above files. If
"Qt6Gui/Qt6QCocoaIntegrationPlugin" provides a separate development package
or SDK, be sure it has been installed.

What could possibly be wrong? I double checked your script, double checked my homebrew qt6 locations and the files are there, so I can't understand why cmake can't find it there.

@rhaleblian
Copy link
Author

Those messages relate exactly to the oddness that makes me have to add all those -D options to the command.
So you're close, and if the codebase has changed maybe my command is invalid now.

Check with the devs about whether there's a build process in the Jenkins CI instance -- they received a machine to build on so they may have formalized an official build workflow (so we don't need to devise one). Good luck!

@brunocastello
Copy link

Yeah I got one of those experimental builds to test, thanks!

@rhaleblian
Copy link
Author

great

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment