Skip to content

Commit

Permalink
Honor CFLAGS_FOR_BUILD
Browse files Browse the repository at this point in the history
Signed-off-by: Alexey Neyman <stilor@att.net>
  • Loading branch information
stilor committed Jun 16, 2017
1 parent 07a3b82 commit 1e37cd5
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
4 changes: 3 additions & 1 deletion scripts/build/binutils/binutils.sh
Expand Up @@ -200,7 +200,9 @@ do_binutils_backend() {

CT_DoExecLog CFG \
CC_FOR_BUILD="${CT_BUILD}-gcc" \
CFLAGS_FOR_BUILD="${cflags_for_build}" \
CFLAGS_FOR_BUILD="${CT_CFLAGS_FOR_BUILD}" \
CXXFLAGS_FOR_BUILD="${CT_CFLAGS_FOR_BUILD}" \
LDFLAGS_FOR_BUILD="${CT_LDFLAGS_FOR_BUILD}" \
CFLAGS="${cflags}" \
CXXFLAGS="${cflags}" \
LDFLAGS="${ldflags}" \
Expand Down
2 changes: 1 addition & 1 deletion scripts/build/cc/100-gcc.sh
Expand Up @@ -547,7 +547,7 @@ do_gcc_core_backend() {
CT_DoLog DEBUG "Extra config passed: '${extra_config[*]}'"

# We may need to modify host/build CFLAGS separately below
cflags_for_build="${cflags}"
cflags_for_build="${CT_CFLAGS_FOR_BUILD}"

# Clang's default bracket-depth is 256, and building GCC
# requires somewhere between 257 and 512.
Expand Down
9 changes: 6 additions & 3 deletions scripts/build/debug/300-gdb.sh
Expand Up @@ -141,7 +141,8 @@ do_debug_gdb_build() {

CT_DoExecLog CFG \
CC_FOR_BUILD="${CT_BUILD}-gcc" \
CFLAGS_FOR_BUILD="${cflags_for_build}" \
CFLAGS_FOR_BUILD="${CT_CFLAGS_FOR_BUILD}" \
LDFLAGS_FOR_BUILD="${CT_LDFLAGS_FOR_BUILD}" \
CPP="${CPP_for_gdb}" \
CC="${CC_for_gdb}" \
CXX="${CXX_for_gdb}" \
Expand Down Expand Up @@ -261,7 +262,8 @@ do_debug_gdb_build() {

CT_DoExecLog CFG \
CC_FOR_BUILD="${CT_BUILD}-gcc" \
CFLAGS_FOR_BUILD="${cflags_for_build}" \
CFLAGS_FOR_BUILD="${CT_CFLAGS_FOR_BUILD}" \
LDFLAGS_FOR_BUILD="${CT_LDFLAGS_FOR_BUILD}" \
CPP="${CPP_for_gdb}" \
CC="${CC_for_gdb}" \
CXX="${CXX_for_gdb}" \
Expand Down Expand Up @@ -339,7 +341,8 @@ do_debug_gdb_build() {

CT_DoExecLog CFG \
CC_FOR_BUILD="${CT_BUILD}-gcc" \
CFLAGS_FOR_BUILD="${cflags_for_build}" \
CFLAGS_FOR_BUILD="${CT_CFLAGS_FOR_BUILD}" \
LDFLAGS_FOR_BUILD="${CT_LDFLAGS_FOR_BUILD}" \
CC="${CT_TARGET}-${CT_CC}" \
CPP="${CT_TARGET}-cpp" \
LD="${CT_TARGET}-ld" \
Expand Down

0 comments on commit 1e37cd5

Please sign in to comment.