From 8ae5a715d66dcbc598017f262089165b762f42c5 Mon Sep 17 00:00:00 2001 From: Mounir IDRASSI Date: Sun, 15 Aug 2021 00:51:06 +0200 Subject: MacOSX: First native Apple M1 support --- src/Makefile | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'src/Makefile') diff --git a/src/Makefile b/src/Makefile index 4f9796b6..e8cc2d68 100644 --- a/src/Makefile +++ b/src/Makefile @@ -274,6 +274,10 @@ ifeq "$(shell uname -s)" "Darwin" ifeq "$(CPU_ARCH)" "x64" CPU_ARCH = x86 endif + + ifeq "$(CPU_ARCH)" "arm64" + CPU_ARCH = x86 + endif CFLAGS += -msse2 CXXFLAGS += -msse2 @@ -302,14 +306,18 @@ ifeq "$(shell uname -s)" "Darwin" C_CXX_FLAGS += -gfull -arch x86_64 LFLAGS += -Wl,-dead_strip -arch x86_64 + WX_CONFIGURE_FLAGS += --without-libpng --disable-gif --disable-pcx --disable-tga --disable-iff --disable-gif --disable-svg + #----- Legacy build: we build both 32-bit and 64-bit ---- ifdef VC_LEGACY_BUILD C_CXX_FLAGS += -arch i386 LFLAGS += -arch i386 WX_CONFIGURE_FLAGS += --enable-universal_binary=i386,x86_64 else - CXXFLAGS += -std=c++11 - WX_CONFIGURE_FLAGS += --disable-universal_binary + CXXFLAGS += -std=c++11 + C_CXX_FLAGS += -arch arm64 + LFLAGS += -arch arm64 + WX_CONFIGURE_FLAGS += --enable-universal_binary=arm64,x86_64 endif WXCONFIG_CFLAGS += -gfull -- cgit v1.2.3