From 947c0d85c33c0db9b643aa4a4eefc447bd87f1f2 Mon Sep 17 00:00:00 2001 From: malik1004x Date: Sat, 12 Jul 2025 10:16:44 +0200 Subject: darwin sed on darwin only --- contrib/depends/packages/native_mrustc.mk | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'contrib') diff --git a/contrib/depends/packages/native_mrustc.mk b/contrib/depends/packages/native_mrustc.mk index dc9e1ff..6f5703b 100644 --- a/contrib/depends/packages/native_mrustc.mk +++ b/contrib/depends/packages/native_mrustc.mk @@ -19,7 +19,9 @@ define $(package)_preprocess_cmds sed -i.bak "s/STD_ENV_ARCH=[a-zA-Z0-9_]*/STD_ENV_ARCH=$$$$ARCH/" script-overrides/stable-1.54.0-linux/build_std.txt; \ fi && \ sed -i.bak 's/^make$$$$/make $$$$@/' build-1.54.0.sh &&\ - sed -i '' 's/^[[:space:]]*RUSTC_TARGET ?= x86_64-apple-darwin/RUSTC_TARGET ?= aarch64-apple-darwin/' run_rustc/Makefile && \ + if [ `uname -s` = "Darwin" ]; then \ + sed -i '' 's/^[[:space:]]*RUSTC_TARGET ?= x86_64-apple-darwin/RUSTC_TARGET ?= aarch64-apple-darwin/' run_rustc/Makefile; \ + fi && \ echo >> build-1.54.0.sh && \ echo make -C run_rustc >> build-1.54.0.sh endef -- cgit v1.2.3