-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathMake.tools
181 lines (169 loc) · 5.45 KB
/
Make.tools
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
# $Id: Make.tools 1.14.44.1 Broadcom SDK $
# $Copyright: Copyright 2011 Broadcom Corporation.
# This program is the proprietary software of Broadcom Corporation
# and/or its licensors, and may only be used, duplicated, modified
# or distributed pursuant to the terms and conditions of a separate,
# written license agreement executed between you and Broadcom
# (an "Authorized License"). Except as set forth in an Authorized
# License, Broadcom grants no license (express or implied), right
# to use, or waiver of any kind with respect to the Software, and
# Broadcom expressly reserves all rights in and to the Software
# and all intellectual property rights therein. IF YOU HAVE
# NO AUTHORIZED LICENSE, THEN YOU HAVE NO RIGHT TO USE THIS SOFTWARE
# IN ANY WAY, AND SHOULD IMMEDIATELY NOTIFY BROADCOM AND DISCONTINUE
# ALL USE OF THE SOFTWARE.
#
# Except as expressly set forth in the Authorized License,
#
# 1. This program, including its structure, sequence and organization,
# constitutes the valuable trade secrets of Broadcom, and you shall use
# all reasonable efforts to protect the confidentiality thereof,
# and to use this information only in connection with your use of
# Broadcom integrated circuit products.
#
# 2. TO THE MAXIMUM EXTENT PERMITTED BY LAW, THE SOFTWARE IS
# PROVIDED "AS IS" AND WITH ALL FAULTS AND BROADCOM MAKES NO PROMISES,
# REPRESENTATIONS OR WARRANTIES, EITHER EXPRESS, IMPLIED, STATUTORY,
# OR OTHERWISE, WITH RESPECT TO THE SOFTWARE. BROADCOM SPECIFICALLY
# DISCLAIMS ANY AND ALL IMPLIED WARRANTIES OF TITLE, MERCHANTABILITY,
# NONINFRINGEMENT, FITNESS FOR A PARTICULAR PURPOSE, LACK OF VIRUSES,
# ACCURACY OR COMPLETENESS, QUIET ENJOYMENT, QUIET POSSESSION OR
# CORRESPONDENCE TO DESCRIPTION. YOU ASSUME THE ENTIRE RISK ARISING
# OUT OF USE OR PERFORMANCE OF THE SOFTWARE.
#
# 3. TO THE MAXIMUM EXTENT PERMITTED BY LAW, IN NO EVENT SHALL
# BROADCOM OR ITS LICENSORS BE LIABLE FOR (i) CONSEQUENTIAL,
# INCIDENTAL, SPECIAL, INDIRECT, OR EXEMPLARY DAMAGES WHATSOEVER
# ARISING OUT OF OR IN ANY WAY RELATING TO YOUR USE OF OR INABILITY
# TO USE THE SOFTWARE EVEN IF BROADCOM HAS BEEN ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGES; OR (ii) ANY AMOUNT IN EXCESS OF
# THE AMOUNT ACTUALLY PAID FOR THE SOFTWARE ITSELF OR USD 1.00,
# WHICHEVER IS GREATER. THESE LIMITATIONS SHALL APPLY NOTWITHSTANDING
# ANY FAILURE OF ESSENTIAL PURPOSE OF ANY LIMITED REMEDY.$
# Customize the location of your local tools below.
# Several standard flavors are auto-selected based on uname -s
# output. If the SYSNAME environment variable is set, that overrides
# calling uname. There are also a couple of Windows flavors that are
# selected by setting the HOSTTYPE environment variable. These should
# convert to using SYSNAME when I can test them...
# HOSTTYPE is still set because it is used in various Makefiles in the tree
SYSOK = 0
ifneq "$(SYSNAME)" ""
SYSOK = 1 # already set from environment
endif
# non-unix types first
ifeq "$(SYSOK)" "0"
ifeq "$(HOSTTYPE)" "Windows2000PC"
SYSOK = 1
#MAKE = make
HCC = cl
SED = SED_NOT_DEFINED
COMPRESS = COMPRESS_NOT_DEFINED
GZIP = GZIP_NOT_DEFINED
LZMA = LZMA_NOT_DEFINED
TOUCH = TOUCH_NOT_DEFINED
export PERL_BASE ?= c:/Perl/
ifneq "$(PERL_BASE)" ""
PERL = $(PERL_BASE)/bin/perl
else
PERL = perl
endif
endif
endif
# unix or unix-type type hosts
ifeq "$(SYSOK)" "0"
SYSNAME := $(shell uname -s)
ifeq "$(SYSNAME)" "Linux"
SYSOK = 1
HCC = /usr/bin/gcc
SED = /bin/sed
COMPRESS = /usr/bin/compress
GZIP = /usr/bin/gzip
LZMA = /projects/ntsw-tools/tools/bin/7za
TEST = /usr/bin/test
PERL = $(shell which perl)
LN = /bin/ln
HOSTTYPE= i386-linux
endif
ifeq "$(SYSNAME)" "SunOS"
SYSOK = 1
HCC = /tools/bin/gcc
SED = /usr/ucb/sed
COMPRESS = /bin/compress
GZIP = /usr/bin/gzip
LZMA = LZMA_NOT_DEFINED
TEST = /bin/test
PERL = $(shell which perl)
LN = /usr/bin/ln
HOSTTYPE= sun4
endif
ifeq "$(SYSNAME)" "NetBSD"
SYSOK = 1
HCC = /usr/bin/gcc
SED = /usr/bin/sed
COMPRESS = /usr/bin/compress
GZIP = /usr/bin/gzip
LZMA = LZMA_NOT_DEFINED
PERL = /usr/pkg/bin/perl
LN = /bin/ln
HOSTTYPE= i386-linux
endif
ifneq "$(findstring CYGWIN,$(SYSNAME))" ""
SYSOK = 1
HCC = /usr/bin/gcc
SED = /usr/bin/sed
COMPRESS = COMPRESS_NOT_DEFINED
GZIP = GZIP_NOT_DEFINED
LZMA = LZMA_NOT_DEFINED
PERL = /usr/bin/perl
LN = /bin/ln
HOSTTYPE= Windows_Cygnus
export HOSTTYPE # systems makefiles need this
endif
endif
#
# You may override any of the previous decisions and assignments
# determined above by providing your own makefile to be
# included here. Just set MAKE_TOOLS_LOCAL to the path to your makefile.
#
# Don't forget to set SYSOK=1 in your local makefile if you are
# providing a brand new
# environment.
#
ifdef MAKE_TOOLS_LOCAL
include ${MAKE_TOOLS_LOCAL}
endif
ifeq "$(SYSOK)" "0"
$(error Cannot figure out system type)
endif
#
# Platform Independent
#
ifeq "$(HOSTTYPE)" "Windows2000PC"
MKTOOL = $(PERL) ${SDK}/tools/mktool.pl
BCM2C = $(PERL) ${SDK}/tools/bcm2c.pl
MKVERS = $(PERL) ${SDK}/tools/version.pl
RM = rm -f
CP = cp
#MKDIR = mkdir -p
MKDIR = c:/windriver/workbench-3.0/x86-win32/bin/mkdir -p
FOREACH = $(MKTOOL) -foreach
MAKEDEP = echo
ECHO = echo
#TOUCH = touch
TOUCH = c:/windriver/workbench-3.0/x86-win32/bin/touch
MKBEEP = $(MKTOOL) -beep
else
MKTOOL = $(PERL) ${SDK}/tools/mktool.pl
BCM2C = $(PERL) ${SDK}/tools/bcm2c.pl
MKVERS = $(PERL) ${SDK}/tools/version.pl
RM = /bin/rm -rf
CP = /bin/cp
MKDIR = /bin/mkdir -p
FOREACH = $(MKTOOL) -foreach
MAKEDEP = /bin/echo
ECHO = /bin/echo
TOUCH = /bin/touch
MKBEEP = $(MKTOOL) -beep
endif
MKSBXHS = $(PERL) $(SDK)/tools/mksbxhs.pl