From ca8e9b70a85cc3311de0233b582b2a3e2d2eddc7 Mon Sep 17 00:00:00 2001 From: Cacodemon345 Date: Mon, 19 Dec 2022 13:30:51 +0600 Subject: [PATCH 01/10] Reset size of screen on 4:3 option toggling --- src/qt/qt_mainwindow.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/qt/qt_mainwindow.cpp b/src/qt/qt_mainwindow.cpp index 102363414..3078ccde7 100644 --- a/src/qt/qt_mainwindow.cpp +++ b/src/qt/qt_mainwindow.cpp @@ -1835,6 +1835,7 @@ video_toggle_option(QAction *action, int *val) action->setChecked(*val > 0 ? true : false); endblit(); config_save(); + reset_screen_size(); device_force_redraw(); for (int i = 0; i < MONITORS_NUM; i++) { if (monitors[i].target_buffer) From b85ca5091b43148b4c91df191fc8626342bf7d44 Mon Sep 17 00:00:00 2001 From: Jasmine Iwanek Date: Mon, 19 Dec 2022 03:30:49 -0500 Subject: [PATCH 02/10] Try and work out what is causing packaging to fail --- .github/workflows/cmake.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index 534d268b7..c00b683fd 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -105,7 +105,7 @@ jobs: shell: msys2 {0} strategy: - fail-fast: true + fail-fast: false matrix: build: - name: Debug From 6ce4f2de03290e39bb742301c93227a678e30fea Mon Sep 17 00:00:00 2001 From: Cacodemon345 Date: Mon, 19 Dec 2022 22:52:17 +0600 Subject: [PATCH 03/10] qt: Don't resize renderer screen beyond window size --- src/qt/qt_mainwindow.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qt/qt_mainwindow.cpp b/src/qt/qt_mainwindow.cpp index 3078ccde7..d707fc7ea 100644 --- a/src/qt/qt_mainwindow.cpp +++ b/src/qt/qt_mainwindow.cpp @@ -261,7 +261,7 @@ MainWindow::MainWindow(QWidget *parent) + (statusBar()->height() * !hide_status_bar) + (ui->toolBar->height() * !hide_tool_bar); - ui->stackedWidget->resize(w, h); + ui->stackedWidget->resize(w, (h / (!dpi_scale ? util::screenOfWidget(this)->devicePixelRatio() : 1.))); setFixedSize(w, modifiedHeight); } }); From 10b52114208fd0ecec699c0c4514936ea1c49a43 Mon Sep 17 00:00:00 2001 From: Jasmine Iwanek Date: Mon, 19 Dec 2022 14:59:45 -0500 Subject: [PATCH 04/10] Disable Qt MINGW32 packaging for now --- .github/workflows/cmake.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index c00b683fd..eceb3f2d6 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -105,7 +105,7 @@ jobs: shell: msys2 {0} strategy: - fail-fast: false + fail-fast: true matrix: build: - name: Debug @@ -162,6 +162,7 @@ jobs: - name: Build run: cmake --build build - name: Generate package + if: matrix.environment.msystem != 'MINGW32' run: cmake --install build - uses: actions/upload-artifact@v3 with: From 561b6b1b0620a7269c128bbb05c843ab8c95f595 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Hrdli=C4=8Dka?= Date: Mon, 19 Dec 2022 14:37:01 +0100 Subject: [PATCH 05/10] vcpkg: fix Qt build --- .github/workflows/cmake.yml | 4 ++-- vcpkg.json | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index eceb3f2d6..c303f4631 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -197,8 +197,8 @@ jobs: ui: - name: Win32 GUI qt: off -# - name: Qt GUI -# qt: on + - name: Qt GUI + qt: on slug: -Qt target: - name: x86 diff --git a/vcpkg.json b/vcpkg.json index f3f420b33..46ab6bff3 100644 --- a/vcpkg.json +++ b/vcpkg.json @@ -21,6 +21,7 @@ "concurrent", "default-features", "gui", + "opengl", "harfbuzz", "network", "vulkan", From 82bdd54b203a960e2dfec236396e54fa799e998d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Hrdli=C4=8Dka?= Date: Mon, 19 Dec 2022 14:42:52 +0100 Subject: [PATCH 06/10] actions: combine the two MSYS2 jobs into one --- .github/workflows/cmake.yml | 114 ++++++++---------------------------- 1 file changed, 26 insertions(+), 88 deletions(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index c303f4631..ec488eea5 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -25,7 +25,7 @@ on: jobs: msys2: - name: MSYS2 (Win32 GUI, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.environment.msystem }}) + name: MSYS2 (${{ matrix.ui.name }}, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.environment.msystem }}) runs-on: windows-2022 @@ -50,6 +50,17 @@ jobs: - name: NDR new: on slug: -NDR + ui: + - name: Win32 GUI + qt: off + static: on + - name: Qt GUI + qt: on + static: off + slug: -Qt + packages: >- + qt5-base:p + qt5-tools:p environment: - msystem: MINGW32 prefix: mingw-w64-i686 @@ -64,20 +75,20 @@ jobs: steps: - uses: msys2/setup-msys2@v2 with: - path-type: inherit update: true msystem: ${{ matrix.environment.msystem }} - install: >- - ${{ matrix.environment.prefix }}-ninja - ${{ matrix.environment.prefix }}-cc - ${{ matrix.environment.prefix }}-pkg-config - ${{ matrix.environment.prefix }}-freetype - ${{ matrix.environment.prefix }}-SDL2 - ${{ matrix.environment.prefix }}-zlib - ${{ matrix.environment.prefix }}-libpng - ${{ matrix.environment.prefix }}-libvncserver - ${{ matrix.environment.prefix }}-openal - ${{ matrix.environment.prefix }}-rtmidi + pacboy: >- + ninja:p + cmake:p + cc:p + pkg-config:p + freetype:p + SDL2:p + zlib:p + libpng:p + openal:p + rtmidi:p + ${{ matrix.ui.packages }} - uses: actions/checkout@v3 - name: Configure CMake run: >- @@ -85,7 +96,8 @@ jobs: --toolchain ${{ matrix.environment.toolchain }} -D NEW_DYNAREC=${{ matrix.dynarec.new }} -D CMAKE_INSTALL_PREFIX=./build/artifacts - -D QT=OFF + -D QT=${{ matrix.ui.qt }} + -D STATIC_BUILD=${{ matrix.ui.static }} - name: Build run: cmake --build build - name: Generate package @@ -95,80 +107,6 @@ jobs: name: '86Box${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-Windows-${{ matrix.environment.msystem }}-gha${{ github.run_number }}' path: build/artifacts/** - msys2-qt: - name: MSYS2 (Qt GUI, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.environment.msystem }}) - - runs-on: windows-2022 - - defaults: - run: - shell: msys2 {0} - - strategy: - fail-fast: true - matrix: - build: - - name: Debug - preset: debug - slug: -Debug - - name: Dev - preset: experimental - slug: -Dev - dynarec: - - name: ODR - new: off - slug: -ODR - - name: NDR - new: on - slug: -NDR - environment: - - msystem: MINGW32 - prefix: mingw-w64-i686 - toolchain: ./cmake/flags-gcc-i686.cmake - - msystem: MINGW64 - prefix: mingw-w64-x86_64 - toolchain: ./cmake/flags-gcc-x86_64.cmake - - msystem: UCRT64 - prefix: mingw-w64-ucrt-x86_64 - toolchain: ./cmake/flags-gcc-x86_64.cmake - - steps: - - uses: msys2/setup-msys2@v2 - with: - path-type: inherit - update: true - msystem: ${{ matrix.environment.msystem }} - install: >- - ${{ matrix.environment.prefix }}-ninja - ${{ matrix.environment.prefix }}-cc - ${{ matrix.environment.prefix }}-pkg-config - ${{ matrix.environment.prefix }}-freetype - ${{ matrix.environment.prefix }}-SDL2 - ${{ matrix.environment.prefix }}-zlib - ${{ matrix.environment.prefix }}-libpng - ${{ matrix.environment.prefix }}-libvncserver - ${{ matrix.environment.prefix }}-openal - ${{ matrix.environment.prefix }}-rtmidi - ${{ matrix.environment.prefix }}-qt5-base - ${{ matrix.environment.prefix }}-qt5-tools - - uses: actions/checkout@v3 - - name: Configure CMake - run: >- - cmake -G Ninja -S . -B build --preset ${{ matrix.build.preset }} - --toolchain ${{ matrix.environment.toolchain }} - -D NEW_DYNAREC=${{ matrix.dynarec.new }} - -D CMAKE_INSTALL_PREFIX=./build/artifacts - -D QT=ON - - name: Build - run: cmake --build build - - name: Generate package - if: matrix.environment.msystem != 'MINGW32' - run: cmake --install build - - uses: actions/upload-artifact@v3 - with: - name: '86Box-Qt${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-Windows-${{ matrix.environment.msystem }}-gha${{ github.run_number }}' - path: build/artifacts/** - llvm-windows: name: "Windows vcpkg/LLVM (${{ matrix.ui.name }}, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.target.name }})" From f480e6b5cdcb480115dc86f6edcbeb81a7ec38da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Hrdli=C4=8Dka?= Date: Mon, 19 Dec 2022 21:10:47 +0100 Subject: [PATCH 07/10] actions: add frontend slug to MSYS2 --- .github/workflows/cmake.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index ec488eea5..e6da49cef 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -104,7 +104,7 @@ jobs: run: cmake --install build - uses: actions/upload-artifact@v3 with: - name: '86Box${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-Windows-${{ matrix.environment.msystem }}-gha${{ github.run_number }}' + name: '86Box${{ matrix.ui.slug }}${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-Windows-${{ matrix.environment.msystem }}-gha${{ github.run_number }}' path: build/artifacts/** llvm-windows: From 1ed1a5da3d50eafab45124b03c16489c5091a037 Mon Sep 17 00:00:00 2001 From: Jasmine Iwanek Date: Mon, 19 Dec 2022 18:41:09 -0500 Subject: [PATCH 08/10] Create llvm-win32-arm.cmake --- cmake/llvm-win32-arm.cmake | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 cmake/llvm-win32-arm.cmake diff --git a/cmake/llvm-win32-arm.cmake b/cmake/llvm-win32-arm.cmake new file mode 100644 index 000000000..9d3488124 --- /dev/null +++ b/cmake/llvm-win32-arm.cmake @@ -0,0 +1,30 @@ +# +# 86Box A hypervisor and IBM PC system emulator that specializes in +# running old operating systems and software designed for IBM +# PC systems and compatibles from 1981 through fairly recent +# system designs based on the PCI bus. +# +# This file is part of the 86Box distribution. +# +# CMake toolchain file for Clang on Windows builds (ARM64 target). +# +# Authors: David Hrdlička, +# +# Copyright 2021 David Hrdlička. +# + +include(${CMAKE_CURRENT_LIST_DIR}/flags-gcc-armv7.cmake) + +# Use the GCC-compatible Clang executables in order to use our flags +set(CMAKE_C_COMPILER clang) +set(CMAKE_CXX_COMPILER clang++) + +# `llvm-rc` is barely usable as of LLVM 13, using MS' rc.exe for now +set(CMAKE_RC_COMPILER rc) + +set(CMAKE_C_COMPILER_TARGET arm-pc-windows-msvc) +set(CMAKE_CXX_COMPILER_TARGET arm-pc-windows-msvc) + +set(CMAKE_SYSTEM_PROCESSOR ARM) + +# TODO: set the vcpkg target triplet perhaps? From cfe3fec2baa2160fe6417dc4b4bdd077f8067f09 Mon Sep 17 00:00:00 2001 From: Jasmine Iwanek Date: Mon, 19 Dec 2022 19:45:39 -0500 Subject: [PATCH 09/10] Fix issues on non QT unix builds --- src/include/86box/unix_sdl.h | 6 +++--- src/unix/macOSXGlue.h | 2 +- src/unix/unix.c | 16 ++++++++-------- src/unix/unix_sdl.c | 16 ++++++++-------- 4 files changed, 20 insertions(+), 20 deletions(-) diff --git a/src/include/86box/unix_sdl.h b/src/include/86box/unix_sdl.h index 0054ed938..27d7ec0aa 100644 --- a/src/include/86box/unix_sdl.h +++ b/src/include/86box/unix_sdl.h @@ -2,9 +2,9 @@ #define _UNIX_SDL_H extern void sdl_close(void); -extern int sdl_inits(); -extern int sdl_inith(); -extern int sdl_initho(); +extern int sdl_inits(void); +extern int sdl_inith(void); +extern int sdl_initho(void); extern int sdl_pause(void); extern void sdl_resize(int x, int y); extern void sdl_enable(int enable); diff --git a/src/unix/macOSXGlue.h b/src/unix/macOSXGlue.h index f49402805..44bf9e7f6 100644 --- a/src/unix/macOSXGlue.h +++ b/src/unix/macOSXGlue.h @@ -14,7 +14,7 @@ CF_IMPLICIT_BRIDGING_ENABLED CF_EXTERN_C_BEGIN void getDefaultROMPath(char *); -int toto(); +int toto(void); CF_EXTERN_C_END CF_IMPLICIT_BRIDGING_DISABLED diff --git a/src/unix/unix.c b/src/unix/unix.c index 4410118f3..296da5e14 100644 --- a/src/unix/unix.c +++ b/src/unix/unix.c @@ -468,12 +468,12 @@ ui_sb_update_tip(int arg) } void -ui_sb_update_panes() +ui_sb_update_panes(void) { } void -ui_sb_update_text() +ui_sb_update_text(void) { } @@ -699,7 +699,7 @@ typedef struct mouseinputdata { SDL_mutex *mousemutex; static mouseinputdata mousedata; void -mouse_poll() +mouse_poll(void) { SDL_LockMutex(mousemutex); mouse_x = mousedata.deltax; @@ -754,7 +754,7 @@ plat_pause(int p) } void -plat_init_rom_paths() +plat_init_rom_paths(void) { #ifndef __APPLE__ if (getenv("XDG_DATA_HOME")) { @@ -1202,7 +1202,7 @@ main(int argc, char **argv) case SDL_RENDER_DEVICE_RESET: case SDL_RENDER_TARGETS_RESET: { - extern void sdl_reinit_texture(); + extern void sdl_reinit_texture(void); sdl_reinit_texture(); break; } @@ -1238,7 +1238,7 @@ main(int argc, char **argv) sdl_blit(params.x, params.y, params.w, params.h); } if (title_set) { - extern void ui_window_title_real(); + extern void ui_window_title_real(void); ui_window_title_real(); } if (video_fullscreen && keyboard_isfsexit()) { @@ -1303,13 +1303,13 @@ joystick_process(void) { } void -startblit() +startblit(void) { SDL_LockMutex(blitmtx); } void -endblit() +endblit(void) { SDL_UnlockMutex(blitmtx); } diff --git a/src/unix/unix_sdl.c b/src/unix/unix_sdl.c index bd2f3937b..bc89c9290 100644 --- a/src/unix/unix_sdl.c +++ b/src/unix/unix_sdl.c @@ -46,7 +46,7 @@ double mouse_sensitivity = 1.0; /* Unused. */ double mouse_x_error = 0.0, mouse_y_error = 0.0; /* Unused. */ static uint8_t interpixels[17842176]; -extern void RenderImGui(); +extern void RenderImGui(void); static void sdl_integer_scale(double *d, double *g) { @@ -61,7 +61,7 @@ sdl_integer_scale(double *d, double *g) } } -void sdl_reinit_texture(); +void sdl_reinit_texture(void); static void sdl_stretch(int *w, int *h, int *x, int *y) @@ -141,7 +141,7 @@ sdl_blit_shim(int x, int y, int w, int h, int monitor_index) video_blit_complete_monitor(monitor_index); } -void ui_window_title_real(); +void ui_window_title_real(void); void sdl_real_blit(SDL_Rect *r_src) @@ -286,7 +286,7 @@ sdl_select_best_hw_driver(void) } void -sdl_reinit_texture() +sdl_reinit_texture(void) { sdl_destroy_texture(); @@ -416,19 +416,19 @@ sdl_init_common(int flags) } int -sdl_inits() +sdl_inits(void) { return sdl_init_common(0); } int -sdl_inith() +sdl_inith(void) { return sdl_init_common(RENDERER_HARDWARE); } int -sdl_initho() +sdl_initho(void) { return sdl_init_common(RENDERER_HARDWARE | RENDERER_OPENGL); } @@ -462,7 +462,7 @@ wchar_t sdl_win_title[512] = { L'8', L'6', L'B', L'o', L'x', 0 }; SDL_mutex *titlemtx = NULL; void -ui_window_title_real() +ui_window_title_real(void) { char *res; if (sizeof(wchar_t) == 1) { From 5ef744ab2d2aefe01900e367302c8b0ec00dbb7b Mon Sep 17 00:00:00 2001 From: Jasmine Iwanek Date: Mon, 19 Dec 2022 19:07:03 -0500 Subject: [PATCH 10/10] Fix many inconsistencies in GHA cmake script --- .github/workflows/c-cpp.yml | 60 +++++++++++++++++++++---------------- .github/workflows/cmake.yml | 60 +++++++++++++++++++++++-------------- 2 files changed, 72 insertions(+), 48 deletions(-) diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index 7eafa3d12..0c4ecd6b7 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -16,9 +16,9 @@ on: jobs: msys2: - name: MSYS2 Makefile (Win32 GUI, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.environment.msystem }}) + name: "Windows MSYS2 Makefile (Win32 GUI, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.environment.msystem }})" - runs-on: windows-latest + runs-on: windows-2022 defaults: run: @@ -50,28 +50,38 @@ jobs: - msystem: MINGW64 prefix: mingw-w64-x86_64 x64: y + - msystem: UCRT64 + prefix: mingw-w64-ucrt-x86_64 + x64: y steps: - - uses: msys2/setup-msys2@v2 - with: - update: true - msystem: ${{ matrix.environment.msystem }} - install: >- - make - ${{ matrix.environment.prefix }}-gcc - ${{ matrix.environment.prefix }}-pkg-config - ${{ matrix.environment.prefix }}-openal - ${{ matrix.environment.prefix }}-freetype - ${{ matrix.environment.prefix }}-SDL2 - ${{ matrix.environment.prefix }}-zlib - ${{ matrix.environment.prefix }}-libpng - ${{ matrix.environment.prefix }}-libvncserver - ${{ matrix.environment.prefix }}-rtmidi - - uses: actions/checkout@v3 - - name: make - run: make -fwin/makefile.mingw -j DEV_BUILD=${{ matrix.build.dev }} DEBUG=${{ matrix.build.debug }} NEW_DYNAREC=${{ matrix.dynarec.new }} X64=${{ matrix.environment.x64 }} VNC=n - working-directory: ./src - - uses: actions/upload-artifact@v3 - with: - name: '86Box${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-Windows-${{ matrix.environment.msystem }}-gha${{ github.run_number }}' - path: src/86Box.exe + - name: Prepare MSYS2 environment + uses: msys2/setup-msys2@v2 + with: + update: true + msystem: ${{ matrix.environment.msystem }} + install: >- + make + ${{ matrix.environment.prefix }}-gcc + ${{ matrix.environment.prefix }}-pkg-config + ${{ matrix.environment.prefix }}-freetype + ${{ matrix.environment.prefix }}-SDL2 + ${{ matrix.environment.prefix }}-zlib + ${{ matrix.environment.prefix }}-libpng + ${{ matrix.environment.prefix }}-openal + ${{ matrix.environment.prefix }}-rtmidi + ${{ matrix.environment.prefix }}-libvncserver + - uses: actions/checkout@v3 + - name: make + run: >- + make -fwin/makefile.mingw -j + DEV_BUILD=${{ matrix.build.dev }} + DEBUG=${{ matrix.build.debug }} + NEW_DYNAREC=${{ matrix.dynarec.new }} + X64=${{ matrix.environment.x64 }} + VNC=n + working-directory: ./src + - uses: actions/upload-artifact@v3 + with: + name: '86Box${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-Windows-${{ matrix.environment.msystem }}-gha${{ github.run_number }}' + path: src/86Box.exe diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml index e6da49cef..6876e83bc 100644 --- a/.github/workflows/cmake.yml +++ b/.github/workflows/cmake.yml @@ -25,7 +25,7 @@ on: jobs: msys2: - name: MSYS2 (${{ matrix.ui.name }}, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.environment.msystem }}) + name: "Windows MSYS2 (${{ matrix.ui.name }}, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, ${{ matrix.environment.msystem }})" runs-on: windows-2022 @@ -73,14 +73,15 @@ jobs: toolchain: ./cmake/flags-gcc-x86_64.cmake steps: - - uses: msys2/setup-msys2@v2 + - name: Prepare MSYS2 environment + uses: msys2/setup-msys2@v2 with: update: true msystem: ${{ matrix.environment.msystem }} pacboy: >- ninja:p cmake:p - cc:p + gcc:p pkg-config:p freetype:p SDL2:p @@ -88,6 +89,7 @@ jobs: libpng:p openal:p rtmidi:p + libvncserver:p ${{ matrix.ui.packages }} - uses: actions/checkout@v3 - name: Configure CMake @@ -98,6 +100,7 @@ jobs: -D CMAKE_INSTALL_PREFIX=./build/artifacts -D QT=${{ matrix.ui.qt }} -D STATIC_BUILD=${{ matrix.ui.static }} + -D VNC=n - name: Build run: cmake --build build - name: Generate package @@ -141,15 +144,15 @@ jobs: target: - name: x86 triplet: x86-windows-static - toolchain: cmake/llvm-win32-i686.cmake + toolchain: ./cmake/llvm-win32-i686.cmake vcvars: x64_x86 - name: x64 triplet: x64-windows-static - toolchain: cmake/llvm-win32-x86_64.cmake + toolchain: ./cmake/llvm-win32-x86_64.cmake vcvars: x64 - name: ARM64 triplet: arm64-windows-static - toolchain: cmake/llvm-win32-aarch64.cmake + toolchain: ./cmake/llvm-win32-aarch64.cmake vcvars: x64_arm64 exclude: - dynarec: @@ -158,7 +161,6 @@ jobs: name: ARM64 steps: - - uses: actions/checkout@v3 - name: Prepare VS environment uses: ilammy/msvc-dev-cmd@v1 with: @@ -180,11 +182,13 @@ jobs: -password "${{ secrets.GITHUB_TOKEN }}" - name: Fix MSVC atomic headers run: dir "C:/Program Files/Microsoft Visual Studio/2022/*/VC/Tools/MSVC/*/include" -include stdatomic.h -recurse | del + - uses: actions/checkout@v3 - name: Configure CMake run: > cmake -G Ninja -S . -B build --preset ${{ matrix.build.preset }} --toolchain C:/vcpkg/scripts/buildsystems/vcpkg.cmake -D NEW_DYNAREC=${{ matrix.dynarec.new }} -D QT=${{ matrix.ui.qt }} + -D CMAKE_INSTALL_PREFIX=./build/artifacts -D VCPKG_CHAINLOAD_TOOLCHAIN_FILE=${{ github.workspace }}/${{ matrix.target.toolchain }} -D VCPKG_TARGET_TRIPLET=${{ matrix.target.triplet }} -D VCPKG_HOST_TRIPLET=x64-windows @@ -200,14 +204,14 @@ jobs: - name: Build run: cmake --build build - name: Generate package - run: cmake --install build --prefix ./build/artifacts + run: cmake --install build - uses: actions/upload-artifact@v3 with: name: '86Box${{ matrix.ui.slug }}${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-Windows-LLVM-${{ matrix.target.name }}-gha${{ github.run_number }}' path: build/artifacts/** linux: - name: "Linux GCC 11 (${{ matrix.build.name }} ${{ matrix.dynarec.name }} x86_64)" + name: "Linux GCC 11 (Qt GUI, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, x86_64)" runs-on: ubuntu-22.04 @@ -230,7 +234,6 @@ jobs: slug: -NDR steps: - - uses: actions/checkout@v3 - name: Install dependencies run: >- sudo apt update && sudo apt install @@ -244,22 +247,24 @@ jobs: qtbase5-dev qttools5-dev libopenal-dev + - uses: actions/checkout@v3 - name: Configure CMake run: >- cmake -G Ninja -S . -B build --preset ${{ matrix.build.preset }} --toolchain ./cmake/flags-gcc-x86_64.cmake -D NEW_DYNAREC=${{ matrix.dynarec.new }} + -D CMAKE_INSTALL_PREFIX=./build/artifacts - name: Build run: cmake --build build -# - name: Generate package -# run: cmake --install build --prefix ./build/artifacts -# - uses: actions/upload-artifact@v3 -# with: -# name: '86Box${{ matrix.build.slug }}-UbuntuJammy-x86_64-gha${{ github.run_number }}' -# path: build/artifacts/** + - name: Generate package + run: cmake --install build + - uses: actions/upload-artifact@v3 + with: + name: '86Box-Qt${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-UbuntuJammy-x86_64-gha${{ github.run_number }}' + path: build/artifacts/** macos11: - name: "macOS 11 (${{ matrix.build.name }} x86_64)" + name: "macOS 11 (Qt GUI, ${{ matrix.build.name }}, ${{ matrix.dynarec.name }}, x86_64)" runs-on: macos-11 @@ -282,22 +287,31 @@ jobs: slug: -NDR steps: - - uses: actions/checkout@v3 - name: Install dependencies - run: brew install freetype sdl2 libpng rtmidi qt@5 openal-soft ninja + run: >- + brew install + ninja + freetype + sdl2 + libpng + rtmidi + qt@5 + openal-soft + - uses: actions/checkout@v3 - name: Configure CMake run: >- cmake -G Ninja -S . -B build --preset ${{ matrix.build.preset }} - --toolchain cmake/flags-gcc-x86_64.cmake - -D NEW_DYNAREC=${{ matrix.build.new-dynarec }} + --toolchain ./cmake/flags-gcc-x86_64.cmake + -D NEW_DYNAREC=${{ matrix.dynarec.new }} + -D CMAKE_INSTALL_PREFIX=./build/artifacts -D Qt5_ROOT=$(brew --prefix qt@5) -D Qt5LinguistTools_ROOT=$(brew --prefix qt@5) -D OpenAL_ROOT=$(brew --prefix openal-soft) - name: Build run: cmake --build build - name: Generate package - run: cmake --install build --prefix ./build/artifacts + run: cmake --install build - uses: actions/upload-artifact@v3 with: - name: '86Box${{ matrix.build.slug }}-macOS-x86_64-gha${{ github.run_number }}' + name: '86Box-Qt${{ matrix.dynarec.slug }}${{ matrix.build.slug }}-macOS-x86_64-gha${{ github.run_number }}' path: build/artifacts/**