diff options
Diffstat (limited to 'scripts/build')
-rw-r--r-- | scripts/build/arch.sh | 46 | ||||
-rw-r--r-- | scripts/build/arch/arc.sh | 15 | ||||
-rw-r--r-- | scripts/build/arch/avr.sh | 7 | ||||
-rw-r--r-- | scripts/build/arch/xtensa.sh | 11 | ||||
-rw-r--r-- | scripts/build/kernel/bare-metal.sh | 12 | ||||
-rw-r--r-- | scripts/build/kernel/linux.sh | 13 | ||||
-rw-r--r-- | scripts/build/kernel/windows.sh | 12 |
7 files changed, 61 insertions, 55 deletions
diff --git a/scripts/build/arch.sh b/scripts/build/arch.sh index de3e3c91..e7a2efe4 100644 --- a/scripts/build/arch.sh +++ b/scripts/build/arch.sh @@ -1,31 +1,36 @@ # This file provides the default implementations of arch-specific functions. # Set up the target tuple -CT_DoArchTupleValues() { - :; +CT_DoArchTupleValues() +{ + : } # Adjust the list of multilibs for the target -CT_DoArchMultilibList() { - :; +CT_DoArchMultilibList() +{ + : } # Multilib: change the target triplet according to CFLAGS # Usage: CT_DoArchGlibcAdjustTuple <variable-name> <CFLAGS> -CT_DoArchMultilibTarget() { - :; +CT_DoArchMultilibTarget() +{ + : } # Multilib: Adjust target tuple for GLIBC # Usage: CT_DoArchGlibcAdjustTuple <variable-name> -CT_DoArchGlibcAdjustTuple() { - :; +CT_DoArchGlibcAdjustTuple() +{ + : } # Multilib: Adjust configure arguments for GLIBC # Usage: CT_DoArchGlibcAdjustConfigure <configure-args-array-name> <cflags> -CT_DoArchGlibcAdjustConfigure() { - :; +CT_DoArchGlibcAdjustConfigure() +{ + : } # Helper for uClibc configurators: select the architecture @@ -41,14 +46,16 @@ CT_DoArchUClibcSelectArch() { # uClibc: Adjust configuration file according to the CT-NG configuration # Usage: CT_DoArchUClibcConfig <config-file> -CT_DoArchUClibcConfig() { +CT_DoArchUClibcConfig() +{ CT_DoLog WARN "Support for '${CT_ARCH}' is not implemented in uClibc config tweaker." CT_DoLog WARN "Exact configuration file must be provided." } # Multilib/uClibc: Adjust configuration file for given CFLAGS # Usage: CT_DoArchUClibcCflags <config-file> <cflags> -CT_DoArchUClibcCflags() { +CT_DoArchUClibcCflags() +{ local cfg="${1}" local cflags="${2}" @@ -63,21 +70,24 @@ CT_DoArchUClibcCflags() { # Multilib/uClibc: Adjust header installation path for given CFLAGS # Usage: CT_DoArchUClibcHeaderDir <path-variable> <cflags> -CT_DoArchUClibcHeaderDir() { +CT_DoArchUClibcHeaderDir() +{ # Only needed if a given architecture may select different uClibc architectures. - :; + : } # Multilib/MUSL: Adjust header installation path for given CFLAGS # Usage: CT_DoArchMUSLHeaderDir <path-variable> <cflags> -CT_DoArchMUSLHeaderDir() { +CT_DoArchMUSLHeaderDir() +{ # Only needed if a given architecture may select different MUSL architectures. - :; + : } # MUSL: Perform any final adjustments on the installed libc/headers -CT_DoArchMUSLPostInstall() { - :; +CT_DoArchMUSLPostInstall() +{ + : } # Override from the actual arch implementation as needed. diff --git a/scripts/build/arch/arc.sh b/scripts/build/arch/arc.sh index 2b48e4ba..b13ef0eb 100644 --- a/scripts/build/arch/arc.sh +++ b/scripts/build/arch/arc.sh @@ -1,23 +1,20 @@ # Compute ARC-specific values -CT_DoArchTupleValues() { +CT_DoArchTupleValues() +{ # The architecture part of the tuple: CT_TARGET_ARCH="${CT_ARCH}${CT_ARCH_SUFFIX:-${target_endian_eb}}" - - # The system part of the tuple: - case "${CT_LIBC}" in - glibc) CT_TARGET_SYS=gnu;; - uClibc) CT_TARGET_SYS=uclibc;; - esac } -CT_DoArchUClibcConfig() { +CT_DoArchUClibcConfig() +{ local cfg="${1}" CT_DoArchUClibcSelectArch "${cfg}" "arc" } -CT_DoArchUClibcCflags() { +CT_DoArchUClibcCflags() +{ local cfg="${1}" local cflags="${2}" local f diff --git a/scripts/build/arch/avr.sh b/scripts/build/arch/avr.sh index fd8c8edd..501b020b 100644 --- a/scripts/build/arch/avr.sh +++ b/scripts/build/arch/avr.sh @@ -2,11 +2,4 @@ CT_DoArchTupleValues() { CT_TARGET_ARCH="${CT_ARCH}" - case "${CT_LIBC}" in - avr-libc) - # avr-libc only seems to work with the non-canonical "avr" target. - CT_TARGET_SKIP_CONFIG_SUB=y - CT_TARGET_SYS= # CT_TARGET_SYS must be empty - ;; - esac } diff --git a/scripts/build/arch/xtensa.sh b/scripts/build/arch/xtensa.sh index 744bbb2d..d0ba6f58 100644 --- a/scripts/build/arch/xtensa.sh +++ b/scripts/build/arch/xtensa.sh @@ -1,18 +1,15 @@ # Compute Xtensa-specific values -CT_DoArchTupleValues() { +CT_DoArchTupleValues() +{ # The architecture part of the tuple: CT_TARGET_ARCH="${CT_ARCH}${CT_ARCH_SUFFIX}" CT_ARCH_ENDIAN_CFLAG="" CT_ARCH_ENDIAN_LDFLAG="" - # The system part of the tuple: - case "${CT_LIBC}" in - *glibc) CT_TARGET_SYS=gnu;; - uClibc) CT_TARGET_SYS=uclibc;; - esac } -CT_DoArchUClibcConfig() { +CT_DoArchUClibcConfig() +{ local cfg="${1}" CT_DoArchUClibcSelectArch "${cfg}" "xtensa" diff --git a/scripts/build/kernel/bare-metal.sh b/scripts/build/kernel/bare-metal.sh index 629f63fa..79c43454 100644 --- a/scripts/build/kernel/bare-metal.sh +++ b/scripts/build/kernel/bare-metal.sh @@ -2,19 +2,23 @@ # Copyright 2008 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package -CT_DoKernelTupleValues() { +CT_DoKernelTupleValues() +{ # For bare-metal, there is no kernel part in the tuple CT_TARGET_KERNEL= } -do_kernel_get() { +do_kernel_get() +{ : } -do_kernel_extract() { +do_kernel_extract() +{ : } -do_kernel_headers() { +do_kernel_headers() +{ : } diff --git a/scripts/build/kernel/linux.sh b/scripts/build/kernel/linux.sh index 5ab49182..f0987653 100644 --- a/scripts/build/kernel/linux.sh +++ b/scripts/build/kernel/linux.sh @@ -2,10 +2,9 @@ # Copyright 2007 Yann E. MORIN # Licensed under the GPL v2. See COPYING in the root of this package -CT_DoKernelTupleValues() { - if [ "${CT_ARCH_USE_MMU}" = "y" ]; then - CT_TARGET_KERNEL="linux" - else +CT_DoKernelTupleValues() +{ + if [ -z "${CT_ARCH_USE_MMU}" ]; then # Some no-mmu linux targets requires a -uclinux tuple (like m68k/cf), # while others must have a -linux tuple. Other targets # should be added here when someone starts to care about them. @@ -18,7 +17,8 @@ CT_DoKernelTupleValues() { } # Download the kernel -do_kernel_get() { +do_kernel_get() +{ CT_Fetch LINUX } @@ -42,7 +42,8 @@ do_kernel_extract() } # Install kernel headers using headers_install from kernel sources. -do_kernel_headers() { +do_kernel_headers() +{ local kernel_path local kernel_arch diff --git a/scripts/build/kernel/windows.sh b/scripts/build/kernel/windows.sh index 7d6266c1..37bc1d78 100644 --- a/scripts/build/kernel/windows.sh +++ b/scripts/build/kernel/windows.sh @@ -2,20 +2,24 @@ # Copyright 2012 Yann Diorcet # Licensed under the GPL v2. See COPYING in the root of this package -CT_DoKernelTupleValues() { +CT_DoKernelTupleValues() +{ # Even we compile for x86_64 target architecture, the target OS have to # bet mingw32 (require by gcc and mingw-w64) CT_TARGET_KERNEL="mingw32" } -do_kernel_get() { +do_kernel_get() +{ : } -do_kernel_extract() { +do_kernel_extract() +{ : } -do_kernel_headers() { +do_kernel_headers() +{ : } |