Sridhar Parasuram | fedf9ac | 2015-11-03 16:20:50 -0800 | [diff] [blame] | 1 | UEFI_TOP_DIR := . |
| 2 | |
| 3 | ifndef $(BOOTLOADER_OUT) |
| 4 | BOOTLOADER_OUT := . |
| 5 | endif |
| 6 | export $(BOOTLOADER_OUT) |
| 7 | |
| 8 | BUILDDIR=$(shell pwd) |
padarshr | 8518103 | 2016-07-09 02:32:43 +0530 | [diff] [blame] | 9 | export CLANG35_AARCH64_PREFIX := $(ANDROID_BUILD_TOP)/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-$(TARGET_GCC_VERSION)/bin/aarch64-linux-android- |
Sridhar Parasuram | fedf9ac | 2015-11-03 16:20:50 -0800 | [diff] [blame] | 10 | export CLANG35_BIN := $(CLANG_BIN) |
Channagoud Kadabi | 53362e0 | 2016-06-29 18:34:12 -0700 | [diff] [blame] | 11 | ANDROID_PRODUCT_OUT := $(BOOTLOADER_OUT)/Build |
Sridhar Parasuram | fedf9ac | 2015-11-03 16:20:50 -0800 | [diff] [blame] | 12 | |
| 13 | WORKSPACE=$(BUILDDIR) |
| 14 | TARGET_TOOLS := CLANG35 |
| 15 | TARGET := DEBUG |
| 16 | BUILD_ROOT := $(ANDROID_PRODUCT_OUT)/$(TARGET)_$(TARGET_TOOLS) |
Channagoud Kadabi | 6769899 | 2016-03-02 13:04:47 -0800 | [diff] [blame] | 17 | LOAD_ADDRESS := 0X9FA00000 |
Channagoud Kadabi | 1ed4a15 | 2016-02-05 15:15:41 -0800 | [diff] [blame] | 18 | EDK_TOOLS := $(BUILDDIR)/BaseTools |
| 19 | EDK_TOOLS_BIN := $(EDK_TOOLS)/Source/C/bin |
Sridhar Parasuram | fedf9ac | 2015-11-03 16:20:50 -0800 | [diff] [blame] | 20 | ABL_FV_IMG := $(BUILD_ROOT)/FV/abl.fv |
| 21 | ABL_FV_ELF := $(BOOTLOADER_OUT)/../../abl.elf |
lijuang | 4d342f6 | 2016-09-13 15:51:26 +0800 | [diff] [blame] | 22 | SHELL:=/bin/bash |
Sridhar Parasuram | fedf9ac | 2015-11-03 16:20:50 -0800 | [diff] [blame] | 23 | |
| 24 | .PHONY: all cleanall |
| 25 | |
| 26 | all: ABL_FV_ELF |
| 27 | |
| 28 | cleanall: |
| 29 | @. ./edksetup.sh BaseTools && \ |
| 30 | build -p $(WORKSPACE)/QcomModulePkg/QcomModulePkg.dsc -a AARCH64 -t $(TARGET_TOOLS) -b $(TARGET) -j build_modulepkg.log cleanall |
| 31 | rm -rf $(WORKSPACE)/QcomModulePkg/Bin64 |
| 32 | |
Channagoud Kadabi | 1ed4a15 | 2016-02-05 15:15:41 -0800 | [diff] [blame] | 33 | EDK_TOOLS_BIN: |
Sridhar Parasuram | fedf9ac | 2015-11-03 16:20:50 -0800 | [diff] [blame] | 34 | @. ./edksetup.sh BaseTools && \ |
Channagoud Kadabi | 1ed4a15 | 2016-02-05 15:15:41 -0800 | [diff] [blame] | 35 | $(MAKE) -C $(EDK_TOOLS) -j1 |
| 36 | |
| 37 | ABL_FV_IMG: EDK_TOOLS_BIN |
| 38 | @. ./edksetup.sh BaseTools && \ |
Shivaprasad Hongal | 3860bbf | 2017-04-27 17:40:13 -0700 | [diff] [blame] | 39 | build -p $(WORKSPACE)/QcomModulePkg/QcomModulePkg.dsc -a AARCH64 -t $(TARGET_TOOLS) -b $(TARGET) -D ABL_OUT_DIR=$(ANDROID_PRODUCT_OUT) -D VERIFIED_BOOT=$(VERIFIED_BOOT) -D VERIFIED_BOOT_2=$(VERIFIED_BOOT_2) -D USER_BUILD_VARIANT=$(USER_BUILD_VARIANT) -j build_modulepkg.log $* |
Sridhar Parasuram | fedf9ac | 2015-11-03 16:20:50 -0800 | [diff] [blame] | 40 | cp $(BUILD_ROOT)/FV/FVMAIN_COMPACT.Fv $(ABL_FV_IMG) |
| 41 | |
| 42 | ABL_FV_ELF: ABL_FV_IMG |
Jeevan Shriram | 19a5381 | 2017-06-14 15:39:48 -0700 | [diff] [blame^] | 43 | python $(WORKSPACE)/QcomModulePkg/Tools/image_header.py $(ABL_FV_IMG) $(ABL_FV_ELF) $(LOAD_ADDRESS) elf 32 |