File tree 1 file changed +19
-0
lines changed
1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -148,6 +148,25 @@ endif
148
148
# Define COREBOOT_TOOLCHAIN_DIR based on the resolved toolchain module
149
149
COREBOOT_TOOLCHAIN_DIR := $(build)/$($(coreboot_toolchain_module)_base_dir)
150
150
151
+ # Define the coreboot configuration logic with cleanup
152
+ $(coreboot_module)_configure := \
153
+ rm -rf $(build)/$(coreboot_dir)/*; \
154
+ mkdir -p "$(build)/$(coreboot_dir)"; \
155
+ $(call install_config,$(pwd)/$(CONFIG_COREBOOT_CONFIG),$(build)/$(coreboot_dir)/.config); \
156
+ sed -i '/^CONFIG_LOCALVERSION/d' $(build)/$(coreboot_dir)/.config; \
157
+ echo 'CONFIG_LOCALVERSION=$(CONFIG_COREBOOT_LOCALVERSION)' >> $(build)/$(coreboot_dir)/.config; \
158
+ sed -i '/^CONFIG_MAINBOARD_SMBIOS_PRODUCT_NAME/d' $(build)/$(coreboot_dir)/.config; \
159
+ echo 'CONFIG_MAINBOARD_SMBIOS_PRODUCT_NAME="$(CONFIG_COREBOOT_SMBIOS_PRODUCT_NAME)"' >> $(build)/$(coreboot_dir)/.config; \
160
+ if [ ! -z "$(CONFIG_COREBOOT_SMBIOS_MANUFACTURER)" ]; then \
161
+ sed -i '/^CONFIG_MAINBOARD_SMBIOS_MANUFACTURER/d' $(build)/$(coreboot_dir)/.config; \
162
+ echo 'CONFIG_MAINBOARD_SMBIOS_MANUFACTURER="$(CONFIG_COREBOOT_SMBIOS_MANUFACTURER)"' >> $(build)/$(coreboot_dir)/.config; \
163
+ fi; \
164
+ $(MAKE) olddefconfig \
165
+ -C "$(build)/$(coreboot_base_dir)" \
166
+ obj="$(build)/$(coreboot_dir)" \
167
+ DOTCONFIG="$(build)/$(coreboot_dir)/.config" \
168
+ BUILD_TIMELESS=1
169
+
151
170
# Ensure that touching the config file will force a rebuild
152
171
$(build)/$(coreboot_dir)/.configured: $(CONFIG_COREBOOT_CONFIG) $(COREBOOT_TOOLCHAIN_DIR)/.heads-toolchain
153
172
@echo "DEBUG: Triggering coreboot configuration for $(coreboot_dir)";
You can’t perform that action at this time.
0 commit comments