blob: 163f2b98da637a4b7c8d9f02a043ae5f501bd358 [file] [log] [blame]
Stefan Roese5ff4c3f2005-08-15 12:31:23 +02001#
Marian Balakowiczd62379d2006-09-01 19:49:50 +02002# (C) Copyright 2006
3# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4#
Stefan Roese5ff4c3f2005-08-15 12:31:23 +02005# (C) Copyright 2005
6# Travis B. Sawyer, Sandburst Corporation, tsawyer@sandburst.com
7#
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02008# SPDX-License-Identifier: GPL-2.0+
Stefan Roese5ff4c3f2005-08-15 12:31:23 +02009#
10
11include $(TOPDIR)/config.mk
Marian Balakowiczd62379d2006-09-01 19:49:50 +020012ifneq ($(OBJTREE),$(SRCTREE))
13$(shell mkdir -p $(obj)../common)
14endif
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020015
16# TBS: add for debugging purposes
17BUILDUSER := $(shell whoami)
18FORCEBUILD := $(shell rm -f $(LIB) $(BOARD).o)
19
20CFLAGS += -DBUILDUSER='"$(BUILDUSER)"'
21# TBS: end debugging
22
23
Sebastien Carliera8d426f2010-11-05 15:48:07 +010024LIB = $(obj)lib$(BOARD).o
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020025
Dirk Eibach42b204f2013-04-25 02:40:01 +000026COBJS = $(BOARD).o ../common/flash.o ../common/sb_common.o
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020027SOBJS = init.o
28
Marian Balakowiczd62379d2006-09-01 19:49:50 +020029SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
30OBJS := $(addprefix $(obj),$(COBJS))
31SOBJS := $(addprefix $(obj),$(SOBJS))
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020032
33$(LIB): $(OBJS) $(SOBJS)
Sebastien Carliera8d426f2010-11-05 15:48:07 +010034 $(call cmd_link_o_target, $(OBJS))
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020035
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020036#########################################################################
37
Marian Balakowiczd62379d2006-09-01 19:49:50 +020038# defines $(obj).depend target
39include $(SRCTREE)/rules.mk
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020040
Marian Balakowiczd62379d2006-09-01 19:49:50 +020041sinclude $(obj).depend
Stefan Roese5ff4c3f2005-08-15 12:31:23 +020042
43#########################################################################