xref: /titanic_44/usr/src/tools/env/gatekeeper.sh (revision 98157a7002f4f2cf7978f3084ca5577f0a1d72b2)
1#
2# CDDL HEADER START
3#
4# The contents of this file are subject to the terms of the
5# Common Development and Distribution License (the "License").
6# You may not use this file except in compliance with the License.
7#
8# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9# or http://www.opensolaris.org/os/licensing.
10# See the License for the specific language governing permissions
11# and limitations under the License.
12#
13# When distributing Covered Code, include this CDDL HEADER in each
14# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15# If applicable, add the following below this CDDL HEADER, with the
16# fields enclosed by brackets "[]" replaced with your own identifying
17# information: Portions Copyright [yyyy] [name of copyright owner]
18#
19# CDDL HEADER END
20#
21
22#
23# Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
24# Use is subject to license terms.
25#
26# ident	"%Z%%M%	%I%	%E% SMI"
27#
28
29#	Configuration variables for the runtime environment of the nightly
30# build script and other tools for construction and packaging of releases.
31# This script is sourced by 'nightly' and 'bldenv' to set up the environment
32# for the build. This example is suitable for building a gate,
33# which will contain the resulting packages and archives (builds of the gate
34# are done in children and then the resulting archives, packages, and proto
35# area are put into the parent for everyone to use). It is based off
36# the onnv release. It sets NIGHTLY_OPTIONS to make nightly do:
37#	DEBUG and non-DEBUG builds (-D)
38#	creates cpio archives for bfu (-a)
39#	creates packages for PIT/RE (-p)
40#	checks for new interfaces in libraries (-A)
41#	runs 'make check' (-C)
42#	runs lint in usr/src (-l plus the LINTDIRS variable)
43#	sends mail on completion (-m and the MAILTO variable)
44#	updates the protolist in the parent for children to compare with (-u)
45#	updates the proto area in the parent when done (-U)
46#	checks for changes in ELF runpaths (-r)
47#	checks for changes in unreferenced files (-f)
48#
49NIGHTLY_OPTIONS="-aADClmpuUrf";		export NIGHTLY_OPTIONS
50
51# This is a variable for the rest of the script - GATE doesn't matter to
52# nightly itself
53GATE=onnv-gate;					export GATE
54
55# CODEMGR_WS - where is your workspace at (or what should nightly name it)
56# there is only one definition here, which assumes all the gate build machines
57# (sparc and x86) are set up the same. But remember, this is a script, so
58# you _could_ look at $MACH or `uname -n` and set these variables differently.
59CODEMGR_WS="/builds/$GATE";			export CODEMGR_WS
60
61# PARENT_WS is used to determine the parent of this workspace. This is
62# for the options that deal with the parent workspace (such as where the
63# proto area will go).
64PARENT_WS="/ws/$GATE";				export PARENT_WS
65
66# CLONE_WS is the workspace nightly should do a bringover from. Since it's
67# going to bringover usr/src, this could take a while, so we use the
68# clone instead of the gate (see the gate's README).
69CLONE_WS="/ws/onnv-clone";			export CLONE_WS
70
71# This flag controls whether to build the closed source.  If
72# undefined, nightly(1) and bldenv(1) will set it according to whether
73# the closed source tree is present.  CLOSED_IS_PRESENT="no" means not
74# building the closed sources.
75# CLOSED_IS_PRESENT="yes";		export CLOSED_IS_PRESENT
76
77# The bringover, if any, is done as STAFFER.
78# Set STAFFER to your own login as gatekeeper or integration engineer.
79# The point is to use group "staff" and avoid referencing the parent
80# workspace as root.
81# Some scripts optionally send mail messages to MAILTO.
82#
83STAFFER=nobody;				export STAFFER
84MAILTO=$STAFFER;			export MAILTO
85
86# The project (see project(4)) under which to run this build.  If not
87# specified, the build is simply run in a new task in the current project.
88BUILD_PROJECT=;				export BUILD_PROJECT
89
90# You should not need to change the next four lines
91LOCKNAME="`basename $CODEMGR_WS`_nightly.lock"; export LOCKNAME
92ATLOG="$CODEMGR_WS/log";			export ATLOG
93LOGFILE="$ATLOG/nightly.log";			export LOGFILE
94MACH=`uname -p`;				export MACH
95
96# REF_PROTO_LIST - for comparing the list of stuff in your proto area
97# with. Generally this should be left alone, since you want to see differences
98# between todays build and yesterdays.
99#
100REF_PROTO_LIST=$PARENT_WS/usr/src/proto_list_${MACH}; export REF_PROTO_LIST
101
102# where cpio archives of the OS are placed. Usually this should be left
103# alone too. Here they don't go in the build workspace, but in the parent.
104# Since this is done as root, the build machine needs root acces to
105# the parent over NFS.
106CPIODIR="${PARENT_WS}/archives/${MACH}/nightly";	export CPIODIR
107
108#
109#	build environment variables, including version info for mcs, motd,
110# motd, uname and boot messages. Mostly you shouldn't change this except
111# when the release slips (nah) or when starting a new release.
112#
113ROOT="$CODEMGR_WS/proto/root_${MACH}";	export ROOT
114SRC="$CODEMGR_WS/usr/src";         	export SRC
115VERSION="$GATE";			export VERSION
116
117#
118# the RELEASE and RELEASE_DATE variables are set in Makefile.master;
119# there might be special reasons to override them here, but that
120# should not be the case in general
121#
122# RELEASE="5.10.1";			export RELEASE
123# RELEASE_DATE="October 2007";		export RELEASE_DATE
124
125# proto area in parent for optionally depositing a copy of headers and
126# libraries corresponding to the protolibs target
127#
128PARENT_ROOT=$PARENT_WS/proto/root_$MACH; export PARENT_ROOT
129
130#
131#       package creation variable. This put the packages in the parent.
132#
133PKGARCHIVE="${PARENT_WS}/packages/${MACH}/nightly";	export PKGARCHIVE
134
135# we want make to do as much as it can, just in case there's more than
136# one problem. This is especially important with the gate, since multiple
137# unrelated broken things can be integrated.
138MAKEFLAGS=k;	export MAKEFLAGS
139
140# Magic variable to prevent the devpro compilers/teamware from sending
141# mail back to devpro on every use.
142UT_NO_USAGE_TRACKING="1"; export UT_NO_USAGE_TRACKING
143
144# Build tools - don't set these unless you know what you're doing.  These
145# variables allows you to get the compilers and onbld files locally or
146# through cachefs.  Set BUILD_TOOLS to pull everything from one location.
147# Alternately, you can set ONBLD_TOOLS to where you keep the contents of
148# SUNWonbld and SPRO_ROOT to where you keep the compilers.
149#
150#BUILD_TOOLS=/opt;				export BUILD_TOOLS
151#ONBLD_TOOLS=/opt/onbld;			export ONBLD_TOOLS
152#SPRO_ROOT=/opt/SUNspro;			export SPRO_ROOT
153
154# This goes along with lint - it is a series of the form "A [y|n]" which
155# means "go to directory A and run 'make lint'" Then mail me (y) the
156# difference in the lint output. 'y' should only be used if the area you're
157# linting is actually lint clean or you'll get lots of mail.
158# You shouldn't need to change this though.
159#LINTDIRS="$SRC y";	export LINTDIRS
160
161#
162# Reference to IA32 IHV workspace, proto area and packages
163#
164#IA32_IHV_WS=/ws/${GATE}-ihv;				export IA32_IHV_WS
165#IA32_IHV_ROOT=$IA32_IHV_WS/proto/root_i386;		export IA32_IHV_ROOT
166#IA32_IHV_PKGS=$IA32_IHV_WS/packages/i386/nightly;	export IA32_IHV_PKGS
167
168#
169# Reference to binary-only IA32 IHV packages
170#
171#IA32_IHV_BINARY_PKGS=/ws/${GATE}-ihv-bin
172#export IA32_IHV_BINARY_PKGS
173
174#
175# Destination for sparc realmode package SUNWrmodu
176#
177#SPARC_RM_PKGARCHIVE="${CODEMGR_WS}/packages/sparc_realmode/nightly"
178#export SPARC_RM_PKGARCHIVE
179
180# Set this flag to 'n' to disable the automatic validation of the dmake
181# version in use.  The default is to check it.
182#CHECK_DMAKE=y
183
184# Set this flag to 'n' to disable the use of 'checkpaths'.  The default,
185# if the 'N' option is not specified, is to run this test.
186#CHECK_PATHS=y
187
188# Set this flag to 'y' to enable the use of elfsigncmp to validate the
189# output of elfsign.  Doing so requires that 't' be set in NIGHTLY_OPTIONS.
190# The default is to not verify them.
191#VERIFY_ELFSIGN=n
192
193# BRINGOVER_FILES is the list of files nightly passes to bringover.
194# If not set the default is "usr", but it can be used for bringing
195# over deleted_files or other nifty directories.
196#BRINGOVER_FILES="usr deleted_files"
197
198# POST_NIGHTLY can be any command to be run at the end of nightly.  See
199# nightly(1) for interactions between environment variables and this command.
200#POST_NIGHTLY=
201