clib: Tell gcc to compile for a base i386 target

Only benefits Linux targets; Windows is still lower bound to 686-cmov by MinGW's crt0.
This commit is contained in:
RichardG867
2024-10-26 16:39:05 -03:00
parent aba2c775bf
commit aef2d14bec

View File

@@ -16,7 +16,14 @@
#
VPATH = . ../clib
CC ?= "gcc"
CC ?= "gcc"
ifneq "$(shell $(CC) -dumpmachine | grep -w i.86)" ""
CFLAGS += -march=i386
else
ifneq "$(shell $(CC) -dumpmachine | grep -w x86_64)" ""
CFLAGS += -march=x86-64
endif
endif
all: $(DEST)