# This file is part of the OpenADK project. OpenADK is copyrighted
# material, please see the LICENCE file in the top-level directory.

# CPU
config ADK_CPU_ALPHA
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_AMDFAM10
	bool
	select ADK_TARGET_CPU_WITH_VT
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_ARC700
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_ARCv2EM
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_ARM1176JZF_S
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU
	select ADK_TARGET_CPU_WITH_FPU_VFP

config ADK_CPU_ARM926EJ_S
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_ARMV8
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_ATHLON
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_ATOM
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_AVR32
	bool
	select ADK_TARGET_WITH_LT

config ADK_CPU_BFIN
	bool
	select ADK_TARGET_WITH_LT

config ADK_CPU_C6X
	bool
	select ADK_TARGET_WITH_LT

config ADK_CPU_CF
	bool

config ADK_CPU_CF_5208
	bool
	select ADK_CPU_CF
	select ADK_TARGET_WITH_LT

config ADK_CPU_CORTEX_M3
	bool
	select ADK_TARGET_WITH_LT

config ADK_CPU_CORTEX_M4
	bool
	select ADK_TARGET_WITH_LT

config ADK_CPU_CORTEX_A7
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU
	select ADK_TARGET_CPU_WITH_FPU_VFPV4

config ADK_CPU_CORTEX_A9
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU
	select ADK_TARGET_CPU_WITH_FPU_VFPV3

config ADK_CPU_CORTEX_A53
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_CORTEX_A57
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_CRIS_V10
	bool
	select ADK_TARGET_WITH_LT

config ADK_CPU_CRIS_V32
	bool
	select ADK_TARGET_WITH_LT

config ADK_CPU_GEODE
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_I486
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_I586
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_I686
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_LOONGSON2F
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_M68K
	bool
	select ADK_TARGET_WITH_LT if ADK_LINUX_UCLINUX
	select ADK_TARGET_WITH_MMU if !ADK_LINUX_UCLINUX
	select ADK_TARGET_WITH_NPTL

config ADK_CPU_MIPS32
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU
	select ADK_TARGET_CPU_WITH_FPU

config ADK_CPU_MIPS32R2
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU
	select ADK_TARGET_CPU_WITH_FPU

config ADK_CPU_MIPS64
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_MIPS64R2
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_MICROBLAZE
	bool
	select ADK_TARGET_WITH_LT if ADK_TARGET_LIBC_UCLIBC_NG
	select ADK_TARGET_WITH_MMU if !ADK_LINUX_UCLINUX
	select ADK_TARGET_WITH_NPTL

config ADK_CPU_NIOS2
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_PARISC
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_PENTIUM_M
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_PPC
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_PPC_440
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_PPC64
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_SH4
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_SPARC_V8
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_SPARC_V9
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_TILE
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_X86
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_X86_64
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_XSCALE
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

config ADK_CPU_XTENSA
	bool
	select ADK_TARGET_WITH_NPTL
	select ADK_TARGET_WITH_MMU

# CPU features
config ADK_TARGET_CPU_WITH_FPU
	bool

config ADK_TARGET_CPU_WITH_FPU_VFP
	bool
	select ADK_TARGET_CPU_WITH_FPU

config ADK_TARGET_CPU_WITH_FPU_VFPV3
	bool
	select ADK_TARGET_CPU_WITH_FPU

config ADK_TARGET_CPU_WITH_FPU_VFPV4
	bool
	select ADK_TARGET_CPU_WITH_FPU

config ADK_TARGET_CPU_WITH_VT
	bool

config ADK_TARGET_CPU_WITH_MTRR
	bool

config ADK_TARGET_CPU_WITH_MMX
	bool

config ADK_TARGET_CPU_WITH_MMXEXT
	bool

config ADK_TARGET_CPU_WITH_SSE
	bool

config ADK_TARGET_CPU_WITH_SSE2
	bool

config ADK_TARGET_CPU_WITH_SSE3
	bool

config ADK_TARGET_CPU_WITH_SSSE3
	bool

config ADK_TARGET_CPU_WITH_IWMMXT
	bool

config ADK_TARGET_CPU_WITH_NEON
	bool

config ADK_TARGET_CPU_WITH_HT
	bool

config ADK_TARGET_CPU_WITH_3DNOW
	bool

config ADK_TARGET_CPU_WITH_3DNOWEXT
	bool

config ADK_TARGET_GCC_CPU
	string
	default "440" if ADK_CPU_PPC_440
	default "5208" if ADK_CPU_CF_5208
	default "arc700" if ADK_CPU_ARC700
	default "arcv2em" if ADK_CPU_ARCv2EM
	default "arm1176jzf-s" if ADK_CPU_ARM1176JZF_S
	default "arm926ej-s" if ADK_CPU_ARM926EJ_S
	default "armv8-a" if ADK_CPU_ARMV8
	default "cortex-a7" if ADK_CPU_CORTEX_A7
	default "cortex-a9" if ADK_CPU_CORTEX_A9
	default "cortex-a53" if ADK_CPU_CORTEX_A53
	default "cortex-a57" if ADK_CPU_CORTEX_A57
	default "cortex-m3" if ADK_CPU_CORTEX_M3
	default "cortex-m4" if ADK_CPU_CORTEX_M4
	default "powerpc" if ADK_CPU_PPC
	default "powerpc64" if ADK_CPU_PPC64
	default "ultrasparc" if ADK_CPU_SPARC_V9
	default "v8" if ADK_CPU_SPARC_V8
	default "xscale" if ADK_CPU_XSCALE

config ADK_TARGET_GCC_ARCH
	string
	default "amdfam10" if ADK_CPU_AMDFAM10
	default "athlon" if ADK_CPU_ATHLON
	default "atom" if ADK_CPU_ATOM
	default "geode" if ADK_CPU_GEODE
	default "i486" if ADK_CPU_I486
	default "i586" if ADK_CPU_I586
	default "i686" if ADK_CPU_I686
	default "loongson2f" if ADK_CPU_LOONGSON2F
	default "mips32" if ADK_CPU_MIPS32
	default "mips32r2" if ADK_CPU_MIPS32R2
	default "mips64" if ADK_CPU_MIPS64
	default "mips64r2" if ADK_CPU_MIPS64R2
	default "pentium-m" if ADK_CPU_PENTIUM_M
	default "x86-64" if ADK_CPU_X86_64

config ADK_TARGET_CPU_FLAGS
	string
	default "-mcpu=v10" if ADK_CPU_CRIS_V10
	default "-mcpu=v32" if ADK_CPU_CRIS_V32
	default "-mcpu=v7.10.d" if ADK_CPU_MICROBLAZE

config ADK_TARGET_CPU_ARCH
	string
	default "aarch64" if ADK_TARGET_ARCH_AARCH64 && ADK_TARGET_LITTLE_ENDIAN
	default "alpha" if ADK_TARGET_ARCH_ALPHA
	default "arm" if ADK_TARGET_ARCH_ARM && ADK_TARGET_LITTLE_ENDIAN
	default "armeb" if ADK_TARGET_ARCH_ARM && ADK_TARGET_BIG_ENDIAN
	default "arc" if ADK_TARGET_ARCH_ARC && ADK_TARGET_LITTLE_ENDIAN
	default "arceb" if ADK_TARGET_ARCH_ARC && ADK_TARGET_BIG_ENDIAN
	default "avr32" if ADK_CPU_AVR32
	default "bfin" if ADK_CPU_BFIN
	default "c6x" if ADK_CPU_C6X
	default "cris" if ADK_CPU_CRIS_V10
	default "crisv32" if ADK_CPU_CRIS_V32
	default "i486" if ADK_CPU_I486
	default "i586" if ADK_CPU_I586
	default "i686" if ADK_CPU_I686
	default "i586" if ADK_CPU_GEODE
	default "i686" if ADK_CPU_PENTIUM_M
	default "i686" if ADK_CPU_ATOM
	default "i686" if ADK_CPU_ATHLON
	default "hppa" if ADK_TARGET_ARCH_HPPA
	default "m68k" if ADK_TARGET_ARCH_M68K
	default "microblaze" if ADK_TARGET_ARCH_MICROBLAZE && ADK_TARGET_BIG_ENDIAN
	default "microblazeel" if ADK_TARGET_ARCH_MICROBLAZE && ADK_TARGET_LITTLE_ENDIAN
	default "mips64" if ADK_TARGET_ARCH_MIPS64 && ADK_TARGET_BIG_ENDIAN
	default "mips64el" if ADK_TARGET_ARCH_MIPS64 && ADK_TARGET_LITTLE_ENDIAN
	default "mips" if ADK_TARGET_ARCH_MIPS && ADK_TARGET_BIG_ENDIAN
	default "mipsel" if ADK_TARGET_ARCH_MIPS && ADK_TARGET_LITTLE_ENDIAN
	default "nios2" if ADK_TARGET_ARCH_NIOS2
	default "ppc" if ADK_CPU_PPC
	default "ppc" if ADK_CPU_PPC_440
	default "ppc64" if ADK_CPU_PPC64
	default "sh4" if ADK_TARGET_ARCH_SH && ADK_TARGET_LITTLE_ENDIAN
	default "sh4eb" if ADK_TARGET_ARCH_SH && ADK_TARGET_BIG_ENDIAN
	default "sparc" if ADK_TARGET_ARCH_SPARC
	default "sparc64" if ADK_TARGET_ARCH_SPARC64
	default "tilegx" if ADK_CPU_TILE
	default "x86_64" if ADK_CPU_X86_64
	default "x86_64" if ADK_CPU_AMDFAM10
	default "xtensa" if ADK_TARGET_ARCH_XTENSA