Use macOS 12 SDK and Xcode 13 toolchain to build Wine #52
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build Mythic Engine (wine-crossover 9.0) | |
| on: | |
| push: | |
| pull_request: | |
| env: | |
| MACOSX_DEPLOYMENT_TARGET: 10.15 | |
| SDKROOT: /Library/Developer/CommandLineTools/SDKs/MacOSX12.3.sdk | |
| TOOLCHAINS: com.applex.dt.toolchain.Xcode13 | |
| PATH: /usr/local/bin:/usr/local/opt/bison/bin:/usr/bin:/bin:/usr/sbin:/sbin | |
| CPATH: /usr/local/include | |
| LIBRARY_PATH: /usr/local/lib | |
| # mingw-w64 cross-compilers | |
| i386_CC: i686-w64-mingw32-gcc | |
| x86_64_CC: x86_64-w64-mingw32-gcc | |
| i386_LD: i686-w64-mingw32-ld | |
| x86_64_LD: x86_64-w64-mingw32-ld | |
| # compiler and linker flags | |
| CFLAGS: -O2 -Wno-deprecated-declarations -Wno-unguarded-availability | |
| CXXFLAGS: -O2 -Wno-deprecated-declarations -Wno-unguarded-availability | |
| CROSSCFLAGS: -O2 -Wno-error=incompatible-pointer-types -Wno-error=int-conversion -Wno-deprecated-declarations | |
| CPPFLAGS: -I/usr/local/opt/libpcap/include | |
| LDFLAGS: -Wl,-headerpad_max_install_names -Wl,-rpath,@loader_path/../../ -Wl,-rpath,@loader_path/../../external -Wl,-rpath,/usr/local/lib -L/usr/local/opt/libpcap/lib | |
| PKG_CONFIG_PATH: /usr/local/opt/libpcap/lib/pkgconfig | |
| # wine configure overrides | |
| ac_cv_lib_soname_MoltenVK: libMoltenVK.dylib | |
| ac_cv_lib_soname_vulkan: "" | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref_name }} | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| runs-on: macos-15-intel | |
| steps: | |
| - uses: actions/checkout@v5 | |
| with: | |
| path: src | |
| - name: download & add Xcode 13 toolchain | |
| run: | | |
| sudo mkdir -p /Library/Developer/Toolchains | |
| curl -fL https://dl.getmythic.app/engine/toolchains/Xcode13.xctoolchain.tar.xz \ | |
| | sudo tar -xJ -C /Library/Developer/Toolchains | |
| - name: download & add macOS 12.3 SDK | |
| run: | | |
| sudo mkdir -p /Library/Developer/CommandLineTools/SDKs | |
| curl -fL https://github.com/Gcenx/macos-sdk/releases/download/12.3/MacOSX12.3.tar.bz2 \ | |
| | sudo tar -xj -C /Library/Developer/CommandLineTools/SDKs | |
| - name: install build & runtime dependencies | |
| run: | | |
| brew install bison \ | |
| freetype \ | |
| pkg-config \ | |
| gettext \ | |
| gnutls \ | |
| gstreamer \ | |
| gst-plugins-base \ | |
| gst-plugins-good \ | |
| jpeg \ | |
| libpng \ | |
| libtiff \ | |
| libffi \ | |
| libpcap \ | |
| sdl2 \ | |
| molten-vk \ | |
| winetricks | |
| # install mingw-w64 v12.0.0_1 from local formula w/ tap | |
| # required, this version requires binutils 2.43.1 or older | |
| brew tap-new local/mingw-w64 | |
| cp src/external/dependencies/mingw-w64.rb \ | |
| "$(brew --repo local/mingw-w64)/Formula/mingw-w64.rb" | |
| brew install local/mingw-w64/mingw-w64 | |
| - name: create build directory | |
| run: mkdir -p build | |
| - name: configure wine | |
| working-directory: build | |
| run: | | |
| ../src/configure \ | |
| --prefix= \ | |
| --disable-tests \ | |
| --enable-archs=i386,x86_64 \ | |
| --with-mingw \ | |
| --without-alsa \ | |
| --without-capi \ | |
| --with-coreaudio \ | |
| --with-cups \ | |
| --without-dbus \ | |
| --without-fontconfig \ | |
| --with-freetype \ | |
| --with-gettext \ | |
| --without-gettextpo \ | |
| --without-gphoto \ | |
| --with-gnutls \ | |
| --without-gssapi \ | |
| --with-gstreamer \ | |
| --without-krb5 \ | |
| --without-netapi \ | |
| --with-opencl \ | |
| --with-opengl \ | |
| --without-oss \ | |
| --with-pcap \ | |
| --with-pthread \ | |
| --without-pulse \ | |
| --without-sane \ | |
| --with-sdl \ | |
| --without-udev \ | |
| --with-unwind \ | |
| --without-usb \ | |
| --without-v4l2 \ | |
| --with-vulkan \ | |
| --without-x | |
| - name: build wine | |
| working-directory: build | |
| run: make -j$(sysctl -n hw.ncpu) | |
| - name: create install directory | |
| run: mkdir -p install | |
| - name: install wine | |
| working-directory: build | |
| run: make install-lib DESTDIR=${{ github.workspace }}/install | |
| - name: add wine64 symlink for backward compatibility | |
| working-directory: install/bin | |
| run: ln -s wine wine64 | |
| - name: create Engine directory | |
| run: mkdir -p Engine | |
| - name: copy build artifacts | |
| run: | | |
| # copy wine installation | |
| mkdir -p Engine/wine | |
| cp -R install/* Engine/wine | |
| - name: copy externals | |
| run: | | |
| # copy dxvk binaries | |
| mkdir -p Engine/dxvk | |
| ditto src/external/dxvk-* Engine/dxvk/ | |
| # copy gptk libraries | |
| ditto src/external/gptk-*/redist/lib/ Engine/wine/lib/ | |
| - name: copy engine properties file | |
| run: cp -R src/Mythic/Properties.plist Engine/ | |
| - name: compress engine artifact | |
| run: tar -cJf Engine.tar.xz -C Engine . | |
| - name: upload engine artifact | |
| uses: actions/upload-artifact@v5 | |
| with: | |
| name: Engine | |
| path: Engine.tar.xz |