X-Git-Url: https://rtime.felk.cvut.cz/gitweb/l4.git/blobdiff_plain/c06638d2e57a3230381daf1ccce3cf0dfd0eaa92..003b628647705666de261350195da72a38f2c4d2:/l4/mk/Kconfig diff --git a/l4/mk/Kconfig b/l4/mk/Kconfig index e600c033d..040bf3224 100644 --- a/l4/mk/Kconfig +++ b/l4/mk/Kconfig @@ -4,32 +4,22 @@ config KERNELVERSION string option env="KERNELVERSION" +config ARCH_ENABLE_STACK_PROTECTOR + bool + choice prompt "Target Architecture" default BUILD_ARCH_x86 help Specify for which processor architecture you want to build. -config BUILD_ARCH_x86 - bool "X86-32 architecture" - -config BUILD_ARCH_amd64 - bool "AMD64 architecture" - -config BUILD_ARCH_arm - bool "ARM architecture" - -config BUILD_ARCH_ppc32 - bool "PowerPC 32 architecture (EXPERIMENTAL!)" +# ARCH_CHOICE endchoice config BUILD_ARCH string - default "x86" if BUILD_ARCH_x86 - default "arm" if BUILD_ARCH_arm - default "amd64" if BUILD_ARCH_amd64 - default "ppc32" if BUILD_ARCH_ppc32 +# ARCH_NAME # currently we have nothing for abi linux, so just do not offer this option #choice @@ -52,342 +42,50 @@ config BUILD_ABI default "l4f" if BUILD_ABI_l4f default "linux" if BUILD_ABI_linux -if BUILD_ARCH_x86 || BUILD_ARCH_amd64 +# PF_INCLUDE choice - prompt "CPU variant" - -config CPU_X86_GENERIC - bool "generic CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_586 - bool "586 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PENTIUM - bool "Pentium type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PENTIUMMMX - bool "Pentium with MMX type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PENTIUMPRO - bool "Pentium Pro type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_686 - bool "686 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PENTIUM2 - bool "Pentium2 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PENTIUM3 - bool "Pentium3 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PENTIUMM - bool "Pentium-M type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PENTIUM4 - bool "Pentium4 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_PRESCOTT - bool "Pentium4 Prescott type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_NOCONA - bool "Pentium Nocona type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_CORE2 - bool "Core2 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_K6 - bool "K6 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_K7 - bool "K7 type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_ATHLON4 - bool "Athlon type CPU" - depends on BUILD_ARCH_x86 - -config CPU_X86_K8 - bool "K8 type CPU" - depends on BUILD_ARCH_x86 || BUILD_ARCH_amd64 - -config CPU_X86_K10 - bool "K10/Barcelona type CPU" - depends on BUILD_ARCH_x86 || BUILD_ARCH_amd64 - -config CPU_X86_OPTERON - bool "Opteron type CPU" - depends on BUILD_ARCH_x86 || BUILD_ARCH_amd64 - - - -endchoice - - -config CPU - string - default "generic" if CPU_X86_GENERIC - default "586" if CPU_X86_586 - default "pentium" if CPU_X86_PENTIUM - default "pentiummmx" if CPU_X86_PENTIUMMMX - default "pentiumpro" if CPU_X86_PENTIUMPRO - default "686" if CPU_X86_686 - default "pentium2" if CPU_X86_PENTIUM2 - default "pentium3" if CPU_X86_PENTIUM3 - default "pentiumm" if CPU_X86_PENTIUMM - default "pentium4" if CPU_X86_PENTIUM4 - default "prescott" if CPU_X86_PRESCOTT - default "core2" if CPU_X86_CORE2 - default "nocona" if CPU_X86_NOCONA - default "K6" if CPU_X86_K6 - default "K7" if CPU_X86_K7 - default "athlon4" if CPU_X86_ATHLON4 - default "K8" if CPU_X86_K8 - default "amdfam10" if CPU_X86_K10 - default "opteron" if CPU_X86_OPTERON -endif - + prompt "Platform Selection" -if BUILD_ARCH_arm +INSERT_PLATFORMS -choice - prompt "CPU variant" - -config CPU_ARM_ARMV4 - bool "ARMv4 type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV4T - bool "ARMv4T type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV5 - bool "ARMv5 type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV5T - bool "ARMv5T type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV5TE - bool "ARMv5TE type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV6 - bool "ARMv6 type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV6T2 - bool "ARMv6t2 type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV6ZK - bool "ARMv6zk type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV7A - bool "ARMv7A type CPU" - depends on BUILD_ARCH_arm - -config CPU_ARM_ARMV7R - bool "ARMv7R type CPU" - depends on BUILD_ARCH_arm - -endchoice - -config CPU - string - default "armv4" if CPU_ARM_ARMV4 - default "armv4t" if CPU_ARM_ARMV4T - default "armv5" if CPU_ARM_ARMV5 - default "armv5t" if CPU_ARM_ARMV5T - default "armv5te" if CPU_ARM_ARMV5TE - default "armv6" if CPU_ARM_ARMV6 - default "armv6t2" if CPU_ARM_ARMV6T2 - default "armv6zk" if CPU_ARM_ARMV6ZK - default "armv7-a" if CPU_ARM_ARMV7A - default "armv7-r" if CPU_ARM_ARMV7R - -config CPU_ARMV6KPLUS - bool - default y if CPU_ARM_ARMV6ZK || CPU_ARM_ARMV7A || CPU_ARM_ARMV7R - -config CPU_ARMV6PLUS - bool - default y if CPU_ARM_ARMV6 || CPU_ARM_ARMV6T2 || CPU_ARMV6KPLUS - -menu "Platform" - -choice - prompt "ARM Platform" - -config PLATFORM_ARM_integrator - bool "ARM Integrator" - -config PLATFORM_ARM_rv - bool "ARM Realview" - -config PLATFORM_ARM_imx21 - bool "Freescale i.MX21" - -config PLATFORM_ARM_omap3evm - bool "TI OMAP3EVM" - -config PLATFORM_ARM_beagleboard - bool "Beagleboard" - -config PLATFORM_ARM_custom +config PLATFORM_TYPE_custom bool "Custom platform" + help + Define your own platform, alternatively define the following + in conf/platforms/yourname.conf: + PLATFORM_RAM_BASE = 0 + PLATFORM_RAM_SIZE_MB = 64 -endchoice - -if PLATFORM_ARM_integrator - -config ARM_PLATFORM_TYPE - string - default "integrator" - -config RAM_BASE - hex - default 0x0 - -config RAM_SIZE_MB - int - default 256 - -endif - -if PLATFORM_ARM_rv - -config ARM_PLATFORM_TYPE - string - default "rv" - -config RAM_BASE - hex - default 0x0 - -config RAM_SIZE_MB - int - default 256 - -endif - -if PLATFORM_ARM_imx21 - -config ARM_PLATFORM_TYPE - string - default "imx21" - -config RAM_BASE - hex - default 0xc0000000 - -config RAM_SIZE_MB - int - default 64 -endif - -if PLATFORM_ARM_omap3evm - -config ARM_PLATFORM_TYPE - string - default "omap3evm" - -config RAM_BASE - hex - default 0x80000000 - -config RAM_SIZE_MB - int - default 128 -endif - -if PLATFORM_ARM_beagleboard - -config ARM_PLATFORM_TYPE - string - default "beagleboard" - -config RAM_BASE - hex - default 0x80000000 -config RAM_SIZE_MB - int - default 128 -endif +endchoice -if PLATFORM_ARM_custom +if PLATFORM_TYPE_custom +menu "Custom Platform Definition" -config ARM_PLATFORM_TYPE +config PLATFORM_TYPE string "Name of your platform" - depends on BUILD_ARCH_arm -config RAM_BASE +config PLATFORM_RAM_BASE hex "Start of RAM" - depends on BUILD_ARCH_arm default 0x0 help Hexadecimal physical address where RAM memory starts on the platform. -config RAM_SIZE_MB +config PLATFORM_RAM_SIZE_MB int "RAM-Memory available on the platform in MB" - depends on BUILD_ARCH_arm default 128 -endif - -endmenu +config PLATFORM_UART_NR + int "Select UART to use" + default 0 +endmenu # Custom platform endif - - -if BUILD_ARCH_ppc32 - -config CPU - string "CPU variant" - default "603e" - -menu "Platform" - -choice - prompt "Platform" - -config PLATFORM_PPC_mpc5200 - bool "MPC52xx" - -endchoice - -if PLATFORM_PPC_mpc5200 - -config PPC_PLATFORM_TYPE - string - default "mpc5200" -endif - -endmenu - -endif - - +INSERT_PLATFORM_TYPES config USE_DROPS_STDDIR def_bool n @@ -409,13 +107,6 @@ config BID_COLORED_PHASES menu "Building" -#menu "Compilers and Tools" -#config BIDc_USE_SPECIAL_CC -# bool "Use special C-Compilers" -#if BIDc_USE_SPECIAL_CC -#endif -#endmenu - config YACC string default "yacc" @@ -457,7 +148,6 @@ config INT_LD_NAME config BID_STRIP_PROGS bool "Strip binaries on install" - default n help If enabled, binaries will be stripped on installation into $(L4DIR)/bin or $(DROPS_STDDIR)/bin. If you want to load them with @@ -468,19 +158,51 @@ config BID_STRIP_PROGS config BID_GCC_OMIT_FP bool "GCC: Omit Frame-pointers" - default n + default y help If enabled, gcc will be passed the '-fomit-frame-pointer' cmdline option, adding an additional register to the register set for the generated code. Programs will be faster, but backtraces cannot be done, seriously hindering debugging. - If unsure, say 'N'. + If unsure, say 'Y'. + +config BID_GCC_ENABLE_STACK_PROTECTOR + bool "GCC: enable stack protector" + default y if ARCH_ENABLE_STACK_PROTECTOR + help + If enabled, support for the gcc stack protector will be enabled. + The stack protector uses stack canaries to detect stack smashing + attacks (see "man gcc" for details). In L4Re the stack protector is + enabled only for packages that are linked against the full uclibc. + Enabling this feature will add some overhead, but increase security. + If unsure, say 'Y'. + +choice + prompt "GCC: Enable stack protector" + depends on BID_GCC_ENABLE_STACK_PROTECTOR + default BID_GCC_STACK_PROTECTOR + +config BID_GCC_STACK_PROTECTOR_ALL + bool "on all functions" + help + If enabled, '-fstack-protector-all' flag is used for gcc. This + option adds significant overhead, as the stack canary is checked on + every function return. See "man gcc" for details. + +config BID_GCC_STACK_PROTECTOR + bool "exclusively for functions with vulnerable objects" + help + If enabled, '-fstack-protector' flag is passed to gcc. If this + flag is set, gcc will add stack canaries to vulnerable functions, such as + functions that call "alloca", and functions with buffers larger than 8 + bytes. + +endchoice config BID_GENERATE_MAPFILE bool #"Generate Map-files for binaries" - default n help Enabling this option will generate map-files together with the binaries. This might be handy for debugging purposes. See ld(1) @@ -490,7 +212,6 @@ config BID_GENERATE_MAPFILE config BID_BUILD_DOC bool "Build doc directories" - default n help Say Y if you also want to build the doc directories. @@ -501,12 +222,11 @@ config RELEASE_MODE Say N. - -config LABEL - string "Configuration label" +config MAKECONFS_ADD + string "Additional Makeconf files" help - Name for the configuration. The build system will also try to - include a file Makeconf.