openbcm

Git mirror of https://github.com/Broadcom-Network-Switching-Software/OpenBCM
git clone git://git.finwo.net/mirror/broadcom/openbcm
Log | Files | Refs | README

Makefile (1699B)


      1 # -*- Makefile -*-
      2 # 
      3 # This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file.
      4 # 
      5 # Copyright 2007-2019 Broadcom Inc. All rights reserved.
      6 
      7 #
      8 # This make job requires the following environment variables to be set:
      9 #
     10 # SDK                - path to StrataXGS SDK root directory
     11 #
     12 # Optionally the following environment variables can be set to
     13 # override the default build server configuration:
     14 #
     15 # PPC_TOOLS_DIR      - path to build tools (if not in PATH already)
     16 # PPC_CROSS_COMPILE  - cross compile tools prefix
     17 # LINUX_INCLUDE      - path to Linux kernel include directory
     18 #
     19 
     20 SDK :=$(shell if [ -n "$$SDK" ] ; then\
     21 	echo $$SDK;\
     22 	else\
     23 	cd $(dir $(lastword $(MAKEFILE_LIST))); while /usr/bin/test ! -e RELEASE ; do \
     24 	dir=`cd ../;pwd`;			\
     25 	if [ "$$dir" = "/" ] ; then		\
     26 	   echo Cannot find SDK in $(lastword $(MAKEFILE_LIST)) 1>&2;		\
     27 	   exit 1;				\
     28 	fi ;					\
     29 	cd $$dir;				\
     30 	done ;					\
     31 	pwd;					\
     32 	fi)
     33 
     34 ifeq ($(SDK),)					
     35 $(error Please run this in a tree)		
     36 endif 				
     37 
     38 export SDK
     39 
     40 
     41 override kernel_version=2_6
     42 platform=gtr-2_6
     43 LINUX_MAKE_USER=1
     44 export LINKER_RELAX=1
     45 
     46 XMC ?= /projects/ntsw-tools/toolchains/xlp316/sdk-base
     47 TOOLS_DIR = $(XMC)/toolchains_bin/mipscross/linux/bin
     48 
     49 # Select the build environment
     50 #BUILD_PLATFORM=ELDK
     51 #BUILD_PLATFORM=WR_LINUX
     52 
     53 #Select the LINUX KERNEL VERSION
     54 #KERN_VER = 2.6.21.7
     55 #KERN_VER = 2.6.24.4
     56 #KERN_VER = 2.6.25
     57 
     58 
     59 # Select the ELDK version
     60 #ELDK_VERSION=4.1
     61 #ELDK_VERSION=4.0
     62 
     63 #Select WRS Linux version
     64 #WRS_LINUX_VERSION=2.0
     65 #WRS_LINUX_VERSION=3.0
     66 
     67 
     68 export KERN_VER
     69 export ELDK_VERSION
     70 export BUILD_PLATFORM
     71 export WRS_LINUX_VERSION
     72 
     73 include ${SDK}/make/Make.linux
     74