aboutsummaryrefslogtreecommitdiff
path: root/disk/Makefile
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2022-08-11 19:34:44 -0600
committerTom Rini <trini@konsulko.com>2022-09-16 11:05:00 -0400
commitfc614d2044a41ce98588f591349ac0f8c1c43ff6 (patch)
tree6241b5ed4a1ebd84165a149b1a9df80b2d359dda /disk/Makefile
parent1bbfdc575cdaf3afde6485b204d95b26ad2c5677 (diff)
downloadu-boot-fc614d2044a41ce98588f591349ac0f8c1c43ff6.zip
u-boot-fc614d2044a41ce98588f591349ac0f8c1c43ff6.tar.gz
u-boot-fc614d2044a41ce98588f591349ac0f8c1c43ff6.tar.bz2
disk: Use Makefile to omit partition drivers
At present these files have an #ifdef covering the whole file. Move the condition to the Makefile instead. Add BLK to the condition since future patches will adjust things so that HAVE_BLOCK_DEVICE is only for SPL, but the partition drivers are needed in U-Boot proper too. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'disk/Makefile')
-rw-r--r--disk/Makefile4
1 files changed, 4 insertions, 0 deletions
diff --git a/disk/Makefile b/disk/Makefile
index ec14883..458e21e 100644
--- a/disk/Makefile
+++ b/disk/Makefile
@@ -9,8 +9,12 @@ obj-$(CONFIG_$(SPL_TPL_)PARTITIONS) += part.o
ifdef CONFIG_$(SPL_TPL_)BLK
obj-$(CONFIG_$(SPL_TPL_)PARTITIONS) += disk-uclass.o
endif
+
+# Must have BLK or HAVE_BLOCK_DEVICE to support partitions
+ifneq ($(CONFIG_$(SPL_TPL_)BLK),$(CONFIG_HAVE_BLOCK_DEVICE),)
obj-$(CONFIG_$(SPL_TPL_)MAC_PARTITION) += part_mac.o
obj-$(CONFIG_$(SPL_TPL_)DOS_PARTITION) += part_dos.o
obj-$(CONFIG_$(SPL_TPL_)ISO_PARTITION) += part_iso.o
obj-$(CONFIG_$(SPL_TPL_)AMIGA_PARTITION) += part_amiga.o
obj-$(CONFIG_$(SPL_TPL_)EFI_PARTITION) += part_efi.o
+endif