Skip to content

Commit 935b263

Browse files
MetaLambdacmuellner
authored andcommitted
fix NEWLIB_MULTILIB_NAMES in Makefile
see #1513 The NEWLIB_MULTILIB_NAMES generated in makefile for MULTILIB_GEN may contain space at the end, which cause the generate_target_board script to crash Signed-off-by: Bin XIE <xiebin@zju.edu.cn>
1 parent a14abe3 commit 935b263

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Makefile.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ ifeq ($(MULTILIB_GEN),)
7474
NEWLIB_MULTILIB_NAMES := @newlib_multilib_names@
7575
GCC_MULTILIB_FLAGS := $(MULTILIB_FLAGS)
7676
else
77-
NEWLIB_MULTILIB_NAMES := $(shell echo "$(MULTILIB_GEN)" | $(SED) 's/;/\n/g' | $(SED) '/^$$/d' | $(AWK) '{split($$0,a,"-"); printf "%s-%s ", a[1],a[2]}')
77+
NEWLIB_MULTILIB_NAMES := $(shell echo "$(MULTILIB_GEN)" | $(SED) 's/;/\n/g' | $(SED) '/^$$/d' | $(AWK) '{split($$0,a,"-"); printf "%s-%s", (NR==1?a[1]:" "a[1]),a[2]}')
7878
GCC_MULTILIB_FLAGS := $(MULTILIB_FLAGS) --with-multilib-generator="$(MULTILIB_GEN)"
7979
endif
8080
GLIBC_MULTILIB_NAMES := @glibc_multilib_names@

0 commit comments

Comments
 (0)