b0d446dee4
As the kernel and bootloaders do not use the normal BR2_PACKAGE_* Kconfig options, their target name was not automatically added to the global TARGETS variable. Each bootloader .mk and the linux.mk had to add their own target manually to TARGETS, and the package infrastructure was making tests on non-existing Kconfig variables. This commit improves the package infrastructure so that it looks at BR2_PACKAGE_<pkg> for packages, BR2_TARGET_<pkg> for bootloaders and at the special BR2_LINUX_KERNEL for the linux package. This allows to simplify a little bit the bootloaders and linux .mk files. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
30 lines
857 B
Makefile
30 lines
857 B
Makefile
#############################################################
|
|
#
|
|
# syslinux to make target msdos/iso9660 filesystems bootable
|
|
#
|
|
#############################################################
|
|
|
|
SYSLINUX_VERSION = 3.85
|
|
SYSLINUX_SOURCE = syslinux-$(SYSLINUX_VERSION).tar.bz2
|
|
SYSLINUX_SITE = $(BR2_KERNEL_MIRROR)/linux/utils/boot/syslinux/3.xx/
|
|
|
|
SYSLINUX_INSTALL_TARGET = NO
|
|
SYSLINUX_INSTALL_IMAGES = YES
|
|
|
|
SYSLINUX_DEPENDENCIES = host-nasm
|
|
|
|
define SYSLINUX_BUILD_CMDS
|
|
$(TARGET_MAKE_ENV) $(MAKE) CC="$(HOSTCC)" AR="$(HOSTAR)" -C $(@D)
|
|
endef
|
|
|
|
SYSLINUX_IMAGES-$(BR2_TARGET_SYSLINUX_ISOLINUX) += isolinux.bin
|
|
SYSLINUX_IMAGES-$(BR2_TARGET_SYSLINUX_PXELINUX) += pxelinux.bin
|
|
|
|
define SYSLINUX_INSTALL_IMAGES_CMDS
|
|
for i in $(SYSLINUX_IMAGES-y); do \
|
|
$(INSTALL) -D -m 0755 $(@D)/core/$$i $(BINARIES_DIR)/$$i; \
|
|
done
|
|
endef
|
|
|
|
$(eval $(call GENTARGETS,boot,syslinux))
|