]> xenbits.xensource.com Git - unikraft/unikraft.git/commitdiff
build: Adopt cross-compile prefixes for Darwin
authorSimon Kuenzer <simon@unikraft.io>
Wed, 26 Jul 2023 11:53:39 +0000 (13:53 +0200)
committerUnikraft <monkey@unikraft.io>
Fri, 11 Aug 2023 10:21:30 +0000 (10:21 +0000)
This commit adopts the preconfigured cross-compile prefixes for
Darwin (MacOS). It is assumed that the needed `gcc` compiler is installed
via `brew`.

Signed-off-by: Simon Kuenzer <simon@unikraft.io>
Reviewed-by: Alexander Jung <alex@unikraft.io>
Approved-by: Razvan Deaconescu <razvand@unikraft.io>
Tested-by: Unikraft CI <monkey@unikraft.io>
GitHub-Closes: #1034

arch/arm/arm64/Compiler.uk
arch/x86/x86_64/Compiler.uk

index 235346be50e91bab0157b76a0da2ee021ba267e9..c92a66448d65cd717c40009daed836db2bd90592 100644 (file)
@@ -1,6 +1,10 @@
 # set cross compile
 ifeq ($(call qstrip,$(CONFIG_CROSS_COMPILE)),)
+ifeq ($(HOSTOSENV),Darwin)
+       CONFIG_CROSS_COMPILE := aarch64-elf-
+else
 ifneq ($(CONFIG_UK_ARCH),$(HOSTARCH))
        CONFIG_CROSS_COMPILE := aarch64-linux-gnu-
 endif
 endif
+endif
index dbe097111dd1408e99083af320b75e54ef1320db..8d958f8858119c9cd138dcb7aa5d260e442e381b 100644 (file)
@@ -1,6 +1,10 @@
 # set cross compile
 ifeq ($(call qstrip,$(CONFIG_CROSS_COMPILE)),)
+ifeq ($(HOSTOSENV),Darwin)
+       CONFIG_CROSS_COMPILE := x86_64-elf-
+else
 ifneq ($(CONFIG_UK_ARCH),$(HOSTARCH))
        CONFIG_CROSS_COMPILE := x86_64-linux-gnu-
 endif
 endif
+endif