diff options
author | Alexey Neyman <stilor@att.net> | 2019-02-20 08:46:29 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-20 08:46:29 (GMT) |
commit | 9627a041d25e56de06c4eab0ac4af72975b08113 (patch) | |
tree | 03298bac0fd9ddd09ba38ea385f4ad8f709ed490 /scripts/build | |
parent | 7d621cd831e4fb015fa151437051192135337006 (diff) | |
parent | 8088c6ef4733d0b9fff9cd538c7f2c745434f149 (diff) |
Merge pull request #1143 from stilor/rc2-fixes-2
RC2 fixes, part 2
Diffstat (limited to 'scripts/build')
-rw-r--r-- | scripts/build/cc/gcc.sh | 5 | ||||
-rw-r--r-- | scripts/build/libc/uClibc.sh | 13 |
2 files changed, 16 insertions, 2 deletions
diff --git a/scripts/build/cc/gcc.sh b/scripts/build/cc/gcc.sh index 9ba5982..ce7fea4 100644 --- a/scripts/build/cc/gcc.sh +++ b/scripts/build/cc/gcc.sh @@ -542,9 +542,10 @@ do_gcc_core_backend() { CT_DoLog DEBUG "Extra config passed: '${extra_config[*]}'" - # We may need to modify host/build CFLAGS separately below + # We may need to modify host/build/target CFLAGS separately below. Note + # that ${cflags} may refer either to build or host CFLAGS; they are provided + # by the caller. cflags_for_build="${CT_CFLAGS_FOR_BUILD}" - cflags="${CT_CFLAGS_FOR_HOST}" cflags_for_target="${CT_TARGET_CFLAGS}" # Clang's default bracket-depth is 256, and building GCC diff --git a/scripts/build/libc/uClibc.sh b/scripts/build/libc/uClibc.sh index 5ea5c58..fbee4aa 100644 --- a/scripts/build/libc/uClibc.sh +++ b/scripts/build/libc/uClibc.sh @@ -237,6 +237,15 @@ manage_uClibc_config() CT_KconfigEnableOption "ARCH_USE_MMU" "${dst}" else CT_KconfigDisableOption "ARCH_USE_MMU" "${dst}" + CT_KconfigDisableOption "UCLIBC_FORMAT_FDPIC" "${dst}" + CT_KconfigDisableOption "UCLIBC_FORMAT_FLAT" "${dst}" + CT_KconfigDisableOption "UCLIBC_FORMAT_SHARED_FLAT" "${dst}" + case "${CT_ARCH_BINFMT_FLAT},${CT_ARCH_BINFMT_FDPIC},${CT_SHARED_LIBS}" in + y,,y) CT_KconfigEnableOption "UCLIBC_FORMAT_SHARED_FLAT" "${dst}";; + y,,) CT_KconfigEnableOption "UCLIBC_FORMAT_FLAT" "${dst}";; + ,y,*) CT_KconfigEnableOption "UCLIBC_FORMAT_FDPIC" "${dst}";; + *) CT_Abort "Unsupported binary format";; + esac fi if [ "${CT_SHARED_LIBS}" = "y" ]; then @@ -404,6 +413,10 @@ manage_uClibc_config() # Now allow architecture to tweak as it wants CT_DoArchUClibcConfig "${dst}" CT_DoArchUClibcCflags "${dst}" "${flags}" + + # Preserve the config we created (before uclibc's `make olddefconfig` + # overrides anything). + CT_DoExecLog ALL cp "${dst}" "${dst}.created-by-ct-ng" } uClibc_post_cc() |