blob: a706d3cc70f5a5a7ae614b6aa659c97b72979212 [file] [log] [blame]
wdenk0c8959d2002-08-14 08:04:29 +00001#
Marian Balakowiczd62379d2006-09-01 19:49:50 +02002# (C) Copyright 2000-2006
wdenk0c8959d2002-08-14 08:04:29 +00003# Wolfgang Denk, DENX Software Engineering, wd@denx.de.
4#
Wolfgang Denkd79de1d2013-07-08 09:37:19 +02005# SPDX-License-Identifier: GPL-2.0+
wdenk0c8959d2002-08-14 08:04:29 +00006#
7
Kyle Moffett78d58de2011-02-23 06:40:38 +00008## Build a couple of necessary functions into a private libgcc
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +09009## if the user asked for it
Kyle Moffett78d58de2011-02-23 06:40:38 +000010ifdef USE_PRIVATE_LIBGCC
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090011lib-y += _ashldi3.o
12lib-y += _ashrdi3.o
13lib-y += _lshrdi3.o
Kyle Moffett78d58de2011-02-23 06:40:38 +000014endif
15
Scott Wood7c810902012-09-20 16:35:21 -050016MINIMAL=
17
18ifdef CONFIG_SPL_BUILD
19ifdef CONFIG_SPL_INIT_MINIMAL
20MINIMAL=y
21endif
22endif
23
24ifdef MINIMAL
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090025obj-y += cache.o time.o
26obj-y += ticks.o
Scott Wood7c810902012-09-20 16:35:21 -050027else
28
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090029obj-y += ppcstring.o
Scott Wood7c810902012-09-20 16:35:21 -050030
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090031obj-y += ppccache.o
32obj-y += ticks.o
33obj-y += reloc.o
wdenk0c8959d2002-08-14 08:04:29 +000034
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090035obj-$(CONFIG_BAT_RW) += bat_rw.o
Stefan Roese50b5ac02012-08-16 17:53:18 +020036ifndef CONFIG_SPL_BUILD
Simon Glassfa6945f2013-03-11 06:50:01 +000037ifndef CONFIG_SYS_GENERIC_BOARD
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090038obj-y += board.o
Stefan Roese50b5ac02012-08-16 17:53:18 +020039endif
Simon Glassfa6945f2013-03-11 06:50:01 +000040endif
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090041obj-$(CONFIG_CMD_BOOTM) += bootm.o
42obj-y += cache.o
43obj-y += extable.o
44obj-y += interrupts.o
45obj-$(CONFIG_CMD_KGDB) += kgdb.o
46obj-$(CONFIG_CMD_IDE) += ide.o
47obj-y += time.o
wdenk0c8959d2002-08-14 08:04:29 +000048
Stefan Roese50b5ac02012-08-16 17:53:18 +020049# Don't include the MPC5xxx special memcpy into the
50# SPL U-Boot image. memcpy is used in the SPL NOR
51# flash driver. And we need the real, fast memcpy
52# here. We have no problems with unaligned access.
53ifndef CONFIG_SPL_BUILD
Wolfgang Denk85aa2c42010-06-29 01:33:35 +020054# Workaround for local bus unaligned access problems
55# on MPC512x and MPC5200
56ifdef CONFIG_MPC512X
57$(obj)ppcstring.o: AFLAGS += -Dmemcpy=__memcpy
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090058obj-y += memcpy_mpc5200.o
Wolfgang Denk85aa2c42010-06-29 01:33:35 +020059endif
Wolfgang Denk16126092010-06-21 22:29:59 +020060ifdef CONFIG_MPC5200
61$(obj)ppcstring.o: AFLAGS += -Dmemcpy=__memcpy
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090062obj-y += memcpy_mpc5200.o
Wolfgang Denk16126092010-06-21 22:29:59 +020063endif
Stefan Roese50b5ac02012-08-16 17:53:18 +020064endif
Wolfgang Denk16126092010-06-21 22:29:59 +020065
Scott Wood7c810902012-09-20 16:35:21 -050066endif # not minimal
67
Stefan Roeseec90d342012-08-23 08:34:21 +020068ifdef CONFIG_SPL_BUILD
Masahiro Yamada4fbb29d2013-10-17 17:35:04 +090069obj-$(CONFIG_SPL_FRAMEWORK) += spl.o
Stefan Roeseec90d342012-08-23 08:34:21 +020070endif