Skip to content

Commit

Permalink
Merge pull request #435 from rust-osdev/fix-ci
Browse files Browse the repository at this point in the history
CI: Fix macOS errors
  • Loading branch information
phil-opp authored Apr 26, 2024
2 parents 4bd1ba4 + a263358 commit b7e2760
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
os: [ubuntu-latest, macos-12, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
timeout-minutes: 30

Expand Down
2 changes: 2 additions & 0 deletions api/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ mod version_info {
/// `#[link_section = ".bootloader-config"]`, which instructs the Rust compiler to store it
/// in a special section of the resulting ELF executable. From there, the bootloader will
/// automatically read it when loading the kernel.
#[cfg(target_arch = "x86_64")]
#[macro_export]
macro_rules! entry_point {
($path:path) => {
Expand Down Expand Up @@ -139,6 +140,7 @@ macro_rules! entry_point {
}

#[doc(hidden)]
#[cfg(target_arch = "x86_64")]
pub fn __force_use(slice: &&[u8; BootloaderConfig::SERIALIZED_LEN]) {
let force_use = slice as *const _ as usize;
unsafe { core::arch::asm!("add {0}, 0", in(reg) force_use, options(nomem, nostack)) };
Expand Down

0 comments on commit b7e2760

Please sign in to comment.