Browse Source

Retire BACKEND stuff

... it is possible to just not set it in the configuration, why force
it? It just increases the complexity in Kconfig.

Signed-off-by: Alexey Neyman <stilor@att.net>
dev-linux
Alexey Neyman 6 years ago
parent
commit
2f286ce5ab
  1. 26
      config/backend.in
  2. 1
      config/binutils/binutils.in
  3. 1
      config/config.in
  4. 1
      config/debug/duma.in
  5. 1
      config/debug/gdb.in.native
  6. 2
      config/debug/ltrace.in
  7. 2
      config/debug/strace.in
  8. 19
      config/global/build-behave.in
  9. 1
      config/global/ct-behave.in
  10. 14
      config/global/paths.in
  11. 4
      config/toolchain.in
  12. 5
      kconfig/kconfig.mk
  13. 52
      maintainer/gen-kconfig.sh

26
config/backend.in

@ -1,26 +0,0 @@
# Options specific to crosstool-NG acting as a backend
config IS_A_BACKEND
string
option env="CT_IS_A_BACKEND"
config BACKEND
bool
depends on OBSOLETE
default y if IS_A_BACKEND = "y" || IS_A_BACKEND = "Y"
if BACKEND
config BACKEND_ARCH
string
option env="CT_BACKEND_ARCH"
config BACKEND_KERNEL
string
option env="CT_BACKEND_KERNEL"
config BACKEND_LIBC
string
option env="CT_BACKEND_LIBC"
endif #if BACKEND

1
config/binutils/binutils.in

@ -314,7 +314,6 @@ config BINUTILS_FOR_TARGET
bool
prompt "binutils libraries for the target"
depends on ! BARE_METAL
depends on ! BACKEND
help
Some utilities may need binutils libraries to be available on
the target, eg. oprofile.

1
config/config.in

@ -1,5 +1,4 @@
source "config/configure.in"
source "config/backend.in"
source "config/global.in"
source "config/target.in"
source "config/toolchain.in"

1
config/debug/duma.in

@ -1,6 +1,5 @@
# D.U.M.A. - Detect Unintended Memory Access - Memory checker
## depends on ! BACKEND
## depends on ! BARE_METAL
## help D.U.M.A. - Detect Unintended Memory Access

1
config/debug/gdb.in.native

@ -4,7 +4,6 @@ config GDB_NATIVE
bool
prompt "Native gdb"
depends on ! BARE_METAL
depends on ! BACKEND
select EXPAT_TARGET
select NCURSES_TARGET
help

2
config/debug/ltrace.in

@ -1,7 +1,5 @@
# ltrace
## depends on ! BACKEND
##
## select LIBELF_TARGET
##
## help ltrace is a program that simply runs the specified command until it exits.

2
config/debug/strace.in

@ -1,7 +1,5 @@
# strace
## depends on ! BACKEND
choice
bool
prompt "strace version"

19
config/global/build-behave.in

@ -2,12 +2,9 @@
comment "Build behavior"
comment "Build options hiden"
depends on BACKEND
config PARALLEL_JOBS
int
prompt "Number of parallel jobs" if ! BACKEND
prompt "Number of parallel jobs"
default 0
help
Number of jobs make will be allowed to run concurently.
@ -20,7 +17,7 @@ config PARALLEL_JOBS
config LOAD
string
prompt "Maximum allowed load" if ! BACKEND
prompt "Maximum allowed load"
default ""
help
Specifies that no new jobs should be started if there are others jobs
@ -33,7 +30,7 @@ config LOAD
config USE_PIPES
bool
prompt "Use -pipe" if ! BACKEND
prompt "Use -pipe"
default y
help
Use gcc's option -pipe to use pipes rather than temp files when building
@ -83,7 +80,6 @@ choice
bool
prompt "Shell to use as CONFIG_SHELL"
default CONFIG_SHELL_BASH
depends on ! BACKEND
config CONFIG_SHELL_SH
bool
@ -141,13 +137,10 @@ config CONFIG_SHELL_CUSTOM
endchoice
# Do not put this into the choice above, because the choice
# is not available in BACKEND-mode, while we do want this to
# be set even in BACKEND-mode.
config CONFIG_SHELL_CUSTOM_PATH
string
prompt "Path to custom shell" if ! BACKEND
depends on CONFIG_SHELL_CUSTOM || BACKEND
prompt "Path to custom shell"
depends on CONFIG_SHELL_CUSTOM
default "/bin/sh"
# Ditto.
@ -157,4 +150,4 @@ config CONFIG_SHELL
default "/bin/sh" if CONFIG_SHELL_SH
default "/bin/ash" if CONFIG_SHELL_ASH
default "${bash}" if CONFIG_SHELL_BASH
default CONFIG_SHELL_CUSTOM_PATH if CONFIG_SHELL_CUSTOM || BACKEND
default CONFIG_SHELL_CUSTOM_PATH if CONFIG_SHELL_CUSTOM

1
config/global/ct-behave.in

@ -63,7 +63,6 @@ config ALLOW_BUILD_AS_ROOT_SURE
config DEBUG_CT
bool
prompt "Debug crosstool-NG"
depends on ! BACKEND
help
Say 'y' here to get some options regarding debugging crosstool-NG.

14
config/global/paths.in

@ -4,7 +4,7 @@ comment "Paths"
config LOCAL_TARBALLS_DIR
string
prompt "Local tarballs directory" if ! BACKEND
prompt "Local tarballs directory"
default "${HOME}/src"
help
If you have previously downloaded the tarballs, enter the PATH where
@ -12,8 +12,8 @@ config LOCAL_TARBALLS_DIR
config SAVE_TARBALLS
bool
prompt "Save new tarballs" if ! BACKEND
depends on LOCAL_TARBALLS_DIR != "" || BACKEND
prompt "Save new tarballs"
depends on LOCAL_TARBALLS_DIR != ""
default y
help
If you say 'y' here, new downloaded tarballs will be saved in the
@ -21,7 +21,7 @@ config SAVE_TARBALLS
config WORK_DIR
string
prompt "Working directory" if ! BACKEND
prompt "Working directory"
default "${CT_TOP_DIR}/.build"
help
Set this to the directory where all build actions will be done.
@ -46,7 +46,7 @@ config BUILD_TOP_DIR
config PREFIX_DIR
string
prompt "Prefix directory" if ! BACKEND
prompt "Prefix directory"
default "${CT_PREFIX:-${HOME}/x-tools}/${CT_HOST:+HOST-${CT_HOST}/}${CT_TARGET}"
help
This is the path the toolchain will run from.
@ -55,7 +55,6 @@ config RM_RF_PREFIX_DIR
bool
prompt "| Remove the prefix dir prior to building"
default y
depends on !BACKEND
help
If you say 'y' here, then PREFIX_DIR (above) will be eradicated
prior to the toolchain is built.
@ -69,9 +68,6 @@ config RM_RF_PREFIX_DIR
it into a directory with pre-install, unrelated programs, it would be
damageable to remove that directory. In this case, you may want to
say 'n' here.
Note that when acting as a backend, this option is not available, and
is forced to 'n'.
config REMOVE_DOCS
bool

4
config/toolchain.in

@ -20,7 +20,7 @@ config USE_SYSROOT
config SYSROOT_NAME
string
prompt "sysroot directory name" if ! BACKEND
prompt "sysroot directory name"
depends on USE_SYSROOT
default "sysroot"
help
@ -33,7 +33,7 @@ config SYSROOT_NAME
config SYSROOT_DIR_PREFIX
string
prompt "sysroot prefix dir (READ HELP)" if ! BACKEND
prompt "sysroot prefix dir (READ HELP)"
depends on USE_SYSROOT
default ""
help

5
kconfig/kconfig.mk

@ -8,11 +8,6 @@
# Top file of crosstool-NG configuration
export KCONFIG_TOP = $(CT_LIB_DIR)/config/config.in
export CT_IS_A_BACKEND:=$(CT_IS_A_BACKEND)
export CT_BACKEND_ARCH:=$(CT_BACKEND_ARCH)
export CT_BACKEND_KERNEL:=$(CT_BACKEND_KERNEL)
export CT_BACKEND_LIBC:=$(CT_BACKEND_LIBC)
# We need CONF for savedefconfig in scripts/saveSample.sh
export CONF := $(CT_LIB_DIR)/kconfig/conf
MCONF := $(CT_LIB_DIR)/kconfig/mconf

52
maintainer/gen-kconfig.sh

@ -10,12 +10,10 @@ grep=${GREP:-grep}
#
# Usage:
# generate a choice:
# gen_choice <out-file> <label> <config-prefix> <base-dir> \
# <conditionals> entry [entry...]
# gen_choice <out-file> <label> <config-prefix> <base-dir>
#
# generate a menuconfig:
# gen_menu <out-file> <label> <config-prefix> <base-dir> \
# entry [entry...]
# gen_menu <out-file> <label> <config-prefix> <base-dir>
#
# where:
# out-file
@ -35,18 +33,6 @@ grep=${GREP:-grep}
# base directory containing config files
# eg. config/arch, config/kernel...
#
# conditionals (valid only for choice)
# generate backend conditionals if Y/y, don't if anything else
# if 'Y' (or 'y'), a dependency on the backen mode will be added
# to each entry
#
# entry [entry...]
# a list of entry/ies toadd to the choice/menuconfig
# eg.:
# arm mips sh x86...
# linux cygwin mingw32 solaris...
# ...
#
# Helper: find the base names of all *.in files in a given directory
get_components() {
@ -66,7 +52,6 @@ gen_choice() {
local label="${2}"
local cfg_prefix="${3}"
local base_dir="${4}"
local cond="${5}"
local file entry _entry
# Generate the part-1
@ -84,9 +69,6 @@ gen_choice() {
printf 'config %s_%s\n' "${cfg_prefix}" "${_entry}"
printf ' bool\n'
printf ' prompt "%s"\n' "${entry}"
if [ "${cond}" = "Y" -o "${cond}" = "y" ]; then
printf ' depends on %s_%s_AVAILABLE\n' "${cfg_prefix}" "${_entry}"
fi
"${sed}" -r -e '/^## depends on /!d; s/^## / /;' ${file} 2>/dev/null
"${sed}" -r -e '/^## select /!d; s/^## / /;' ${file} 2>/dev/null
if "${grep}" -E '^## help' ${file} >/dev/null 2>&1; then
@ -97,21 +79,19 @@ gen_choice() {
done
printf 'endchoice\n'
printf '\n'
printf 'config %s\n' "${cfg_prefix}"
for entry in `get_components ${base_dir}`; do
file="${base_dir}/${entry}.in"
_entry=$(printf '%s\n' "${entry}" |"${sed}" -r -s -e 's/[-.+]/_/g;')
printf '\n'
if [ "${cond}" = "Y" -o "${cond}" = "y" ]; then
printf 'config %s_%s_AVAILABLE\n' "${cfg_prefix}" "${_entry}"
printf ' bool\n'
printf ' default y if'
printf ' BACKEND_%s = "%s"' "${cfg_prefix}" "${entry}"
printf ' || BACKEND_%s = ""' "${cfg_prefix}"
printf ' || ! BACKEND\n'
fi
printf 'if %s_%s\n' "${cfg_prefix}" "${_entry}"
printf 'config %s\n' "${cfg_prefix}"
printf ' default "%s" if %s_%s\n' "${entry}" "${cfg_prefix}" "${_entry}"
done
printf '\n'
for entry in `get_components ${base_dir}`; do
file="${base_dir}/${entry}.in"
_entry=$(printf '%s\n' "${entry}" |"${sed}" -r -s -e 's/[-.+]/_/g;')
printf 'if %s_%s\n' "${cfg_prefix}" "${_entry}"
printf 'source "%s"\n' "${file}"
printf 'endif\n'
done
@ -171,10 +151,10 @@ gen_menu() {
}
mkdir -p config/gen
gen_choice config/gen/arch.in "Target Architecture" "ARCH" "config/arch" "Y"
gen_choice config/gen/kernel.in "Target OS" "KERNEL" "config/kernel" "Y"
gen_choice config/gen/cc.in "Compiler" "CC" "config/cc" "N"
gen_choice config/gen/binutils.in "Binutils" "BINUTILS" "config/binutils" "N"
gen_choice config/gen/libc.in "C library" "LIBC" "config/libc" "Y"
gen_choice config/gen/arch.in "Target Architecture" "ARCH" "config/arch"
gen_choice config/gen/kernel.in "Target OS" "KERNEL" "config/kernel"
gen_choice config/gen/cc.in "Compiler" "CC" "config/cc"
gen_choice config/gen/binutils.in "Binutils" "BINUTILS" "config/binutils"
gen_choice config/gen/libc.in "C library" "LIBC" "config/libc"
gen_menu config/gen/debug.in "Debug facilities" "DEBUG" "config/debug"
gen_menu config/gen/companion_tools.in "Companion tools" "COMP_TOOLS" "config/companion_tools"

Loading…
Cancel
Save