diff options
Diffstat (limited to 'usr/src/tools')
37 files changed, 214 insertions, 76 deletions
diff --git a/usr/src/tools/README.tools b/usr/src/tools/README.tools index 6cb51f028a..323d6c679c 100644 --- a/usr/src/tools/README.tools +++ b/usr/src/tools/README.tools @@ -192,6 +192,9 @@ findunref sort > ~/unref-sparc.out $ comm -12 ~/unref-i386.out ~/unref-sparc.out > ~/unref.out +git-active + helper used by webrev to generate file lists for Git workspaces. + hdrchk checks headers for compliance with OS/Net standards (form, includes, C++ guards). diff --git a/usr/src/tools/aw/aw.c b/usr/src/tools/aw/aw.c index 88673c88e4..36891b1a9c 100644 --- a/usr/src/tools/aw/aw.c +++ b/usr/src/tools/aw/aw.c @@ -550,29 +550,6 @@ main(int argc, char *argv[]) newae(as, "--traditional-format"); /* - * This is a support hack to rewrite code for the compiler - * which should probably cause an assembler programmer to recode - * - so, generate a warning in this case. - * - * -K was dropped begining with version 2.18. - */ - { - struct aelist *as_ver = newael(); - struct aelist *ggrep = newael(); - - newae(as_ver, as_pgm); - newae(as_ver, "--version"); - newae(ggrep, "/usr/bin/ggrep"); - newae(ggrep, "-q"); - newae(ggrep, "-E"); - newae(ggrep, "2.1[567]"); - code = pipeline(aeltoargv(as_ver), aeltoargv(ggrep)); - if (code == 0) { - newae(as, "-K"); - } - } - - /* * Walk the argument list, translating as we go .. */ while (--argc > 0) { diff --git a/usr/src/tools/ctf/Makefile.ctf b/usr/src/tools/ctf/Makefile.ctf index ace863e89b..7c5b041746 100644 --- a/usr/src/tools/ctf/Makefile.ctf +++ b/usr/src/tools/ctf/Makefile.ctf @@ -40,7 +40,8 @@ HDRDIRS= \ -I../../common \ -I$(SRC) \ -I/usr/include \ - -I$(SRC)/uts/common + -I$(SRC)/uts/common \ + -I$(NATIVE_ADJUNCT)/include CPPFLAGS += $(HDRDIRS) CFLAGS += $(CCVERBOSE) diff --git a/usr/src/tools/ctf/common/ctf_headers.h b/usr/src/tools/ctf/common/ctf_headers.h index b00b8fd9a6..268ae79077 100644 --- a/usr/src/tools/ctf/common/ctf_headers.h +++ b/usr/src/tools/ctf/common/ctf_headers.h @@ -27,8 +27,6 @@ #ifndef _CTF_HEADERS_H #define _CTF_HEADERS_H -#pragma ident "%Z%%M% %I% %E% SMI" - /* * Because the ON tools are executed on the system where they are built, * the tools need to include the headers installed on the build system, @@ -69,4 +67,15 @@ #include <uts/common/sys/ctf_api.h> #include <lib/libctf/common/libctf.h> +/* + * XXX: This is hack to deal with GCC 4.x removing __builtin_stdarg_start + * + * We need to build on systems that don't have the fixed va_impl.h on the + * system, to achieve that, we stub it out here and in all similar places to + * give us a leg up. + */ +#if __GNUC__ >= 4 +#define __builtin_stdarg_start(list, name) __builtin_va_start(list, name) +#endif + #endif /* _CTF_HEADERS_H */ diff --git a/usr/src/tools/ctf/common/utils.h b/usr/src/tools/ctf/common/utils.h index 9b07361a53..4ae2dd0917 100644 --- a/usr/src/tools/ctf/common/utils.h +++ b/usr/src/tools/ctf/common/utils.h @@ -27,9 +27,8 @@ #ifndef _UTILS_H #define _UTILS_H -#pragma ident "%Z%%M% %I% %E% SMI" - #include <stdarg.h> +#include <ctf_headers.h> #ifdef __cplusplus extern "C" { diff --git a/usr/src/tools/ctf/cvt/Makefile.com b/usr/src/tools/ctf/cvt/Makefile.com index fb35379c3a..5385b3769f 100644 --- a/usr/src/tools/ctf/cvt/Makefile.com +++ b/usr/src/tools/ctf/cvt/Makefile.com @@ -73,6 +73,7 @@ DWARFLDFLAGS = \ -ldwarf DWARFCPPFLAGS = -I../../dwarf/common +LDFLAGS += -L$(NATIVE_ADJUNCT)/lib LDLIBS += -lz -lelf CPPFLAGS += -D_REENTRANT CFLAGS += $(CTF_FLAGS) diff --git a/usr/src/tools/ctf/cvt/ctftools.h b/usr/src/tools/ctf/cvt/ctftools.h index 991f3bc921..f586236ccf 100644 --- a/usr/src/tools/ctf/cvt/ctftools.h +++ b/usr/src/tools/ctf/cvt/ctftools.h @@ -26,8 +26,6 @@ #ifndef _CTFTOOLS_H #define _CTFTOOLS_H -#pragma ident "%Z%%M% %I% %E% SMI" - /* * Functions and data structures used in the manipulation of stabs and CTF data */ @@ -43,6 +41,17 @@ extern "C" { #endif +/* + * XXX: This is hack to deal with GCC 4.x removing __builtin_stdarg_start + * + * We need to build on systems that don't have the fixed va_impl.h on the + * system, to achieve that, we stub it out here and in all similar places to + * give us a leg up. + */ +#if __GNUC__ >= 4 +#define __builtin_stdarg_start(list, name) __builtin_va_start(list, name) +#endif + #include "list.h" #include "hash.h" diff --git a/usr/src/tools/ctf/dump/Makefile.com b/usr/src/tools/ctf/dump/Makefile.com index ca3e925d01..9877fa06a3 100644 --- a/usr/src/tools/ctf/dump/Makefile.com +++ b/usr/src/tools/ctf/dump/Makefile.com @@ -31,6 +31,7 @@ SRCS = dump.c utils.c symbol.c include ../../Makefile.ctf +LDFLAGS += -L$(NATIVE_ADJUNCT)/lib LDLIBS += -lelf -lz OBJS = $(SRCS:%.c=%.o) diff --git a/usr/src/tools/findunref/exception_list.git b/usr/src/tools/findunref/exception_list.git new file mode 100644 index 0000000000..d14dbd22f0 --- /dev/null +++ b/usr/src/tools/findunref/exception_list.git @@ -0,0 +1,39 @@ +# +# CDDL HEADER START +# +# The contents of this file are subject to the terms of the +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. +# +# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE +# or http://www.opensolaris.org/os/licensing. +# See the License for the specific language governing permissions +# and limitations under the License. +# +# When distributing Covered Code, include this CDDL HEADER in each +# file and include the License file at usr/src/OPENSOLARIS.LICENSE. +# If applicable, add the following below this CDDL HEADER, with the +# fields enclosed by brackets "[]" replaced with your own identifying +# information: Portions Copyright [yyyy] [name of copyright owner] +# +# CDDL HEADER END +# + +# +# Copyright 2009 Cyril Plisko. All rights reserved. +# Use is subject to license terms. +# + +# +# Git-specific exception list +# +# See README.exception_lists for details +# + +# +# Without nested repositories, this list could be empty, because ON +# checks for unref relative to usr, and the git files are all in the +# root of the repository. +# + +*/.git diff --git a/usr/src/tools/findunref/exception_list.open b/usr/src/tools/findunref/exception_list.open index afc9b44a2f..5126a6cb88 100644 --- a/usr/src/tools/findunref/exception_list.open +++ b/usr/src/tools/findunref/exception_list.open @@ -278,3 +278,4 @@ # ld tests which are not currently delivered # ./usr/src/cmd/sgs/test +./usr/src/cmd/mdb/test diff --git a/usr/src/tools/findunref/exception_list.unknown b/usr/src/tools/findunref/exception_list.unknown new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/usr/src/tools/findunref/exception_list.unknown diff --git a/usr/src/tools/onbld/Checks/Cddl.py b/usr/src/tools/onbld/Checks/Cddl.py index 1f5f99f953..0f4d995e89 100644 --- a/usr/src/tools/onbld/Checks/Cddl.py +++ b/usr/src/tools/onbld/Checks/Cddl.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON CDDL = ''' CDDL HEADER START diff --git a/usr/src/tools/onbld/Checks/CmtBlk.py b/usr/src/tools/onbld/Checks/CmtBlk.py index 2f3d29fa79..ddf5caec48 100644 --- a/usr/src/tools/onbld/Checks/CmtBlk.py +++ b/usr/src/tools/onbld/Checks/CmtBlk.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START diff --git a/usr/src/tools/onbld/Checks/Comments.py b/usr/src/tools/onbld/Checks/Comments.py index daf6aa47d9..6304e59818 100644 --- a/usr/src/tools/onbld/Checks/Comments.py +++ b/usr/src/tools/onbld/Checks/Comments.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # diff --git a/usr/src/tools/onbld/Checks/Copyright.py b/usr/src/tools/onbld/Checks/Copyright.py index 81a80058aa..8071b7f435 100644 --- a/usr/src/tools/onbld/Checks/Copyright.py +++ b/usr/src/tools/onbld/Checks/Copyright.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # diff --git a/usr/src/tools/onbld/Checks/DbLookups.py b/usr/src/tools/onbld/Checks/DbLookups.py index 11fd4185be..15f889e8d2 100644 --- a/usr/src/tools/onbld/Checks/DbLookups.py +++ b/usr/src/tools/onbld/Checks/DbLookups.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # diff --git a/usr/src/tools/onbld/Checks/HdrChk.py b/usr/src/tools/onbld/Checks/HdrChk.py index c2697dcaf2..8f7b946d12 100644 --- a/usr/src/tools/onbld/Checks/HdrChk.py +++ b/usr/src/tools/onbld/Checks/HdrChk.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # diff --git a/usr/src/tools/onbld/Checks/Keywords.py b/usr/src/tools/onbld/Checks/Keywords.py index 5c374c3abb..ac3555be32 100644 --- a/usr/src/tools/onbld/Checks/Keywords.py +++ b/usr/src/tools/onbld/Checks/Keywords.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # @@ -24,8 +24,6 @@ # Copyright 2008 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # -# ident "%Z%%M% %I% %E% SMI" -# # # Mercurial (lack of) keyword checks diff --git a/usr/src/tools/onbld/Checks/Mapfile.py b/usr/src/tools/onbld/Checks/Mapfile.py index 2a8cb74aed..d4fa70d141 100644 --- a/usr/src/tools/onbld/Checks/Mapfile.py +++ b/usr/src/tools/onbld/Checks/Mapfile.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # diff --git a/usr/src/tools/onbld/Checks/__init__.py b/usr/src/tools/onbld/Checks/__init__.py index 4bb5f3e262..b7ecf0e881 100644 --- a/usr/src/tools/onbld/Checks/__init__.py +++ b/usr/src/tools/onbld/Checks/__init__.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # diff --git a/usr/src/tools/onbld/Scm/Ignore.py b/usr/src/tools/onbld/Scm/Ignore.py new file mode 100644 index 0000000000..048b46ba6f --- /dev/null +++ b/usr/src/tools/onbld/Scm/Ignore.py @@ -0,0 +1,91 @@ +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +# THE SOFTWARE +# +# Copyright (c) 2013, Joyent Inc. All rights reserved. +# + +''' +Process our ignore/exception_list file format. + +The format is broadly similar, if not identical, to .gitignore and .hgignore +files. +''' + +import re +import fnmatch + +RE_SYNTAX = re.compile(r'^syntax:\s*(.*)\s*$') + +# +# It is important that this module not rely on Mercurial +# + +def _read_ignore_file(ignorefile): + '''Read an ignore file and return an array of regular expressions + to match ignored paths.''' + + syntax = 'regex' + ignore_list = [] + lc = 0 + + with open(ignorefile, 'r') as f: + for l in f: + lc += 1 + # Remove comments and blank lines + l = l.split('#', 2)[0].strip() + if l == '': + continue + # Process "syntax:" lines + m = RE_SYNTAX.match(l) + if m: + syntax = m.group(1) + continue + # All other lines are considered patterns + if (syntax == 'glob'): + ignore_list.append(re.compile('.*' + fnmatch.translate(l))) + elif (syntax == 'regex'): + ignore_list.append(re.compile(l)) + else: + raise Exception('%s:%d: syntax "%s" is not supported' % + (ignorefile, lc, syntax)) + + return ignore_list + +def ignore(root, ignorefiles): + # If we aren't provided any ignore files, we'll never ignore + # any paths: + if (len(ignorefiles) < 1): + return lambda x: False + + ignore_list = [] + for ignorefile in ignorefiles: + ignore_list.extend(_read_ignore_file(ignorefile)) + + # If the ignore files contained no patterns, we'll never ignore + # any paths: + if (len(ignore_list) < 1): + return lambda x: False + + def _ignore_func(path): + for regex in ignore_list: + if (regex.match(path)): + return True + return False + + return _ignore_func diff --git a/usr/src/tools/onbld/Scm/Makefile b/usr/src/tools/onbld/Scm/Makefile index a31f7e5c87..26a3a4ccfc 100644 --- a/usr/src/tools/onbld/Scm/Makefile +++ b/usr/src/tools/onbld/Scm/Makefile @@ -21,6 +21,7 @@ # # Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. +# Copyright (c) 2013, Joyent Inc. All rights reserved. # include $(SRC)/Makefile.master @@ -29,6 +30,7 @@ include ../../Makefile.tools PYSRCS = \ __init__.py \ Backup.py \ + Ignore.py \ Version.py \ WorkSpace.py diff --git a/usr/src/tools/onbld/Scm/__init__.py b/usr/src/tools/onbld/Scm/__init__.py index f45ecbc95f..8934eb3942 100644 --- a/usr/src/tools/onbld/Scm/__init__.py +++ b/usr/src/tools/onbld/Scm/__init__.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # @@ -24,5 +24,3 @@ # Copyright 2008 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # -# ident "%Z%%M% %I% %E% SMI" -# diff --git a/usr/src/tools/onbld/hgext/__init__.py b/usr/src/tools/onbld/hgext/__init__.py index f45ecbc95f..8934eb3942 100644 --- a/usr/src/tools/onbld/hgext/__init__.py +++ b/usr/src/tools/onbld/hgext/__init__.py @@ -1,4 +1,4 @@ -#! /usr/bin/python +#!ON_PYTHON # # CDDL HEADER START # @@ -24,5 +24,3 @@ # Copyright 2008 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # -# ident "%Z%%M% %I% %E% SMI" -# diff --git a/usr/src/tools/onbld/hgext/cdm.py b/usr/src/tools/onbld/hgext/cdm.py index 0ce41d4dad..a04317fff9 100644 --- a/usr/src/tools/onbld/hgext/cdm.py +++ b/usr/src/tools/onbld/hgext/cdm.py @@ -16,6 +16,7 @@ # # Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. # Copyright 2008, 2011 Richard Lowe +# Copyright (c) 2013, Joyent Inc. All rights reserved. # '''OpenSolaris extensions to Mercurial @@ -92,6 +93,7 @@ sys.path.insert(1, os.path.join(os.path.dirname(__file__), "..", "..", "..", sys.path.insert(2, os.path.join(os.path.dirname(__file__), "..", "..")) from onbld.Scm import Version +from onbld.Scm import Ignore from mercurial import util try: @@ -99,7 +101,7 @@ try: except Version.VersionMismatch, badversion: raise util.Abort("Version Mismatch:\n %s\n" % badversion) -from mercurial import cmdutil, ignore, node, patch +from mercurial import cmdutil, node, patch from onbld.Scm.WorkSpace import WorkSpace, WorkList from onbld.Scm.Backup import CdmBackup @@ -167,7 +169,7 @@ def not_check(repo, cmd): ignorefiles.append(f) if ignorefiles: - ign = ignore.ignore(repo.root, ignorefiles, repo.ui.warn) + ign = Ignore.ignore(repo.root, ignorefiles) return canonified_check(ign) else: return util.never diff --git a/usr/src/tools/scripts/bldenv.sh b/usr/src/tools/scripts/bldenv.sh index 4720b7925e..86ed08d932 100644 --- a/usr/src/tools/scripts/bldenv.sh +++ b/usr/src/tools/scripts/bldenv.sh @@ -345,6 +345,10 @@ if [[ "${SUNWSPRO}" != "" ]]; then export PATH="${SUNWSPRO}/bin:$PATH" fi +if [[ -n "${MAKE}" ]]; then + export PATH="$(dirname ${MAKE}):$PATH" +fi + if [[ -z "$CLOSED_IS_PRESENT" ]]; then if [[ -d $SRC/../closed ]]; then export CLOSED_IS_PRESENT="yes" diff --git a/usr/src/tools/scripts/cddlchk.py b/usr/src/tools/scripts/cddlchk.py index 816d2f33a7..ad6a6e6f56 100644 --- a/usr/src/tools/scripts/cddlchk.py +++ b/usr/src/tools/scripts/cddlchk.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # CDDL HEADER START # diff --git a/usr/src/tools/scripts/copyrightchk.py b/usr/src/tools/scripts/copyrightchk.py index 210ef1b46c..f778947bfc 100644 --- a/usr/src/tools/scripts/copyrightchk.py +++ b/usr/src/tools/scripts/copyrightchk.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # CDDL HEADER START # diff --git a/usr/src/tools/scripts/git-pbchk.py b/usr/src/tools/scripts/git-pbchk.py index 656e22f6b4..82a63df70a 100644 --- a/usr/src/tools/scripts/git-pbchk.py +++ b/usr/src/tools/scripts/git-pbchk.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 @@ -17,6 +17,7 @@ # # Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. # Copyright 2008, 2012 Richard Lowe +# Copyright (c) 2013, Joyent Inc. All rights reserved. # import getopt @@ -28,10 +29,6 @@ import tempfile from cStringIO import StringIO -# This is necessary because, in a fit of pique, we used hg-format ignore lists -# for NOT files. -from mercurial import ignore - # # Adjust the load path based on our location and the version of python into # which it is being loaded. This assumes the normal onbld directory @@ -47,6 +44,7 @@ sys.path.insert(1, os.path.join(os.path.dirname(__file__), "..", "lib", # sys.path.insert(2, os.path.join(os.path.dirname(__file__), "..")) +from onbld.Scm import Ignore from onbld.Checks import Comments, Copyright, CStyle, HdrChk from onbld.Checks import JStyle, Keywords, Mapfile @@ -177,10 +175,7 @@ def not_check(root, cmd): ignorefiles = filter(os.path.exists, [os.path.join(root, ".git", "%s.NOT" % cmd), os.path.join(root, "exception_lists", cmd)]) - if len(ignorefiles) > 0: - return ignore.ignore(root, ignorefiles, sys.stderr.write) - else: - return lambda x: False + return Ignore.ignore(root, ignorefiles) def gen_files(root, parent, paths, exclude): diff --git a/usr/src/tools/scripts/hdrchk.py b/usr/src/tools/scripts/hdrchk.py index 84acbc8616..aa62f7b090 100644 --- a/usr/src/tools/scripts/hdrchk.py +++ b/usr/src/tools/scripts/hdrchk.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # CDDL HEADER START # diff --git a/usr/src/tools/scripts/hg-active.py b/usr/src/tools/scripts/hg-active.py index 88394e98e5..23f6c7cd98 100644 --- a/usr/src/tools/scripts/hg-active.py +++ b/usr/src/tools/scripts/hg-active.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 diff --git a/usr/src/tools/scripts/mapfilechk.py b/usr/src/tools/scripts/mapfilechk.py index 9cf2000c7a..ed90d8b426 100644 --- a/usr/src/tools/scripts/mapfilechk.py +++ b/usr/src/tools/scripts/mapfilechk.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # CDDL HEADER START # diff --git a/usr/src/tools/scripts/nightly.sh b/usr/src/tools/scripts/nightly.sh index 9ad9454f4d..cd6a5bcb6a 100644 --- a/usr/src/tools/scripts/nightly.sh +++ b/usr/src/tools/scripts/nightly.sh @@ -654,6 +654,9 @@ function build { rm -rf $PKGARCHIVE >> "$LOGFILE" 2>&1 mkdir -p $PKGARCHIVE >> "$LOGFILE" 2>&1 + /bin/time $MAKE -e stage-licenses 2>&1 | \ + tee -a $SRC/$d/${INSTALLOG}.out >> $LOGFILE + for d in pkg pkgdefs; do if [ ! -f "$SRC/$d/Makefile" ]; then continue @@ -1505,7 +1508,9 @@ DEV_CM="\"@(#)SunOS Internal Development: $LOGNAME $BUILD_DATE [$BASEWSDIR]\"" export o_FLAG X_FLAG POUND_SIGN RELEASE_DATE DEV_CM maketype="distributed" -MAKE=dmake +if [ -z "$MAKE" ]; then + MAKE=dmake +fi # get the dmake version string alone DMAKE_VERSION=$( $MAKE -v ) DMAKE_VERSION=${DMAKE_VERSION#*: } @@ -1700,7 +1705,7 @@ ENVCPPFLAGS4= PARENT_ROOT= export ENVLDLIBS3 ENVCPPFLAGS1 ENVCPPFLAGS2 ENVCPPFLAGS3 ENVCPPFLAGS4 \ - PARENT_ROOT + ENVLDLIBS1 ENVLDLIBS2 PARENT_ROOT PKGARCHIVE_ORIG=$PKGARCHIVE IA32_IHV_PKGS_ORIG=$IA32_IHV_PKGS diff --git a/usr/src/tools/scripts/validate_pkg.py b/usr/src/tools/scripts/validate_pkg.py index 2ac1e009d0..5bf8bd84f2 100644 --- a/usr/src/tools/scripts/validate_pkg.py +++ b/usr/src/tools/scripts/validate_pkg.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # CDDL HEADER START # diff --git a/usr/src/tools/scripts/webrev.sh b/usr/src/tools/scripts/webrev.sh index 7df8aa8b52..e3c1631c1b 100644 --- a/usr/src/tools/scripts/webrev.sh +++ b/usr/src/tools/scripts/webrev.sh @@ -3057,7 +3057,12 @@ done # # Output directory. # -WDIR=${WDIR:-$CWS/webrev} +if [[ $SCM_MODE == "git" ]]; then + ws_top_dir=$(dirname $CWS) + WDIR=${WDIR:-$ws_top_dir/webrev} +else + WDIR=${WDIR:-$CWS/webrev} +fi # # Name of the webrev, derived from the workspace name or output directory; @@ -3685,6 +3690,7 @@ do if [[ $SCM_MODE == "teamware" || $SCM_MODE == "mercurial" || + $SCM_MODE == "git" || $SCM_MODE == "unknown" ]]; then # Include warnings for important file mode situations: diff --git a/usr/src/tools/scripts/wsdiff.py b/usr/src/tools/scripts/wsdiff.py index 5156f03c20..b485a143a3 100644 --- a/usr/src/tools/scripts/wsdiff.py +++ b/usr/src/tools/scripts/wsdiff.py @@ -1,4 +1,4 @@ -#!/usr/bin/python2.6 +#!ON_PYTHON_26 # # CDDL HEADER START # diff --git a/usr/src/tools/scripts/xref.sh b/usr/src/tools/scripts/xref.sh index 78c85bae81..d69a364fda 100644 --- a/usr/src/tools/scripts/xref.sh +++ b/usr/src/tools/scripts/xref.sh @@ -28,11 +28,10 @@ ONBLDDIR=$(dirname $(whence $0)) -PATH=/usr/bin:/usr/ccs/bin:${BUILD_TOOLS:-/opt}/teamware/bin:$ONBLDDIR -export PATH PROG=`basename $0` XREFMK=`dirname $0`/xref.mk XRMAKEFILE=Makefile export XRMAKEFILE +MAKE="dmake -m serial" # # The CSCOPEOPTIONS variable can cause problems if it's set in the environment @@ -163,7 +162,7 @@ if [ -z "$xrefs" ]; then # Disable etags if we can't find it. # xrefs="cscope ctags" - make -e -f $XREFMK xref.etags.check 2>/dev/null 1>&2 && \ + $MAKE -e -f $XREFMK xref.etags.check 2>/dev/null 1>&2 && \ xrefs="$xrefs etags" else oldifs=$IFS @@ -219,7 +218,7 @@ for dir in $dirs; do # to purge any crud that may be lying around from previous aborted runs. # if [ -z "$clobber" ]; then - make -e -f $XREFMK xref.clean > /dev/null + $MAKE -e -f $XREFMK xref.clean > /dev/null fi # @@ -228,7 +227,7 @@ for dir in $dirs; do if [ -z "$noflg" -a -z "$clobber" ]; then SECONDS=0 info "$reldir: finding flg-related source files" - make -e -f $XREFMK xref.flg > /dev/null + $MAKE -e -f $XREFMK xref.flg > /dev/null if [ $? -ne 0 ]; then warn "$reldir: unable to find flg-related source files" else @@ -248,19 +247,19 @@ for dir in $dirs; do for xref in $xrefs; do if [ -n "$clobber" ]; then info "$reldir: clobbering $xref cross-reference" - make -e -f $XREFMK xref.${xref}.clobber > /dev/null || + $MAKE -e -f $XREFMK xref.${xref}.clobber > /dev/null || warn "$reldir: cannot clobber $xref cross-reference" continue fi SECONDS=0 info "$reldir: building $xref cross-reference" - make -e -f $XREFMK xref.${xref} > /dev/null || + $MAKE -e -f $XREFMK xref.${xref} > /dev/null || fail "$reldir: cannot build $xref cross-reference" timeinfo "$reldir: built $xref cross-reference" done - make -e -f $XREFMK xref.clean > /dev/null || + $MAKE -e -f $XREFMK xref.clean > /dev/null || warn "$reldir: cannot clean up temporary files" cd - > /dev/null done |