VirtualBox

source: vbox/trunk/src/VBox/Devices/EFI/FirmwareNew/BaseTools/Source/C/GNUmakefile@ 80721

Last change on this file since 80721 was 80721, checked in by vboxsync, 5 years ago

Devices/EFI/FirmwareNew: Start upgrade process to edk2-stable201908 (compiles on Windows and works to some extent), bugref:4643

  • Property svn:eol-style set to native
File size: 2.0 KB
Line 
1## @file
2# GNU/Linux makefile for C tools build.
3#
4# Copyright (c) 2007 - 2017, Intel Corporation. All rights reserved.<BR>
5#
6# SPDX-License-Identifier: BSD-2-Clause-Patent
7#
8
9ifndef HOST_ARCH
10 #
11 # If HOST_ARCH is not defined, then we use 'uname -m' to attempt
12 # try to figure out the appropriate HOST_ARCH.
13 #
14 uname_m = $(shell uname -m)
15 $(info Attempting to detect HOST_ARCH from 'uname -m': $(uname_m))
16 ifneq (,$(strip $(filter $(uname_m), x86_64 amd64)))
17 HOST_ARCH=X64
18 endif
19 ifeq ($(patsubst i%86,IA32,$(uname_m)),IA32)
20 HOST_ARCH=IA32
21 endif
22 ifneq (,$(findstring aarch64,$(uname_m)))
23 HOST_ARCH=AARCH64
24 else ifneq (,$(findstring arm64,$(uname_m)))
25 HOST_ARCH=AARCH64
26 else ifneq (,$(findstring arm,$(uname_m)))
27 HOST_ARCH=ARM
28 endif
29 ifndef HOST_ARCH
30 $(info Could not detected HOST_ARCH from uname results)
31 $(error HOST_ARCH is not defined!)
32 endif
33 $(info Detected HOST_ARCH of $(HOST_ARCH) using uname.)
34endif
35
36export HOST_ARCH
37
38MAKEROOT = .
39
40include Makefiles/header.makefile
41
42all: makerootdir subdirs
43 @echo Finished building BaseTools C Tools with HOST_ARCH=$(HOST_ARCH)
44
45LIBRARIES = Common
46VFRAUTOGEN = VfrCompile/VfrLexer.h
47APPLICATIONS = \
48 BrotliCompress \
49 VfrCompile \
50 EfiRom \
51 GenFfs \
52 GenFv \
53 GenFw \
54 GenSec \
55 GenCrc32 \
56 LzmaCompress \
57 Split \
58 TianoCompress \
59 VolInfo \
60 DevicePath
61
62SUBDIRS := $(LIBRARIES) $(APPLICATIONS)
63
64$(LIBRARIES): $(MAKEROOT)/libs
65$(APPLICATIONS): $(LIBRARIES) $(MAKEROOT)/bin $(VFRAUTOGEN)
66
67.PHONY: outputdirs
68makerootdir:
69 -mkdir -p $(MAKEROOT)
70
71.PHONY: subdirs $(SUBDIRS)
72subdirs: $(SUBDIRS)
73$(SUBDIRS):
74 $(MAKE) -C $@
75
76.PHONY: $(patsubst %,%-clean,$(sort $(SUBDIRS)))
77$(patsubst %,%-clean,$(sort $(SUBDIRS))):
78 -$(MAKE) -C $(@:-clean=) clean
79
80$(VFRAUTOGEN): VfrCompile/VfrSyntax.g
81 $(MAKE) -C VfrCompile VfrLexer.h
82
83clean: $(patsubst %,%-clean,$(sort $(SUBDIRS)))
84
85clean: localClean
86
87localClean:
88 rm -f $(MAKEROOT)/bin/*
89 -rmdir $(MAKEROOT)/libs $(MAKEROOT)/bin
90
91include Makefiles/footer.makefile
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette