kopia lustrzana https://github.com/espressif/esp-idf
49 wiersze
1.9 KiB
Makefile
49 wiersze
1.9 KiB
Makefile
|
#
|
||
|
# eFuse Manager ganeretes header file.
|
||
|
#
|
||
|
# .PHONY: efuse_table efuse_custom_table efuse_common_table efuse_test_table show_efuse_table
|
||
|
|
||
|
GEN_EFUSE_TABLE := $(PYTHON) $(COMPONENT_PATH)/efuse_table_gen.py
|
||
|
|
||
|
efuse_table: efuse_custom_table
|
||
|
|
||
|
###################
|
||
|
# Make common files esp_efuse_table.c and include/esp_efuse_table.h files.
|
||
|
# The generated files are used in the bootloader and application space.
|
||
|
# To generate new *.c/*.h files run the command manually "make efuse_common_table".
|
||
|
SOC_NAME := $(IDF_TARGET)
|
||
|
EFUSE_COMMON_TABLE_CSV_PATH := $(COMPONENT_PATH)/$(SOC_NAME)/esp_efuse_table.csv
|
||
|
efuse_common_table:
|
||
|
$(GEN_EFUSE_TABLE) $(EFUSE_COMMON_TABLE_CSV_PATH)
|
||
|
|
||
|
###################
|
||
|
# Make custom files
|
||
|
# Changes in esp_efuse_custom_table.csv file lead to regeneration of esp_efuse_custom_table.c and include/esp_efuse_custom_table.h files.
|
||
|
# The generated files are used only in the application.
|
||
|
ifdef IS_BOOTLOADER_BUILD
|
||
|
efuse_custom_table:
|
||
|
else
|
||
|
|
||
|
ifdef CONFIG_EFUSE_CUSTOM_TABLE
|
||
|
# Path to CSV file is relative to project path for custom CSV files.
|
||
|
EFUSE_CUSTOM_TABLE_CSV_PATH := $(call dequote,$(abspath $(call dequote, $(PROJECT_PATH))/$(call dequote,$(CONFIG_EFUSE_CUSTOM_TABLE_FILENAME))))
|
||
|
EFUSE_CUSTOM_TABLE_OUT_PATH := $(call dequote,$(abspath $(call dequote, $(BUILD_DIR_BASE))/$(call dequote,$(CONFIG_EFUSE_CUSTOM_TABLE_FILENAME))))
|
||
|
efuse_custom_table: $(EFUSE_CUSTOM_TABLE_OUT_PATH:.csv=.o)
|
||
|
|
||
|
$(EFUSE_CUSTOM_TABLE_OUT_PATH:.csv=.o): $(EFUSE_CUSTOM_TABLE_CSV_PATH)
|
||
|
@echo "$(EFUSE_CUSTOM_TABLE_OUT_PATH)"
|
||
|
@echo "$(EFUSE_CUSTOM_TABLE_CSV_PATH)"
|
||
|
$(GEN_EFUSE_TABLE) $(EFUSE_COMMON_TABLE_CSV_PATH) $(EFUSE_CUSTOM_TABLE_CSV_PATH)
|
||
|
|
||
|
else
|
||
|
efuse_custom_table:
|
||
|
endif
|
||
|
|
||
|
endif
|
||
|
|
||
|
###################
|
||
|
# Generates files for unit test. This command is run manually.
|
||
|
EFUSE_TEST_TABLE_CSV_PATH := $(COMPONENT_PATH)/test/esp_efuse_test_table.csv
|
||
|
efuse_test_table:
|
||
|
$(GEN_EFUSE_TABLE) $(EFUSE_TEST_TABLE_CSV_PATH)
|