1# Copyright (C) 2021 The Android Open Source Project 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); 4# you may not use this file except in compliance with the License. 5# You may obtain a copy of the License at 6# 7# http://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, 11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12# See the License for the specific language governing permissions and 13# limitations under the License. 14# 15 16# Normally all build/tasks/*.mk files are included from 17# build/make/core/Makefile. Since we don't want these 18# rules to also apply to other products, check for an 19# arbitrary flag that indicates we need the rules. 20ifneq (,$(GOLDFISH_COMBINE_INITRAMFS)) 21 22# Normally, the bootloader is supposed to concatenate the Android initramfs 23# and the initramfs for the kernel modules and let the kernel combine 24# them. However, the bootloader that we're using with FVP (U-Boot) doesn't 25# support concatenation, so we implement it in the build system. 26$(OUT_DIR)/target/product/$(PRODUCT_DEVICE)/boot.img: $(OUT_DIR)/target/product/$(PRODUCT_DEVICE)/combined-ramdisk.img 27 28$(OUT_DIR)/target/product/$(PRODUCT_DEVICE)/combined-ramdisk.img: $(OUT_DIR)/target/product/$(PRODUCT_DEVICE)/ramdisk.img kernel/prebuilts/common-modules/virtual-device/$(TARGET_KERNEL_USE)/arm64/initramfs.img 29 cat $^ > $@ 30 31endif 32