1
0
Fork 0

Add support for specifying BOARD in info.json (#11492)

* add support for specifying BOARD in info.json

* move BOARD from rules.mk to info.json for clueboard

* fix keyboards that do not require board

* remove out of compliance values
This commit is contained in:
Zach White 2021-01-09 20:18:47 -08:00 committed by GitHub
parent 54a8262dfe
commit eaa9106ec7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 19 additions and 9 deletions

View file

@ -462,7 +462,7 @@ def _extract_rules_mk(info_data):
"""Pull some keyboard information from existing rules.mk files
"""
rules = rules_mk(info_data['keyboard_folder'])
mcu = rules.get('MCU')
mcu = rules.get('MCU', info_data.get('processor'))
if mcu in CHIBIOS_PROCESSORS:
arm_processor_rules(info_data, rules)
@ -594,6 +594,12 @@ def arm_processor_rules(info_data, rules):
elif 'ARM_ATSAM' in rules:
info_data['platform'] = 'ARM_ATSAM'
if 'BOARD' in rules:
if 'board' in info_data:
_log_warning(info_data, 'Board is specified in both info.json and rules.mk, the rules.mk value wins.')
info_data['board'] = rules['BOARD']
return info_data