Makefile.LE
资源名称:bcm4702.rar [点击查看]
上传用户:yuanda199
上传日期:2022-06-26
资源大小:412k
文件大小:5k
源码类别:
VxWorks
开发平台:
C/C++
- # Makefile - make rules for systems/mbz/bcm4702
- #
- # modification history
- # --------------------
- # --------------------
- # 01f,21oct02,jmb new TOD chip, BRINGUP flag for LED printing
- # 01e,17sep02,jmb added -DMBZ flag to TFFS build to activate XOR 3
- # 01d,10sep02,jmb TFFS build mods
- # 01c,06sep02,jmb add PCI shared interrupt handler
- # 01b,10aug02,jmb add MBZ define for xmodem build (for TOD BSP dependencies)
- # 01a,10aug02,jmb created by merging IDT and BMW Makefiles and using build flags
- # from HNBU Makefile
- #
- # DESCRIPTION
- # This file contains rules for building VxWorks for the BCM 4702.
- #
- # This is UNPUBLISHED PROPRIETARY SOURCE CODE of Broadcom Corporation;
- # the contents of this file may not be disclosed to third parties, copied or
- # duplicated in any form, in whole or in part, without the prior written
- # permission of Broadcom Corporation.
- #
- ##################################################################
- CPU = MIPS32
- TOOL = sfgnule
- TGT_DIR=$(WIND_BASE)/target
- include $(TGT_DIR)/h/make/defs.bsp
- include $(TGT_DIR)/h/make/make.$(CPU)$(TOOL)
- include $(TGT_DIR)/h/make/defs.$(WIND_HOST_TYPE)
- CONFIG_ALL=$(SRC_DIR)/all
- DRV_DIR=../../../drv
- ## Only redefine make definitions below this point, or your definitions will
- ## be overwritten by the makefile stubs above.
- # Add some options to CFLAGS for drivers and platform
- CFLAGS += -DBROADCOM_BSP -DVXWORKS
- ifdef ROBODV
- CFLAGS += -DROBO
- else
- CFLAGS += -DBRINGUP -DMBZ
- endif
- TARGET_DIR = bcm4702
- VENDOR = Broadcom
- BOARD = Model-1
- #EXTRA_DEFINE =-DCPU_VAR=RC32364 -DBROADCOM_BSP -DTARGETOS_vxWorks -Dvxworks
- CFLAGS += -DCPU_VAR=RC32364 -DTARGETOS_vxWorks -Dvxworks # -DIL_BIGENDIAN=1
- ##################################################################
- ## Only redefine make definitions below this point, or your
- ## definitions will be overwritten by the makefile stubs above.
- ##################################################################
- ##################################################################
- # The constants ROM_TEXT_ADRS, ROM_SIZE, RAM_LOW_ADRS and
- # RAM_HIGH_ADRS are defined in config.h and MakeSkel.
- # All definitions for these constants must be identical.
- ##################################################################
- ROM_TEXT_ADRS = bfc00000 # ROM entry address
- ROM_SIZE = 00100000 # number of bytes of ROM space
- RAM_LOW_ADRS = 80100000 # RAM text/data address
- RAM_HIGH_ADRS = 80c10000
- # XModem driver, fix flags!
- XMODEM_FLAGS = $(CFLAGS) -DMBZ
- XMODEM_SRC_DIR = $(DRV_DIR)/xmodem
- XMODEM_OBJS = xmodem/xmodem.o xmodem/getput.o xmodem/misc.o
- xmodem/send.o xmodem/receive.o xmodem/batch.o xmodem/rtcTime.o
- xmodem/%.o : $(XMODEM_SRC_DIR)/%.c
- mkdir -p xmodem
- $(CC) -I$(XMODEM_SRC_DIR) $(XMODEM_FLAGS) -c $< -o $@
- # M-Systems TFFS (DiskOnChip) Driver Support Libs
- TFFS_SUB_DIR = ./tffs
- TFFS_SRC_DIR = $(DRV_DIR)/tffs
- TFFS_OBJS = tffs/blockdev.o tffs/docsoc.o tffs/fatfilt.o
- tffs/flflash.o tffs/flsocket.o tffs/mdocplus.o
- tffs/diskonc.o tffs/docsys.o tffs/flbase.o
- tffs/flioctl.o tffs/flsysvxw.o tffs/nftllite.o
- tffs/doc2exb.o tffs/docsysp.o tffs/flcustom.o
- tffs/flmtl.o tffs/fltl.o tffs/protectp.o
- tffs/docbdk.o tffs/dosformt.o tffs/fldrvvxw.o
- tffs/flsim.o tffs/inftl.o tffs/reedsol.o
- tffs/if_bcm47xx.o
- TFFS_CFLAGS = $(CFLAGS) -DMBZ
- tffs/%.o : $(TFFS_SRC_DIR)/%.c
- mkdir -p ./tffs
- @ $(RM) $@
- $(CC) -I${TFFS_SRC_DIR} $(CFLAGS) $(TFFS_CFLAGS) -c $< -o $@
- # Uncomment these next lines to build TFFS if you have the sources.
- # Otherwise, it is assumed tffs/libTFFS.a already exists.
- tffs/libTFFS.a: $(TFFS_OBJS)
- $(AR) crus $@ $(TFFS_OBJS)
- bsplib_clean:
- $(RM) xmodem/*.o
- $(RM) tffs/*.o
- # Add driver objects to MACH_EXTRA for building bootrom and ram image
- MACH_EXTRA = srecLoad.o ns16550SioLE.o
- cacheLib.o cacheALib.o pciConfigLib.o pciIntLib.o
- sysSerial.o et_vx.o etc.o etc47xx.o vx_osl.o hnddma.o
- sbutils.o bcmutils.o m48t59y.o ds1743.o
- flash29l160DrvLib.o flash28f320DrvLib.o
- flashDrvLib.o flashFsLib.o
- ftpXfer2.o
- tffs/libTFFS.a
- $(XMODEM_OBJS)
- $(WRS_OBJS)
- ifdef ROBODV
- MACH_EXTRA += robotxrx.c
- endif
- ##################################################################
- ## Only redefine make definitions above this point, or the expansion of
- ## makefile target dependencies may be incorrect.
- ##################################################################
- include $(TGT_DIR)/h/make/rules.bsp
- include $(TGT_DIR)/h/make/rules.$(WIND_HOST_TYPE)
- HEXBIN=$(BIN_DIR)/$(OBJCPY)$(TOOLENV) -I srec -O binary
- SWAP=$(PERL) ${SDK}/tools/swap.pl
- bootrom_swap.hex:
- ${HEXBIN} bootrom.hex bootrom.bin
- ${CP} bootrom.bin bootrom_swap.bin
- ${BINHEX} -I binary bootrom_swap.bin bootrom.hex
- ${CP} ${SRC_DIR}/bootrom.hex ../bootrom.hex
- rm bootrom.bin bootrom_swap.bin