mirror of
https://github.com/crosstool-ng/crosstool-ng.git
synced 2025-02-21 01:21:27 +00:00
cc/gcc: Remove copyheaders toggle in do_cc_core_backend, make default
Canadian Cross compile for baremetal fails with error; checking for the value of EOF... configure: error: computing EOF failed which is due to libstdc++ configure not being able to find stdio.h Having all modes of the core compiler copyheaders from CT_HEADERS_DIR (in combination with previous patch for newlib to add a do_libc_start_files function to copy into the CT_HEADERS_DIR) resolves this. Signed-off-by: David Holsgrove <david.holsgrove@xilinx.com>
This commit is contained in:
parent
234c643008
commit
af731ae904
@ -205,20 +205,16 @@ do_cc_core_backend() {
|
||||
extra_config+=("--enable-threads=no")
|
||||
extra_config+=("--disable-shared")
|
||||
extra_user_config=( "${CT_CC_CORE_EXTRA_CONFIG_ARRAY[@]}" )
|
||||
copy_headers=y # For baremetal, as there's no headers to copy,
|
||||
# we copy an empty directory. So, who cares?
|
||||
;;
|
||||
shared)
|
||||
extra_config+=("--enable-shared")
|
||||
extra_user_config=( "${CT_CC_CORE_EXTRA_CONFIG_ARRAY[@]}" )
|
||||
copy_headers=y
|
||||
;;
|
||||
baremetal)
|
||||
extra_config+=("--with-newlib")
|
||||
extra_config+=("--enable-threads=no")
|
||||
extra_config+=("--disable-shared")
|
||||
extra_user_config=( "${CT_CC_EXTRA_CONFIG_ARRAY[@]}" )
|
||||
copy_headers=n
|
||||
;;
|
||||
*)
|
||||
CT_Abort "Internal Error: 'mode' must be one of: 'static', 'shared' or 'baremetal', not '${mode:-(empty)}'"
|
||||
@ -231,10 +227,8 @@ do_cc_core_backend() {
|
||||
[ -n "${CT_TOOLCHAIN_BUGURL}" ] && extra_config+=("--with-bugurl=${CT_TOOLCHAIN_BUGURL}")
|
||||
fi
|
||||
|
||||
if [ "${copy_headers}" = "y" ]; then
|
||||
CT_DoLog DEBUG "Copying headers to install area of bootstrap gcc, so it can build libgcc2"
|
||||
CT_DoExecLog ALL cp -a "${CT_HEADERS_DIR}" "${prefix}/${CT_TARGET}/include"
|
||||
fi
|
||||
CT_DoLog DEBUG "Copying headers to install area of core C compiler"
|
||||
CT_DoExecLog ALL cp -a "${CT_HEADERS_DIR}" "${prefix}/${CT_TARGET}/include"
|
||||
|
||||
for tmp in ARCH ABI CPU TUNE FPU FLOAT; do
|
||||
eval tmp="\${CT_ARCH_WITH_${tmp}}"
|
||||
|
Loading…
x
Reference in New Issue
Block a user