Optional M42/M226; Add more features filters (#19664)

This commit is contained in:
Scott Lahteine 2020-10-09 16:42:23 -05:00 committed by GitHub
parent 631457ffea
commit 0988af453c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 111 additions and 78 deletions

View file

@ -39,6 +39,12 @@ def parse_pkg_uri(spec):
FEATURE_CONFIG = {}
def add_to_feat_cnf(feature, flines):
try:
feat = FEATURE_CONFIG[feature]
except:
FEATURE_CONFIG[feature] = {}
feat = FEATURE_CONFIG[feature]
atoms = re.sub(',\\s*', '\n', flines).strip().split('\n')
for dep in atoms:
@ -238,7 +244,7 @@ def load_marlin_features():
else:
cmd += ['-D' + s]
cmd += ['-D__MARLIN_PREBUILD__ -w -dM -E -x c++ buildroot/share/PlatformIO/scripts/common-dependencies.h']
cmd += ['-D__MARLIN_DEPS__ -w -dM -E -x c++ buildroot/share/PlatformIO/scripts/common-dependencies.h']
cmd = ' '.join(cmd)
blab(cmd)
define_list = subprocess.check_output(cmd, shell=True).splitlines()