mirror of
https://github.com/MarlinFirmware/Marlin.git
synced 2025-07-18 20:27:55 -06:00
Preflight checks for PlatformIO builds (#21068)
Co-authored-by: Alexander D. Kanevskiy <alexander.kanevskiy@intel.com>
This commit is contained in:
parent
a21d4c06ae
commit
bb1039d4c9
6 changed files with 69 additions and 16 deletions
|
@ -312,16 +312,6 @@ def MarlinFeatureIsEnabled(env, feature):
|
|||
|
||||
return some_on
|
||||
|
||||
#
|
||||
# Check for Configfiles in two common incorrect places
|
||||
#
|
||||
def check_configfile_locations():
|
||||
for p in [ env['PROJECT_DIR'], os.path.join(env['PROJECT_DIR'], "config") ]:
|
||||
for f in [ "Configuration.h", "Configuration_adv.h" ]:
|
||||
if os.path.isfile(os.path.join(p, f)):
|
||||
err = 'ERROR: Config files found in directory ' + str(p) + '. Please move them into the Marlin subdirectory.'
|
||||
raise SystemExit(err)
|
||||
|
||||
#
|
||||
# Add a method for other PIO scripts to query enabled features
|
||||
#
|
||||
|
@ -330,6 +320,5 @@ env.AddMethod(MarlinFeatureIsEnabled)
|
|||
#
|
||||
# Add dependencies for enabled Marlin features
|
||||
#
|
||||
check_configfile_locations()
|
||||
apply_features_config()
|
||||
force_ignore_unused_libs()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue