3 .if ${MACHINE_CPUARCH} == "aarch64" || \
4 ${MACHINE_CPUARCH} == "arm" || \
5 ${MACHINE_ARCH} == "amd64" || \
6 ${MACHINE_ARCH} == "i386" || \
7 ${MACHINE_ARCH} == "powerpc64le" || \
8 ${MACHINE_CPUARCH} == "riscv"
9 TARGET_ENDIANNESS= 1234
12 .elif ${MACHINE_ARCH} == "powerpc" || \
13 ${MACHINE_ARCH} == "powerpc64" || \
14 ${MACHINE_ARCH} == "powerpcspe"
15 TARGET_ENDIANNESS= 4321
18 .elif ${.MAKE.OS} == "FreeBSD"
19 .error Don't know the endian of this architecture
22 # During bootstrapping on !FreeBSD OSes, we need to define some value. Short of
23 # having an exhaustive list for all variants of Linux and MacOS we simply do not
24 # set TARGET_ENDIANNESS and poison the other variables. They should be unused
25 # during the bootstrap phases (apart from one place that's adequately protected
26 # in bsd.compiler.mk) where we're building the bootstrap tools.
28 CAP_MKDB_ENDIAN= -B # Poisoned value, invalid flags for both cap_mkdb
29 LOCALEDEF_ENDIAN= -B # and localedef.