| ## Copyright (C) 2020 The Android Open Source Project |
| ## |
| ## Licensed under the Apache License, Version 2.0 (the "License"); |
| ## you may not use this file except in compliance with the License. |
| ## You may obtain a copy of the License at |
| ## |
| ## http://www.apache.org/licenses/LICENSE-2.0 |
| ## |
| ## Unless required by applicable law or agreed to in writing, software |
| ## distributed under the License is distributed on an "AS IS" BASIS, |
| ## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| ## See the License for the specific language governing permissions and |
| ## limitations under the License. |
| |
| LOCAL_PATH := $(call my-dir) |
| |
| include $(CLEAR_VARS) |
| LOCAL_MODULE := kvm_guest_kernel |
| LOCAL_MODULE_CLASS := ETC |
| LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/vm |
| LOCAL_MODULE_STEM := $(LOCAL_MODULE) |
| include $(BUILD_SYSTEM)/base_rules.mk |
| $(LOCAL_BUILT_MODULE): ./vm-api/kernel/$(TARGET_ARCH)/vm_kernel |
| cp $< $@ |
| |
| include $(CLEAR_VARS) |
| LOCAL_MODULE := kvm_guest_busybox |
| LOCAL_MODULE_CLASS := ETC |
| LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/vm |
| LOCAL_MODULE_STEM := $(LOCAL_MODULE) |
| include $(BUILD_SYSTEM)/base_rules.mk |
| $(LOCAL_BUILT_MODULE): ./vm-api/busybox.img |
| cp $< $@ |
| |
| include $(CLEAR_VARS) |
| LOCAL_MODULE := kvm_guest_ramdisk |
| LOCAL_MODULE_CLASS := ETC |
| LOCAL_MODULE_PATH := $(TARGET_OUT_ETC)/vm |
| LOCAL_MODULE_STEM := $(LOCAL_MODULE) |
| include $(BUILD_SYSTEM)/base_rules.mk |
| $(LOCAL_BUILT_MODULE): ROOTFS_DIR=$(TARGET_OUT_INTERMEDIATES)/$(LOCAL_MODULE_CLASS)/$(LOCAL_MODULE)/rootfs |
| $(LOCAL_BUILT_MODULE): $(MKBOOTFS) $(HOST_OUT_EXECUTABLES)/kvm_guest_init | $(MINIGZIP) |
| $(call pretty,"VM ram disk: $@") |
| $(hide) mkdir -p $(ROOTFS_DIR) |
| $(hide) cp $(HOST_OUT_EXECUTABLES)/kvm_guest_init $(ROOTFS_DIR)/init |
| $(hide) $(MKBOOTFS) $(ROOTFS_DIR) | $(MINIGZIP) > $@ |