Files
OpenCellular/Makefile
Randall Spangler bc4c1b4eb9 Separate utility build for build and host utils
Build is the system doing the build (e.g. 64-bit linux) and host is the
target platform on top of the ec (e.g. 32-bit Chromium OS).

Necessary to get ectool properly compiling for Chromium OS.

Signed-off-by: Randall Spangler <rspangler@chromium.org>

BUG=none
TEST=make && file build/bds/util/ectool; ectool should be a 32-bit binary

Change-Id: I50eba4c164ece236646a7c6087b1b86769beeb28
2011-12-08 10:55:27 -08:00

34 lines
917 B
Makefile

# Copyright (c) 2011 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
#
# Embedded Controller firmware build system
#
BOARD ?= bds
PROJECT?=ec
# output directory for build objects
out?=build/$(BOARD)
# Get build configuration from sub-directories
include board/$(BOARD)/build.mk
include chip/$(CHIP)/build.mk
include common/build.mk
include test/build.mk
include util/build.mk
objs_from_dir=$(foreach obj,$(2), $(out)/$(1)/$(obj))
# Get all sources to build
all-objs=$(call objs_from_dir,chip/$(CHIP),$(chip-objs))
all-objs+=$(call objs_from_dir,board/$(BOARD),$(board-objs))
all-objs+=$(call objs_from_dir,common,$(common-objs))
all-objs+=$(call objs_from_dir,test,$($(PROJECT)-objs))
dirs=chip/$(CHIP) board/$(BOARD) common test util
includes=include $(dirs)
include Makefile.toolchain
include Makefile.rules