Skip to content

Commit 2af82f7

Browse files
committed
auto merge of #19117 : jmesmon/rust/mk-cfg-suffix, r=cmr
Right now we'll end up globbing them into the accepted targets and (ever worse) they will override the make variables of real target files because we `include`d everything in that directory. As a side effect, editors get a better hint on file types.
2 parents 81eeec0 + 8581f00 commit 2af82f7

17 files changed

+5
-2
lines changed

configure

+4-1
Original file line numberDiff line numberDiff line change
@@ -893,7 +893,10 @@ CFG_PREFIX=${CFG_PREFIX%/}
893893
CFG_MANDIR=${CFG_MANDIR%/}
894894
CFG_HOST="$(echo $CFG_HOST | tr ',' ' ')"
895895
CFG_TARGET="$(echo $CFG_TARGET | tr ',' ' ')"
896-
CFG_SUPPORTED_TARGET="$(ls ${CFG_SRC_DIR}mk/cfg)"
896+
CFG_SUPPORTED_TARGET=""
897+
for target_file in ${CFG_SRC_DIR}mk/cfg/*.mk; do
898+
CFG_SUPPORTED_TARGET="${CFG_SUPPORTED_TARGET} $(basename "$target_file" .mk)"
899+
done
897900

898901
# copy host-triples to target-triples so that hosts are a subset of targets
899902
V_TEMP=""
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

mk/platform.mk

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ $(foreach cvar,CC CXX CPP CFLAGS CXXFLAGS CPPFLAGS, \
113113

114114
CFG_RLIB_GLOB=lib$(1)-*.rlib
115115

116-
include $(wildcard $(CFG_SRC_DIR)mk/cfg/*)
116+
include $(wildcard $(CFG_SRC_DIR)mk/cfg/*.mk)
117117

118118
# The -Qunused-arguments sidesteps spurious warnings from clang
119119
define FILTER_FLAGS

0 commit comments

Comments
 (0)