From 9f6794ea9772eaff5f97a8ce182cc6698aca4128 Mon Sep 17 00:00:00 2001 From: oxmc7769 Date: Mon, 25 May 2026 05:19:41 -0700 Subject: [PATCH] Change defaults, add boot.ipxe for mac testing --- boot.ipxe | 30 +++++++++++ build-mac.sh | 79 ++++++++++++++++++++++++++++ build.sh | 121 +++++++++++++++++++++++++++++++++++++++++++ src/config/general.h | 11 ++-- 4 files changed, 236 insertions(+), 5 deletions(-) create mode 100644 boot.ipxe create mode 100644 build-mac.sh create mode 100644 build.sh diff --git a/boot.ipxe b/boot.ipxe new file mode 100644 index 000000000..3aeba7e16 --- /dev/null +++ b/boot.ipxe @@ -0,0 +1,30 @@ +#!ipxe + +# ─── Network ──────────────────────────────────────────────────────────────── +dhcp || goto dhcp_failed + +# ─── Mac detection via SMBIOS manufacturer string ─────────────────────────── +# ${manufacturer} reads SMBIOS Type-1 "Manufacturer" field. +# All Intel Macs report "Apple Inc." here. +iseq ${manufacturer} Apple Inc. && goto mac + +# ─── Non-Mac boot ──────────────────────────────────────────────────────────── +chain http://${next-server}/default.ipxe || goto failed +goto end + +# ─── Mac boot ──────────────────────────────────────────────────────────────── +:mac +chain http://${next-server}/mac.ipxe || goto failed +goto end + +# ─── Error handlers ────────────────────────────────────────────────────────── +:dhcp_failed +echo DHCP failed - no network +sleep 5 +reboot + +:failed +echo Chain failed - dropping to shell +shell + +:end diff --git a/build-mac.sh b/build-mac.sh new file mode 100644 index 000000000..99e52efbd --- /dev/null +++ b/build-mac.sh @@ -0,0 +1,79 @@ +#!/usr/bin/env bash +# ============================================================================= +# Mac-specific iPXE build shortcut +# +# Builds both the native tg3 EFI binary and an SNP fallback, with the +# boot.ipxe script embedded in each. Outputs to ./build/. +# +# Usage: +# ./build-mac.sh [--embed