You can again specify the default board sub-directory when CONFIG_ARCH_BOARD_CUSTOM is used

This commit is contained in:
Gregory Nutt 2014-01-16 10:42:54 -06:00
parent ebc3a64e35
commit 2382af1e7b
4 changed files with 27 additions and 5 deletions

View file

@ -6476,4 +6476,7 @@
(1) it has a bad side effect in that the sub-directory setting
no longer tracks the board setting, and (2) you still can't
source the Kconfig file from the custom board directory (2014-1-16).
* Makefile.unix, Makefile.win, and configs/Kconfig: After thinking a
little harder, I re-implemented the backed-out custom configuration
feature. The new version does not have bad side-effect (1) (but stil
has bad side-effect (2)) (2014-1-16).

View file

@ -63,7 +63,12 @@ KDEFINE = ${shell $(TOPDIR)/tools/define.sh "$(CC)" __KERNEL__}
ARCH_DIR = arch/$(CONFIG_ARCH)
ARCH_SRC = $(ARCH_DIR)/src
ARCH_INC = $(ARCH_DIR)/include
BOARD_DIR = configs/$(CONFIG_ARCH_BOARD)
ifeq ($(CONFIG_ARCH_BOARD_CUSTOM),y)
BOARD_DIR = $(CONFIG_ARCH_BOARD_CUSTOM_DIR)
else
BOARD_DIR = configs/$(CONFIG_ARCH_BOARD)
endif
# Add-on directories. These may or may not be in place in the
# NuttX source tree (they must be specifically installed)

View file

@ -56,7 +56,12 @@ KDEFINE = ${shell $(TOPDIR)\tools\define.bat "$(CC)" __KERNEL__}
ARCH_DIR = arch\$(CONFIG_ARCH)
ARCH_SRC = $(ARCH_DIR)\src
ARCH_INC = $(ARCH_DIR)\include
BOARD_DIR = configs\$(CONFIG_ARCH_BOARD)
ifeq ($(CONFIG_ARCH_BOARD_CUSTOM),y)
BOARD_DIR = $(CONFIG_ARCH_BOARD_CUSTOM_DIR)
else
BOARD_DIR = configs/$(CONFIG_ARCH_BOARD)
endif
# Add-on directories. These may or may not be in place in the
# NuttX source tree (they must be specifically installed)

View file

@ -858,8 +858,18 @@ config ARCH_BOARD_CUSTOM
endchoice
config ARCH_BOARD_CUSTOM_DIR
string "Custom board directory"
depends on ARCH_BOARD_CUSTOM
---help---
If the custom board configuration is selected, then it is necessary
to also tell the build system where it can find the board directory
for the custom board. This may be either a relative path from the
toplevel NuttX directory (like "configs/myboard") or an absolute path
to some location outside of the NuttX source tree (like
"~/projects/myboard").
config ARCH_BOARD
string
default "amber" if ARCH_BOARD_AMBER
default "arduino-due" if ARCH_BOARD_ARDUINO_DUE
default "avr32dev1" if ARCH_BOARD_AVR32DEV1
@ -946,7 +956,6 @@ config ARCH_BOARD
default "zp214xpa" if ARCH_BOARD_ZP214XPA
default "zkit-arm-1769" if ARCH_BOARD_ZKITARM
default "sim" if ARCH_BOARD_SIM
default "" if ARCH_BOARD_CUSTOM
comment "Common Board Options"