Skip to content

Commit 6d02273

Browse files
authored
Merge pull request #7162 from rhooper/boards-list
add boards list to make error message
2 parents e7c87a4 + 7c51201 commit 6d02273

File tree

10 files changed

+103
-289
lines changed

10 files changed

+103
-289
lines changed

ports/atmel-samd/Makefile

Lines changed: 1 addition & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -22,36 +22,7 @@
2222
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2323
# THE SOFTWARE.
2424

25-
# Select the board to build for.
26-
ifeq ($(BOARD),)
27-
$(error You must provide a BOARD parameter)
28-
else
29-
ifeq ($(wildcard boards/$(BOARD)/.),)
30-
$(error Invalid BOARD specified)
31-
endif
32-
endif
33-
34-
# If the build directory is not given, make it reflect the board name.
35-
BUILD ?= build-$(BOARD)
36-
37-
include ../../py/mkenv.mk
38-
# Board-specific
39-
include boards/$(BOARD)/mpconfigboard.mk
40-
# Port-specific
41-
include mpconfigport.mk
42-
# CircuitPython-specific
43-
include $(TOP)/py/circuitpy_mpconfig.mk
44-
45-
# qstr definitions (must come before including py.mk)
46-
QSTR_DEFS = qstrdefsport.h
47-
48-
# include py core make definitions
49-
include $(TOP)/py/py.mk
50-
51-
include $(TOP)/supervisor/supervisor.mk
52-
53-
# Include make rules and variables common across CircuitPython builds.
54-
include $(TOP)/py/circuitpy_defns.mk
25+
include ../../py/circuitpy_mkenv.mk
5526

5627
CROSS_COMPILE = arm-none-eabi-
5728

ports/broadcom/Makefile

Lines changed: 25 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,28 @@
1-
# Select the board to build for.
2-
BOARD?=raspberrypi_pi4b
3-
4-
ifeq ($(BOARD),)
5-
$(error You must provide a BOARD parameter)
6-
else
7-
ifeq ($(wildcard boards/$(BOARD)/.),)
8-
$(error Invalid BOARD "$(BOARD)" specified)
9-
endif
10-
endif
11-
12-
# If the build directory is not given, make it reflect the board name.
13-
BUILD ?= build-$(BOARD)
14-
15-
include ../../py/mkenv.mk
16-
# Board-specific
17-
include boards/$(BOARD)/mpconfigboard.mk
18-
# Port-specific
19-
include mpconfigport.mk
20-
# CircuitPython-specific
21-
include $(TOP)/py/circuitpy_mpconfig.mk
22-
23-
# qstr definitions (must come before including py.mk)
24-
QSTR_DEFS = qstrdefsport.h
25-
26-
# include py core make definitions
27-
include $(TOP)/py/py.mk
28-
29-
include $(TOP)/supervisor/supervisor.mk
30-
31-
# Include make rules and variables common across CircuitPython builds.
32-
include $(TOP)/py/circuitpy_defns.mk
1+
# This file is part of the MicroPython project, http://micropython.org/
2+
#
3+
# The MIT License (MIT)
4+
#
5+
# SPDX-FileCopyrightText: Copyright (c) 2020 Scott Shawcroft for Adafruit Industries
6+
#
7+
# Permission is hereby granted, free of charge, to any person obtaining a copy
8+
# of this software and associated documentation files (the "Software"), to deal
9+
# in the Software without restriction, including without limitation the rights
10+
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
11+
# copies of the Software, and to permit persons to whom the Software is
12+
# furnished to do so, subject to the following conditions:
13+
#
14+
# The above copyright notice and this permission notice shall be included in
15+
# all copies or substantial portions of the Software.
16+
#
17+
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
18+
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19+
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
20+
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
21+
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
22+
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
23+
# THE SOFTWARE.
24+
25+
include ../../py/circuitpy_mkenv.mk
3326

3427
ifeq ($(CHIP_VARIANT), "bcm2711")
3528
CFLAGS += -mcpu=cortex-a72 -DBCM_VERSION=2711

ports/cxd56/Makefile

Lines changed: 1 addition & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -22,39 +22,7 @@
2222
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2323
# THE SOFTWARE.
2424

25-
# Select the board to build for.
26-
ifeq ($(BOARD),)
27-
$(error You must provide a BOARD parameter)
28-
else
29-
ifeq ($(wildcard boards/$(BOARD)/.),)
30-
$(error Invalid BOARD specified)
31-
endif
32-
endif
33-
34-
# If the build directory is not given, make it reflect the board name.
35-
BUILD ?= build-$(BOARD)
36-
37-
include ../../py/mkenv.mk
38-
39-
# Board-specific
40-
include boards/$(BOARD)/mpconfigboard.mk
41-
42-
# Port-specific
43-
include mpconfigport.mk
44-
45-
# CircuitPython-specific
46-
include $(TOP)/py/circuitpy_mpconfig.mk
47-
48-
# qstr definitions (must come before including py.mk)
49-
QSTR_DEFS = qstrdefsport.h
50-
51-
# include py core make definitions
52-
include $(TOP)/py/py.mk
53-
54-
include $(TOP)/supervisor/supervisor.mk
55-
56-
# Include make rules and variables common across CircuitPython builds.
57-
include $(TOP)/py/circuitpy_defns.mk
25+
include ../../py/circuitpy_mkenv.mk
5826

5927
CROSS_COMPILE = arm-none-eabi-
6028

ports/espressif/Makefile

Lines changed: 1 addition & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -22,42 +22,7 @@
2222
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2323
# THE SOFTWARE.
2424

25-
# Select the board to build for.
26-
ifeq ($(BOARD),)
27-
$(error You must provide a BOARD parameter)
28-
else
29-
ifeq ($(wildcard boards/$(BOARD)/.),)
30-
$(error Invalid BOARD specified)
31-
endif
32-
endif
33-
34-
# If the flash PORT is not given, use the default /dev/tty.SLAB_USBtoUART.
35-
PORT ?= /dev/tty.SLAB_USBtoUART
36-
37-
# If the build directory is not given, make it reflect the board name.
38-
BUILD ?= build-$(BOARD)
39-
40-
include ../../py/mkenv.mk
41-
42-
# Board-specific
43-
include boards/$(BOARD)/mpconfigboard.mk
44-
45-
# Port-specific
46-
include mpconfigport.mk
47-
48-
# CircuitPython-specific
49-
include $(TOP)/py/circuitpy_mpconfig.mk
50-
51-
# qstr definitions (must come before including py.mk)
52-
QSTR_DEFS = qstrdefsport.h
53-
54-
# include py core make definitions
55-
include $(TOP)/py/py.mk
56-
57-
include $(TOP)/supervisor/supervisor.mk
58-
59-
# Include make rules and variables common across CircuitPython builds.
60-
include $(TOP)/py/circuitpy_defns.mk
25+
include ../../py/circuitpy_mkenv.mk
6126

6227
ifeq ($(IDF_TARGET),esp32c3)
6328
IDF_TARGET_ARCH = riscv

ports/litex/Makefile

Lines changed: 1 addition & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -22,37 +22,7 @@
2222
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2323
# THE SOFTWARE.
2424

25-
# Select the board to build for.
26-
ifeq ($(BOARD),)
27-
$(error You must provide a BOARD parameter)
28-
else
29-
ifeq ($(wildcard boards/$(BOARD)/.),)
30-
$(error Invalid BOARD specified)
31-
endif
32-
endif
33-
34-
# If the build directory is not given, make it reflect the board name.
35-
BUILD ?= build-$(BOARD)
36-
37-
include ../../py/mkenv.mk
38-
# Board-specific
39-
include boards/$(BOARD)/mpconfigboard.mk
40-
# Port-specific
41-
include mpconfigport.mk
42-
43-
# CircuitPython-specific
44-
include $(TOP)/py/circuitpy_mpconfig.mk
45-
46-
# qstr definitions (must come before including py.mk)
47-
QSTR_DEFS = qstrdefsport.h
48-
49-
# include py core make definitions
50-
include $(TOP)/py/py.mk
51-
52-
include $(TOP)/supervisor/supervisor.mk
53-
54-
# Include make rules and variables common across CircuitPython builds.
55-
include $(TOP)/py/circuitpy_defns.mk
25+
include ../../py/circuitpy_mkenv.mk
5626

5727
CROSS_COMPILE = riscv64-unknown-elf-
5828

ports/mimxrt10xx/Makefile

Lines changed: 1 addition & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -23,36 +23,7 @@
2323
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2424
# THE SOFTWARE.
2525

26-
# Select the board to build for.
27-
ifeq ($(BOARD),)
28-
$(error You must provide a BOARD parameter)
29-
else
30-
ifeq ($(wildcard boards/$(BOARD)/.),)
31-
$(error Invalid BOARD specified)
32-
endif
33-
endif
34-
35-
# If the build directory is not given, make it reflect the board name.
36-
BUILD ?= build-$(BOARD)
37-
38-
include ../../py/mkenv.mk
39-
# Board-specific
40-
include boards/$(BOARD)/mpconfigboard.mk
41-
# Port-specific
42-
include mpconfigport.mk
43-
# CircuitPython-specific
44-
include $(TOP)/py/circuitpy_mpconfig.mk
45-
46-
# qstr definitions (must come before including py.mk)
47-
QSTR_DEFS = qstrdefsport.h
48-
49-
# include py core make definitions
50-
include $(TOP)/py/py.mk
51-
52-
include $(TOP)/supervisor/supervisor.mk
53-
54-
# Include make rules and variables common across CircuitPython builds.
55-
include $(TOP)/py/circuitpy_defns.mk
26+
include ../../py/circuitpy_mkenv.mk
5627

5728
CROSS_COMPILE = arm-none-eabi-
5829

ports/nrf/Makefile

Lines changed: 1 addition & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -22,42 +22,7 @@
2222
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2323
# THE SOFTWARE.
2424

25-
# Select the board to build for.
26-
ifeq ($(BOARD),)
27-
$(info You must provide a BOARD parameter with 'BOARD=')
28-
$(info Possible values are:)
29-
$(info $(sort $(subst /.,,$(subst boards/,,$(wildcard boards/*/.)))))
30-
$(error BOARD not defined)
31-
else
32-
ifeq ($(wildcard boards/$(BOARD)/.),)
33-
$(error Invalid BOARD specified)
34-
endif
35-
endif
36-
37-
CLI_SD := $(SD)
38-
SD_LOWER = $(shell echo $(SD) | tr '[:upper:]' '[:lower:]')
39-
40-
# Build directory with SD if it's different from the default.
41-
BUILD ?= $(if $(CLI_SD),build-$(BOARD)-$(SD_LOWER),build-$(BOARD))
42-
43-
include ../../py/mkenv.mk
44-
# Board-specific
45-
include boards/$(BOARD)/mpconfigboard.mk
46-
# Port-specific
47-
include mpconfigport.mk
48-
# CircuitPython-specific
49-
include $(TOP)/py/circuitpy_mpconfig.mk
50-
51-
# qstr definitions (must come before including py.mk)
52-
QSTR_DEFS = qstrdefsport.h
53-
54-
# include py core make definitions
55-
include $(TOP)/py/py.mk
56-
57-
include $(TOP)/supervisor/supervisor.mk
58-
59-
# Include make rules and variables common across CircuitPython builds.
60-
include $(TOP)/py/circuitpy_defns.mk
25+
include ../../py/circuitpy_mkenv.mk
6126

6227
ifneq ($(SD), )
6328
include bluetooth/bluetooth_common.mk

ports/raspberrypi/Makefile

Lines changed: 1 addition & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -22,36 +22,7 @@
2222
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2323
# THE SOFTWARE.
2424

25-
# Select the board to build for.
26-
ifeq ($(BOARD),)
27-
$(error You must provide a BOARD parameter)
28-
else
29-
ifeq ($(wildcard boards/$(BOARD)/.),)
30-
$(error Invalid BOARD specified)
31-
endif
32-
endif
33-
34-
# If the build directory is not given, make it reflect the board name.
35-
BUILD ?= build-$(BOARD)
36-
37-
include ../../py/mkenv.mk
38-
# Board-specific
39-
include boards/$(BOARD)/mpconfigboard.mk
40-
# Port-specific
41-
include mpconfigport.mk
42-
# CircuitPython-specific
43-
include $(TOP)/py/circuitpy_mpconfig.mk
44-
45-
# qstr definitions (must come before including py.mk)
46-
QSTR_DEFS = qstrdefsport.h
47-
48-
# include py core make definitions
49-
include $(TOP)/py/py.mk
50-
51-
include $(TOP)/supervisor/supervisor.mk
52-
53-
# Include make rules and variables common across CircuitPython builds.
54-
include $(TOP)/py/circuitpy_defns.mk
25+
include ../../py/circuitpy_mkenv.mk
5526

5627
CROSS_COMPILE = arm-none-eabi-
5728

ports/stm/Makefile

Lines changed: 1 addition & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -23,37 +23,7 @@
2323
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
2424
# THE SOFTWARE.
2525

26-
# Select the board to build for.
27-
ifeq ($(BOARD),)
28-
$(error You must provide a BOARD parameter)
29-
else
30-
ifeq ($(wildcard boards/$(BOARD)/.),)
31-
$(error Invalid BOARD specified)
32-
endif
33-
endif
34-
35-
# If the build directory is not given, make it reflect the board name.
36-
BUILD ?= build-$(BOARD)
37-
38-
include ../../py/mkenv.mk
39-
# Board-specific
40-
include boards/$(BOARD)/mpconfigboard.mk
41-
# Port-specific
42-
include mpconfigport.mk
43-
44-
# CircuitPython-specific
45-
include $(TOP)/py/circuitpy_mpconfig.mk
46-
47-
# qstr definitions (must come before including py.mk)
48-
QSTR_DEFS = qstrdefsport.h
49-
50-
# include py core make definitions
51-
include $(TOP)/py/py.mk
52-
53-
include $(TOP)/supervisor/supervisor.mk
54-
55-
# Include make rules and variables common across CircuitPython builds.
56-
include $(TOP)/py/circuitpy_defns.mk
26+
include ../../py/circuitpy_mkenv.mk
5727

5828
CROSS_COMPILE = arm-none-eabi-
5929

0 commit comments

Comments
 (0)