[no ci] Makefile: use list-configs independently (#787)

Co-authored-by: viktorxda <viktorxda@users.noreply.github.com>
pull/790/head
viktorxda 2023-05-11 13:53:19 +02:00 committed by GitHub
parent 734557b36c
commit 93fee9e401
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 16 additions and 30 deletions

View File

@ -30,21 +30,18 @@ BR_DIR := $(ROOT_DIR)/buildroot-$(BR_VER)
.PHONY: usage help clean distclean prepare install-deps all toolchain-params run-tests overlayed-rootfs-% .PHONY: usage help clean distclean prepare install-deps all toolchain-params run-tests overlayed-rootfs-%
usage help: usage help:
@printf "\n \ @printf "BR-OpenIPC usage:\n \
BR-OpenIPC usage:\n \ - make help | usage - print this help\n \
- make help | usage - print this help\n \ - make install-deps - install system dependencies\n \
- make install-deps - install system deps\n \ - make prepare - download and unpack buildroot\n \
- make prepare - download and unpack buildroot\n \ - make list-configs - show available board configurations\n \
- make list-configs - show available hardware configs list\n \ - make <DEFCONFIG> - build the targeted device, includes prepare\n \
- make BOARD=<BOARD-ID> all - build all needed for a board\n \ - make BOARD=<BOARD-ID> all - build the targeted device\n \
(toolchain, kernel and rootfs images)\n \ - make clean - cleaning before reassembly\n \
- make clean - cleaning before reassembly\n \ - make distclean - switching to the factory state\n \
- make distclean - switching to the factory state\n \ - make overlayed-rootfs-<FS-TYPE> ROOTFS_OVERLAYS=[path] - create rootfs overlay\n\n \
- make overlayed-rootfs-<FS-TYPE> ROOTFS_OVERLAYS=... - create rootfs\n \ Example:\n \
image that contains original Buildroot target dir overlayed\n \ - make overlayed-rootfs-squashfs ROOTFS_OVERLAYS=echo_server/overlay\n\n"
by some custom layers\n\n \
Example:\n \
make overlayed-rootfs-squashfs ROOTFS_OVERLAYS=./examples/echo_server/overlay\n\n"
distclean: distclean:
@rm -rf output buildroot-$(BR_VER) @rm -rf output buildroot-$(BR_VER)
@ -76,15 +73,6 @@ else
cpio rsync bc unzip file lzop cpio rsync bc unzip file lzop
endif endif
%_info:
@echo
@cat $(BR_EXT_DIR)/board/$(subst _info,,$@)/config | grep RAM_LINUX_SIZE
$(eval VENDOR := $(shell echo $@ | cut -d "_" -f 1))
$(eval FAMILY := $(shell cat $(BR_EXT_DIR)/board/$(subst _info,,$@)/config | grep FAMILY | cut -d "=" -f 2))
$(eval CHIP := $(shell echo $@ | cut -d "_" -f 3))
@cat $(BR_EXT_DIR)/board/$(FAMILY)/$(CHIP).config
buildroot-version: buildroot-version:
@echo $(BR_VER) @echo $(BR_VER)
@ -95,14 +83,12 @@ toolname:
@$(SCRIPTS_DIR)/show_toolchains.sh $(FULL_PATH) $(BR_VER) @$(SCRIPTS_DIR)/show_toolchains.sh $(FULL_PATH) $(BR_VER)
list-configs: list-configs:
ifndef BOARD @ls -1 br-ext-chip-*/configs
$(error Variable BOARD must be defined to list configs)
else
@echo @echo
@ls -1 $(BR_EXT_DIR)/configs
@echo
endif
%_defconfig: prepare
$(BOARD_MAKE) BR2_DEFCONFIG=$(ROOT_DIR)/$(shell find br-ext-chip-* -name $@) defconfig
$(BOARD_MAKE) all
# ------------------------------------------------------------------------------------------------- # -------------------------------------------------------------------------------------------------
OUT_DIR ?= $(ROOT_DIR)/output OUT_DIR ?= $(ROOT_DIR)/output