Skip to content

Commit

Permalink
fix NEWLIB_MULTILIB_NAMES in Makefile
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
MetaLambda authored and cmuellner committed Oct 22, 2024
1 parent a14abe3 commit 935b263
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ ifeq ($(MULTILIB_GEN),)
NEWLIB_MULTILIB_NAMES := @newlib_multilib_names@
GCC_MULTILIB_FLAGS := $(MULTILIB_FLAGS)
else
NEWLIB_MULTILIB_NAMES := $(shell echo "$(MULTILIB_GEN)" | $(SED) 's/;/\n/g' | $(SED) '/^$$/d' | $(AWK) '{split($$0,a,"-"); printf "%s-%s ", a[1],a[2]}')
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]}')
GCC_MULTILIB_FLAGS := $(MULTILIB_FLAGS) --with-multilib-generator="$(MULTILIB_GEN)"
endif
GLIBC_MULTILIB_NAMES := @glibc_multilib_names@
Expand Down

0 comments on commit 935b263

Please sign in to comment.