Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(598)

Side by Side Diff: Makefile

Issue 6820018: Add default arch to fix compiling outside emake (Closed) Base URL: ssh://gitrw.chromium.org:9222/vboot_reference.git@master
Patch Set: Created 9 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 1 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 export FIRMWARE_ARCH 5 export FIRMWARE_ARCH
6 6
7 export CC ?= gcc 7 export CC ?= gcc
8 export CXX ?= g++ 8 export CXX ?= g++
9 export CFLAGS = -Wall -Werror 9 export CFLAGS = -Wall -Werror
10 10
11 ifeq (${DEBUG},) 11 ifeq (${DEBUG},)
12 CFLAGS += -O3 12 CFLAGS += -O3
13 else 13 else
14 CFLAGS += -O0 -g 14 CFLAGS += -O0 -g
15 endif 15 endif
16 16
17 # Override CC and CFLAGS only if FIRMWARE_CONFIG_PATH is not empty, but we 17 # Override CC and CFLAGS only if FIRMWARE_CONFIG_PATH is not empty, but we
18 # wish to preserve -D flags (so move all -D flags after this). 18 # wish to preserve -D flags (so move all -D flags after this).
19 ifneq (${FIRMWARE_CONFIG_PATH},) 19 ifneq (${FIRMWARE_CONFIG_PATH},)
20 include ${FIRMWARE_CONFIG_PATH} 20 include ${FIRMWARE_CONFIG_PATH}
21 endif 21 endif
22 22
23 # Fix compiling directly on host (outside of emake)
24 ifeq ($(ARCH),)
25 export ARCH=amd64
26 endif
27
23 ifeq ($(FIRMWARE_ARCH),) 28 ifeq ($(FIRMWARE_ARCH),)
24 CFLAGS += -DCHROMEOS_ENVIRONMENT 29 CFLAGS += -DCHROMEOS_ENVIRONMENT
25 endif 30 endif
26 31
27 ifneq (${DEBUG},) 32 ifneq (${DEBUG},)
28 CFLAGS += -DVBOOT_DEBUG 33 CFLAGS += -DVBOOT_DEBUG
29 endif 34 endif
30 35
31 ifeq (${DISABLE_NDEBUG},) 36 ifeq (${DISABLE_NDEBUG},)
32 CFLAGS += -DNDEBUG 37 CFLAGS += -DNDEBUG
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 $(MAKE) -C cgpt install 78 $(MAKE) -C cgpt install
74 79
75 runtests: 80 runtests:
76 $(MAKE) -C tests runtests 81 $(MAKE) -C tests runtests
77 82
78 rbtest: 83 rbtest:
79 $(MAKE) -C tests rbtest 84 $(MAKE) -C tests rbtest
80 85
81 runbmptests: 86 runbmptests:
82 $(MAKE) -C tests runbmptests 87 $(MAKE) -C tests runbmptests
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698