forked from platformio/platformio-core
Stop build process when framework is used and board is not specified
This commit is contained in:
@ -207,9 +207,12 @@ def BuildFrameworks(env, frameworks):
|
|||||||
if not frameworks or "uploadlazy" in COMMAND_LINE_TARGETS:
|
if not frameworks or "uploadlazy" in COMMAND_LINE_TARGETS:
|
||||||
return
|
return
|
||||||
|
|
||||||
board_frameworks = []
|
if "BOARD" not in env:
|
||||||
if "BOARD" in env:
|
env.Exit(
|
||||||
board_frameworks = env.BoardConfig().get("frameworks", [])
|
"Please specify `board` in `platformio.ini` to use "
|
||||||
|
"with '%s' framework" % ", ".join(frameworks))
|
||||||
|
|
||||||
|
board_frameworks = env.BoardConfig().get("frameworks", [])
|
||||||
if frameworks == ["platformio"]:
|
if frameworks == ["platformio"]:
|
||||||
if board_frameworks:
|
if board_frameworks:
|
||||||
frameworks.insert(0, board_frameworks[0])
|
frameworks.insert(0, board_frameworks[0])
|
||||||
|
Reference in New Issue
Block a user