diff options
Diffstat (limited to 'usr/src/tools')
-rw-r--r-- | usr/src/tools/Makefile | 11 | ||||
-rw-r--r-- | usr/src/tools/Makefile.python | 15 | ||||
-rw-r--r-- | usr/src/tools/env/illumos.sh | 13 | ||||
-rw-r--r-- | usr/src/tools/onbld/Checks/DbLookups.py | 2 | ||||
-rw-r--r-- | usr/src/tools/onbld/Checks/Makefile | 4 | ||||
-rw-r--r-- | usr/src/tools/onbld/Checks/py2/Makefile | 45 | ||||
-rw-r--r-- | usr/src/tools/onbld/Makefile | 4 | ||||
-rw-r--r-- | usr/src/tools/onbld/Scm/Makefile | 4 | ||||
-rw-r--r-- | usr/src/tools/onbld/Scm/py2/Makefile | 45 | ||||
-rw-r--r-- | usr/src/tools/onbld/py2/Makefile | 45 | ||||
-rw-r--r-- | usr/src/tools/scripts/Makefile | 2 |
11 files changed, 8 insertions, 182 deletions
diff --git a/usr/src/tools/Makefile b/usr/src/tools/Makefile index 2193a1bda9..68bd0e252a 100644 --- a/usr/src/tools/Makefile +++ b/usr/src/tools/Makefile @@ -123,13 +123,7 @@ ROOTDIRS= \ $(ROOTONBLD)/man \ $(ROOTONBLD)/man/man1onbld -$(BUILDPY2TOOLS)ROOTDIRS += \ - $(ROOTONBLD)/lib/python$(PYTHON_VERSION) \ - $(ROOTONBLD)/lib/python$(PYTHON_VERSION)/onbld \ - $(ROOTONBLD)/lib/python$(PYTHON_VERSION)/onbld/Checks \ - $(ROOTONBLD)/lib/python$(PYTHON_VERSION)/onbld/Scm - -$(BUILDPY3TOOLS)ROOTDIRS += \ +ROOTDIRS += \ $(ROOTONBLD)/lib/python$(PYTHON3_VERSION) \ $(ROOTONBLD)/lib/python$(PYTHON3_VERSION)/onbld \ $(ROOTONBLD)/lib/python$(PYTHON3_VERSION)/onbld/__pycache__ \ @@ -154,7 +148,6 @@ DOROOTDIRS= $(ROOTDIRS) clobber:= DOROOTDIRS= clean:= DOROOTDIRS= -$(BUILDPY2TOOLS)DOROOTONBLDLIBPY= $(ROOTONBLDLIBPY) clobber:= DOROOTONBLDLIBPY= clean:= DOROOTONBLDLIBPY= @@ -181,6 +174,6 @@ $(ROOTDIRS): $(MKDIR) -p -m $(DIRMODE) $@ $(ROOTONBLDLIBPY): $(ROOTDIRS) - $(RM) -r $@; $(SYMLINK) python$(PYTHON_VERSION) $@ + $(RM) -r $@; $(SYMLINK) python$(PYTHON3_VERSION) $@ FRC: diff --git a/usr/src/tools/Makefile.python b/usr/src/tools/Makefile.python index 63df6e7a36..229df0b945 100644 --- a/usr/src/tools/Makefile.python +++ b/usr/src/tools/Makefile.python @@ -85,19 +85,7 @@ pyclobber: $(RM) $(CLOBBERFILES) $(RM) -rf $(CLOBBERDIRS) -# Python 2 module compilation - -python$(PYVER)/%.pyc: ../%.py - @[ -d $(@D) ] || mkdir $(@D) - $(RM) $@ - $(PYTHON) -mpy_compile $< - $(MV) ../$(*).pyc $@ - -$(ROOTPYDIR)/%.pyc: python$(PYVER)/%.pyc - $(INS.pyfile) - -# Python 3 module compilation - +# Python module compilation python$(PYVER)/__pycache__/%.cpython$(PYPKGVERS).pyc: ../%.py @[ -d $(@D) ] || mkdir -p $(@D) $(RM) $@ @@ -106,4 +94,3 @@ python$(PYVER)/__pycache__/%.cpython$(PYPKGVERS).pyc: ../%.py $(ROOTPYDIR)/__pycache__/%.pyc: python$(PYVER)/__pycache__/%.pyc $(INS.pyfile) - diff --git a/usr/src/tools/env/illumos.sh b/usr/src/tools/env/illumos.sh index bd21476c29..30148be6ef 100644 --- a/usr/src/tools/env/illumos.sh +++ b/usr/src/tools/env/illumos.sh @@ -106,23 +106,10 @@ export ENABLE_SMB_PRINTING= # If your distro uses certain versions of Python, make sure either # Makefile.master contains your new defaults OR your .env file sets them. -#export PYTHON_VERSION=2.7 -#export PYTHON_PKGVERS=-27 -#export PYTHON_SUFFIX= #export PYTHON3_VERSION=3.5 #export PYTHON3_PKGVERS=-35 #export PYTHON3_SUFFIX=m -# To disable building with either Python2 or Python 3 (or both), uncomment -# these lines: -#export BUILDPY2='#' -#export BUILDPY3='#' - -# To disable building this workspace's tools in $SRC/tools with either Python2 -# or Python3 (but not both!), uncomment either of these lines: -#export BUILDPY2TOOLS='#' -#export BUILDPY3TOOLS='#' - # Set console color scheme either by build type: # #export RELEASE_CONSOLE_COLOR="-DDEFAULT_ANSI_FOREGROUND=ANSI_COLOR_BLACK \ diff --git a/usr/src/tools/onbld/Checks/DbLookups.py b/usr/src/tools/onbld/Checks/DbLookups.py index 83a60a64dc..d396a68cbc 100644 --- a/usr/src/tools/onbld/Checks/DbLookups.py +++ b/usr/src/tools/onbld/Checks/DbLookups.py @@ -86,7 +86,7 @@ class BugDB(object): try: data = urlopen(req) - except HTTPError, e: + except HTTPError as e: if e.code == 404 or e.code == 403 or e.code == 400: raise NonExistentBug(cr) else: diff --git a/usr/src/tools/onbld/Checks/Makefile b/usr/src/tools/onbld/Checks/Makefile index b6f18bdf85..1cdd9926f7 100644 --- a/usr/src/tools/onbld/Checks/Makefile +++ b/usr/src/tools/onbld/Checks/Makefile @@ -27,9 +27,7 @@ include ../../Makefile.tools -SUBDIRS= -$(BUILDPY2TOOLS)SUBDIRS += py2 -$(BUILDPY3TOOLS)SUBDIRS += py3 +SUBDIRS=py3 all := TARGET= all install := TARGET= install diff --git a/usr/src/tools/onbld/Checks/py2/Makefile b/usr/src/tools/onbld/Checks/py2/Makefile deleted file mode 100644 index 40b2b41255..0000000000 --- a/usr/src/tools/onbld/Checks/py2/Makefile +++ /dev/null @@ -1,45 +0,0 @@ -# -# 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 (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. -# - -# Copyright 2010, Richard Lowe -# Copyright 2014 Garrett D'Amore <garrett@damore.org> -# Copyright 2016, Joyent, Inc. -# Copyright 2018 OmniOS Community Edition (OmniOSce) Association. - -include ../Makefile.com - -PYVER = $(PYTHON_VERSION) -PYPKGVERS = $(PYTHON_PKGVERS) -PYOBJS = $(PYSRCS:%.py=%.pyc) - -include ../../../Makefile.python - -all: $(PYVERSOJBS) - -install: all $(ROOTPYFILES) - -clean: - -clobber: clean pyclobber diff --git a/usr/src/tools/onbld/Makefile b/usr/src/tools/onbld/Makefile index 2127334ae7..8dcf63aca0 100644 --- a/usr/src/tools/onbld/Makefile +++ b/usr/src/tools/onbld/Makefile @@ -27,9 +27,7 @@ include ../Makefile.tools -SUBDIRS=Checks Scm -$(BUILDPY2TOOLS)SUBDIRS += py2 -$(BUILDPY3TOOLS)SUBDIRS += py3 +SUBDIRS=Checks Scm py3 all := TARGET= all install := TARGET= install diff --git a/usr/src/tools/onbld/Scm/Makefile b/usr/src/tools/onbld/Scm/Makefile index b6f18bdf85..2987a8bb8e 100644 --- a/usr/src/tools/onbld/Scm/Makefile +++ b/usr/src/tools/onbld/Scm/Makefile @@ -27,9 +27,7 @@ include ../../Makefile.tools -SUBDIRS= -$(BUILDPY2TOOLS)SUBDIRS += py2 -$(BUILDPY3TOOLS)SUBDIRS += py3 +SUBDIRS= py3 all := TARGET= all install := TARGET= install diff --git a/usr/src/tools/onbld/Scm/py2/Makefile b/usr/src/tools/onbld/Scm/py2/Makefile deleted file mode 100644 index 40b2b41255..0000000000 --- a/usr/src/tools/onbld/Scm/py2/Makefile +++ /dev/null @@ -1,45 +0,0 @@ -# -# 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 (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. -# - -# Copyright 2010, Richard Lowe -# Copyright 2014 Garrett D'Amore <garrett@damore.org> -# Copyright 2016, Joyent, Inc. -# Copyright 2018 OmniOS Community Edition (OmniOSce) Association. - -include ../Makefile.com - -PYVER = $(PYTHON_VERSION) -PYPKGVERS = $(PYTHON_PKGVERS) -PYOBJS = $(PYSRCS:%.py=%.pyc) - -include ../../../Makefile.python - -all: $(PYVERSOJBS) - -install: all $(ROOTPYFILES) - -clean: - -clobber: clean pyclobber diff --git a/usr/src/tools/onbld/py2/Makefile b/usr/src/tools/onbld/py2/Makefile deleted file mode 100644 index 5b372bc0ce..0000000000 --- a/usr/src/tools/onbld/py2/Makefile +++ /dev/null @@ -1,45 +0,0 @@ -# -# 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 (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. -# - -# Copyright 2010, Richard Lowe -# Copyright 2014 Garrett D'Amore <garrett@damore.org> -# Copyright 2016, Joyent, Inc. -# Copyright 2018 OmniOS Community Edition (OmniOSce) Association. - -include ../Makefile.com - -PYVER = $(PYTHON_VERSION) -PYPKGVERS = $(PYTHON_PKGVERS) -PYOBJS = $(PYSRCS:%.py=%.pyc) - -include ../../Makefile.python - -all: $(PYVERSOJBS) - -install: all $(ROOTPYFILES) - -clean: - -clobber: clean pyclobber diff --git a/usr/src/tools/scripts/Makefile b/usr/src/tools/scripts/Makefile index f28b285b14..ae74fc39a1 100644 --- a/usr/src/tools/scripts/Makefile +++ b/usr/src/tools/scripts/Makefile @@ -136,7 +136,7 @@ all: $(SHFILES) $(PERLFILES) $(PERLMODULES) $(PYFILES) \ $(MAN1ONBLDFILES) $(MAKEFILES) $(SCRIPTS) onu.sh: onu.sh.in - $(SED) -e "s:@PYTHON_VERSION@:$(PYTHON_VERSION):g" < onu.sh.in > $@ + $(SED) -e "s:@PYTHON_VERSION@:$(PYTHON3_VERSION):g" < onu.sh.in > $@ $(ROOTONBLDBIN)/git-nits: $(RM) $(ROOTONBLDBIN)/git-nits |