-do_build_all:
-
-build_all:
- @echo "[ $(SOURCE) ] make build_all $(COMPONENT) $(KERNEL_CONFIG) $(ARCH_CONFIG) $(TARGET)"; \
- kernel_config=$(KERNEL_CONFIG); \
- arch_config=$(ARCH_CONFIG); \
- for comp_subdir in $(COMP_SUBDIRS) $($(addprefix COMP_SUBDIRS_, $(ARCH_CONFIG))); \
- do \
- $(MKDIR) $${comp_subdir}; \
- (cd $${comp_subdir}; \
- new_component=$(firstword $(subst /, ,$(subst $(shell $(RELPATH) -d / $(SRCROOT) $(SRCROOT)),,$(addprefix $(shell $(RELPATH) -d / $(SOURCE) $(SOURCE))/, $${comp_subdir}))));\
- ${MAKE} KERNEL_CONFIG=$${kernel_config} \
- ARCH_CONFIG=$${arch_config} \
- MAKEFILES=${SOURCE}/$${comp_subdir}/Makefile \
- SOURCE=${SOURCE}$${comp_subdir}/ \
- TARGET=${OBJROOT}/$${kernel_config}_$${arch_config}/$${new_component} \
- build_all \
- ); \
- done; \
- ${MAKE} do_build_all;
-
-#
-# Build all architectures for all Configuration/Architecture options
-#
-mach_kernel: SRCROOT DSTROOT OBJROOT
- @echo "[ $(SOURCE) ] make mach_kernel"; \
- for kernel_config in $(KERNEL_CONFIGS); \
- do \
- for arch_config in $(ARCH_CONFIGS); \
- do \
- build_subdir=${OBJROOT}/$${kernel_config}_$${arch_config}; \
- $(MKDIR) $${build_subdir}; \
- (cd $${build_subdir}; \
- ${MAKE} KERNEL_CONFIG=$${kernel_config} \
- ARCH_CONFIG=$${arch_config} \
- MAKEFILES=${SOURCE}/Makefile \
- SOURCE=${SOURCE}/ \
- TARGET=$${build_subdir}/ \
- build_mach_kernel \
- ); \
- done; \
- done;
-
-#
-# Build all architectures for all Configuration/Architecture options
-#
-do_build_mach_kernel:
-
-build_mach_kernel:
- @echo "[ $(SOURCE) ] make build_mach_kernel $(COMPONENT) $(KERNEL_CONFIG) $(ARCH_CONFIG) $(TARGET)"; \
- ${MAKE} do_build_mach_kernel;
-
-#
-#
-# Install dependencies order
-#
-.ORDER: SRCROOT DSTROOT OBJROOT SYMROOT installhdrs exporthdrs all
-
-#
-# Install kernel based on RC_ARCHS for all INSTALL_TYPES
-# Install kernel header files based on RC_ARCHS
-#
-install: SRCROOT DSTROOT OBJROOT SYMROOT installhdrs all
- @echo "[ $(SOURCE) ] make install"; \
- rel_path=$(shell $(RELPATH) $(SRCROOT) $(SOURCE)); \
- for kernel_config in $(INSTALL_TYPE); \
- do \
- for arch_config in $(INSTALL_ARCHS); \
- do \
- install_subdir=${OBJROOT}/$${kernel_config}_$${arch_config}/$${rel_path}; \
- $(MKDIR) $${install_subdir}; \
- (cd $${install_subdir}; \
- new_component=$(firstword $(subst /, ,$(subst $(shell $(RELPATH) -d / $(SRCROOT) $(SRCROOT)),,$(addprefix $(shell $(RELPATH) -d / $(SOURCE) $(SOURCE))/,$${rel_path}))));\
- target_subdir=${OBJROOT}/$${kernel_config}_$${arch_config}/$${new_component}; \
- ${MAKE} KERNEL_CONFIG=$${kernel_config} \
- ARCH_CONFIG=$${arch_config} \
- MAKEFILES=${SOURCE}/Makefile \
- SOURCE=${SOURCE}/ \
- TARGET=$${target_subdir}/ \
- build_install \
- ); \
- done; \
- done;