Makefile 1.82 KB
Newer Older
Jeffrey Lee's avatar
Jeffrey Lee committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14
# Copyright 2009 Castle Technology Ltd
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
15 16 17 18 19
# Makefile for OMAP-3 HAL
#

COMPONENT = OMAP-3 HAL
TARGET = OMAP3
20
OBJS = Top Boot Interrupts Timers CLib CLibAsm Stubs UART Debug PRCM Video USB I2C RTC SDMA TPS Audio GPIO GPMC NIC NVMemory CPUClk KbdScan SR37x SDIO KbdMatrix PAudio BMU
21
USBDIR = <Lib$Dir>.USB
22 23 24 25 26 27 28

HDRS =
CMHGFILE =
CUSTOMRES = custom
CUSTOMROM = custom
ROM_TARGET = custom
LNK_TARGET = custom
29
AIFDBG    = aif._${TARGET}
30
GPADBG    = gpa.GPA
31 32 33

include CModule

Ben Avison's avatar
Ben Avison committed
34 35
CCFLAGS += -ff -APCS 3/32bit/nofp/noswst
ASFLAGS += -APCS 3/nofp/noswst
36
ROM_LIBS += ${USBDIR}.o.MUSBDriver ${USBDIR}.o.EHCIDriver ${USBDIR}.o.USBDriver
Jeffrey Lee's avatar
Jeffrey Lee committed
37

38 39 40 41 42 43
resources:
	@${ECHO} ${COMPONENT}: no resources

rom: aof.${TARGET}
	@${ECHO} ${COMPONENT}: rom module built

Jeffrey Lee's avatar
Jeffrey Lee committed
44 45 46
_debug: ${GPADBG}
	@echo ${COMPONENT}: debug image built

47 48 49 50 51 52 53 54 55 56
install_rom: linked.${TARGET}
	${CP} linked.${TARGET} ${INSTDIR}.${TARGET} ${CPFLAGS}
	@echo ${COMPONENT}: rom module installed

aof.${TARGET}: ${ROM_OBJS_} ${ROM_LIBS} ${DIRS} ${ROM_DEPEND}
	${LD} -o $@ -aof ${ROM_OBJS_} ${ROM_LIBS}

linked.${TARGET}: aof.${TARGET}
	${LD} ${LDFLAGS} ${LDLINKFLAGS} -o $@ -bin -base 0xFC000000 aof.${TARGET}

57
${AIFDBG}: ${ROM_OBJS_} ${ROM_LIBS}
Jeffrey Lee's avatar
Jeffrey Lee committed
58
	${MKDIR} aif
59
	${LD} -aif -bin -d -o ${AIFDBG} ${ROM_OBJS_} ${ROM_LIBS}
Jeffrey Lee's avatar
Jeffrey Lee committed
60 61 62 63

${GPADBG}: ${AIFDBG}
	ToGPA -s ${AIFDBG} ${GPADBG}

64
# Dynamic dependencies: