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

Side by Side Diff: Makefile

Issue 6257018: Import firmware compiler flags (Closed) Base URL: ssh://git@gitrw.chromium.org:9222/vboot_reference.git@master
Patch Set: reorder CFLAGS assignments Created 9 years, 11 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 export FIRMWARE_CONFIG_PATH
6 7
7 export CC ?= gcc 8 export CC ?= gcc
8 export CXX ?= g++ 9 export CXX ?= g++
9 ifeq ($(FIRMWARE_ARCH),) 10 export CFLAGS
10 export CFLAGS = -Wall -Werror -DCHROMEOS_ENVIRONMENT 11
11 else 12 # Include compiler flags if provided.
12 export CFLAGS = -Wall -Werror 13 # The CC and CFLAGS should not be overridden hereafter.
14 ifneq ($(FIRMWARE_CONFIG_PATH),)
15 include $(FIRMWARE_CONFIG_PATH)
13 endif 16 endif
14 17
18 # Provides default optimization level if not set by FIRMWARE_CONFIG_PATH
15 ifeq (${DEBUG},) 19 ifeq (${DEBUG},)
16 CFLAGS += -O3 20 CFLAGS ?= -O3
17 else 21 else
18 CFLAGS += -O0 -g -DVBOOT_DEBUG 22 CFLAGS ?= -O0
23 endif
24
25 ifeq ($(FIRMWARE_ARCH),)
26 CFLAGS += -Wall -Werror -DCHROMEOS_ENVIRONMENT
27 else
28 CFLAGS += -Wall -Werror
29 endif
30
31 ifneq (${DEBUG},)
32 CFLAGS += -g -DVBOOT_DEBUG
19 endif 33 endif
20 34
21 ifeq (${DISABLE_NDEBUG},) 35 ifeq (${DISABLE_NDEBUG},)
22 CFLAGS += -DNDEBUG 36 CFLAGS += -DNDEBUG
23 endif 37 endif
24 38
25 export TOP = $(shell pwd) 39 export TOP = $(shell pwd)
26 export FWDIR=$(TOP)/firmware 40 export FWDIR=$(TOP)/firmware
27 export HOSTDIR=$(TOP)/host 41 export HOSTDIR=$(TOP)/host
28 ifeq ($(FIRMWARE_ARCH),) 42 ifeq ($(FIRMWARE_ARCH),)
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 74
61 install: 75 install:
62 $(MAKE) -C utility install 76 $(MAKE) -C utility install
63 $(MAKE) -C cgpt install 77 $(MAKE) -C cgpt install
64 78
65 runtests: 79 runtests:
66 $(MAKE) -C tests runtests 80 $(MAKE) -C tests runtests
67 81
68 rbtest: 82 rbtest:
69 $(MAKE) -C tests rbtest 83 $(MAKE) -C tests rbtest
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