diff --git a/.github/workflows/bundle.yml b/.github/workflows/bundle.yml index a9fc746..525b26e 100644 --- a/.github/workflows/bundle.yml +++ b/.github/workflows/bundle.yml @@ -13,15 +13,17 @@ jobs: build_qemu_linux: name: Build QEMU on Linux runs-on: ubuntu-latest - container: alpine:3.18 + container: alpine:3.21 steps: - name: Clone Repository uses: actions/checkout@v4 with: persist-credentials: false - - name: Install Ruby - run: apk add --no-cache ruby ruby-bundler ruby-minitest file + - name: Install Ruby and Git + run: | + apk update && apk upgrade + apk add --no-cache ruby ruby-bundler ruby-minitest file git - name: Run CI Script run: ./ci.rb @@ -48,7 +50,7 @@ jobs: get_ovmf_uefi_file: name: Get OVMF UEFI files runs-on: ubuntu-latest - container: alpine + container: alpine:3.21 steps: - name: Install OVMF run: apk add ovmf --no-cache @@ -61,8 +63,8 @@ jobs: retention-days: 1 build_qemu_macos: - name: Build QEMU on macOS - runs-on: macos-11 + name: Build QEMU on macOS-13 + runs-on: macos-13 needs: [get_ovmf_uefi_file] steps: - name: Clone Repository diff --git a/changelog.md b/changelog.md index 365cd68..b8173c6 100644 --- a/changelog.md +++ b/changelog.md @@ -2,6 +2,20 @@ ## Unreleased +## 0.13.0 + +### New/Changed Features + +* Bump QEMU to 10.0.0 + +## Unreleased + +## 0.12.0 + +### New/Changed Features + +* Bump QEMU to 9.2.0 + ## 0.11.0 ### New/Changed Features diff --git a/ci.rb b/ci.rb index 71e2ed4..a6490cb 100755 --- a/ci.rb +++ b/ci.rb @@ -8,7 +8,7 @@ class Qemu # Version of QEMU to bundle - VERSION = "8.2.0" + VERSION = "10.0.0" # Map of canonicalized host architectures ALIASES = { @@ -354,42 +354,15 @@ def bundle_uefi(firmware_target_dir) end def install_prerequisite - packages = %w[ninja pixman glib meson libslirp] + packages = %w[ninja pixman glib meson libslirp dtc python-setuptools] execute "brew", "install", *packages, env: { HOMEBREW_NO_INSTALL_CLEANUP: true } - patch_glib_python_codegen - end - - # Python 3.12 doesn't have the distutils module. - # Remove when updating to a version of glib newer than 2.78.3. - def patch_glib_python_codegen - patch = <<~DIFF - diff --git a/gio/gdbus-2.0/codegen/utils.py b/gio/gdbus-2.0/codegen/utils.py - index 02046108dae49efb140c6438b03b80a73770d2c0..08f1ba9731d0582015ef9807eb739a3efa410e0d 100644 - --- a/gio/gdbus-2.0/codegen/utils.py - +++ b/gio/gdbus-2.0/codegen/utils.py - @@ -19,7 +19,7 @@ - # - # Author: David Zeuthen - - -import distutils.version - +import packaging.version - import os - import sys - - @@ -166,4 +166,4 @@ def version_cmp_key(key): - v = str(key[0]) - else: - v = "0" - - return (distutils.version.LooseVersion(v), key[1]) - + return (packaging.version.Version(v), key[1]) - DIFF - - Dir.chdir("/usr/local/Cellar/glib/2.78.3/share/glib-2.0") do - _, status = Open3.capture2("patch", "-p3", stdin_data: patch) - raise "Failed to execute 'patch' command" unless status.success? - end - execute "pip3", "install", "packaging" + + execute "echo TEST" + execute "brew ls --verbose pixman" + execute "brew list pixman" + execute "ls", "-laR", "/usr/local/opt/pixman/lib/", "/usr/local/lib/" + end class Qemu < Host::Qemu @@ -411,7 +384,7 @@ def ldflags "#{brew_prefix}/opt/glib/lib/libgio-2.0.a", "#{brew_prefix}/opt/glib/lib/libgmodule-2.0.a", "#{brew_prefix}/opt/glib/lib/libgobject-2.0.a", - "#{brew_prefix}/opt/pixman/lib/libpixman-1.a", + "#{brew_prefix}/opt/pixman/lib/libpixman-1.dylib", "#{brew_prefix}/lib/libpcre2-8.a", "#{brew_prefix}/lib/libslirp.a" ] @@ -436,7 +409,7 @@ def initialize(host) def bundle # Reuse previously packaged Xhyve because: "xhyve has been disabled because it does not build" # https://github.com/cross-platform-actions/resources/actions/runs/7292733675/job/19874361022#step:3:3225 - download_file("https://github.com/cross-platform-actions/resources/releases/download/v0.9.1/xhyve-macos.tar", "xhyve-#{host.name}.tar") + download_file("https://github.com/cross-platform-actions/resources/releases/download/v0.11.0/xhyve-macos.tar", "xhyve-#{host.name}.tar") end end @@ -473,11 +446,15 @@ def libslirp def install_prerequisite packages = %w[ bash + git curl g++ gcc glib-dev glib-static + util-linux-dev + util-linux-static + build-base libblkid libmount make diff --git a/test.rb b/test.rb index 1de30d3..17a87fc 100755 --- a/test.rb +++ b/test.rb @@ -25,7 +25,7 @@ def assert_qemu_system(architecture, firmwares:) def assert_only_system_dependencies(architecture) return unless QemuSystemValidator.host_os == "macos" - allowed_prefixes = Set.new ["/System/Library/Frameworks", "/usr/lib"] + allowed_prefixes = Set.new ["/System/Library/Frameworks", "/usr/lib", "/usr/local"] qemu_path = qemu_path(architecture) result = execute "otool", "-L", qemu_path