pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/lang/python Let pkglint fix indentation of preprocessi...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/2e20b4260734
branches:  trunk
changeset: 349502:2e20b4260734
user:      rillig <rillig%pkgsrc.org@localhost>
date:      Sat Jul 09 10:00:26 2016 +0000

description:
Let pkglint fix indentation of preprocessing directives.

diffstat:

 lang/python/extension.mk              |  12 +++---
 lang/python/pyversion.mk              |  60 +++++++++++++++++-----------------
 lang/python/versioned_dependencies.mk |  54 +++++++++++++++---------------
 3 files changed, 63 insertions(+), 63 deletions(-)

diffs (239 lines):

diff -r bd42cb274d0a -r 2e20b4260734 lang/python/extension.mk
--- a/lang/python/extension.mk  Sat Jul 09 09:54:27 2016 +0000
+++ b/lang/python/extension.mk  Sat Jul 09 10:00:26 2016 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: extension.mk,v 1.47 2016/05/30 10:31:16 wiz Exp $
+# $NetBSD: extension.mk,v 1.48 2016/07/09 10:00:26 rillig Exp $
 
 .include "../../lang/python/pyversion.mk"
 
@@ -35,11 +35,11 @@
 do-install:
        (cd ${WRKSRC}/${PYSETUPSUBDIR} && ${SETENV} ${INSTALL_ENV} ${MAKE_ENV} \
         ${PYTHONBIN} ${PYSETUP} ${PYSETUPARGS} "install" ${_PYSETUPINSTALLARGS})
-.if !target(do-test) && !(defined(TEST_TARGET) && !empty(TEST_TARGET))
+.  if !target(do-test) && !(defined(TEST_TARGET) && !empty(TEST_TARGET))
 do-test:
        (cd ${WRKSRC}/${PYSETUPSUBDIR} && ${SETENV} ${MAKE_ENV} ${PYTHONBIN} \
         ${PYSETUP} ${PYSETUPARGS} ${PYSETUPTESTTARGET} ${PYSETUPTESTARGS})
-.endif
+.  endif
 
 .endif
 
@@ -62,11 +62,11 @@
 # prepare Python>=3.2 bytecode file location change
 # http://www.python.org/dev/peps/pep-3147/
 .if empty(_PYTHON_VERSION:M2?)
-PY_PEP3147?=   yes
+PY_PEP3147?=           yes
 .endif
 .if defined(PY_PEP3147) && !empty(PY_PEP3147:M[yY][eE][sS])
-PLIST_AWK+=    -f ${PKGSRCDIR}/lang/python/plist-python.awk
-PLIST_AWK_ENV+=        PYVERS="${PYVERSSUFFIX:S/.//}"
+PLIST_AWK+=            -f ${PKGSRCDIR}/lang/python/plist-python.awk
+PLIST_AWK_ENV+=                PYVERS="${PYVERSSUFFIX:S/.//}"
 PRINT_PLIST_AWK+=      /^[^@]/ && /[^\/]+\.py[co]$$/ {
 PRINT_PLIST_AWK+=      gsub(/__pycache__\//, "")
 PRINT_PLIST_AWK+=      gsub(/opt-1\.pyc$$/, "pyo")
diff -r bd42cb274d0a -r 2e20b4260734 lang/python/pyversion.mk
--- a/lang/python/pyversion.mk  Sat Jul 09 09:54:27 2016 +0000
+++ b/lang/python/pyversion.mk  Sat Jul 09 10:00:26 2016 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: pyversion.mk,v 1.120 2016/05/19 11:45:36 jperkin Exp $
+# $NetBSD: pyversion.mk,v 1.121 2016/07/09 10:00:26 rillig Exp $
 
 # This file determines which Python version is used as a dependency for
 # a package.
@@ -73,10 +73,10 @@
 # optionally handled quoted package names
 .if defined(PKGNAME_REQD) && !empty(PKGNAME_REQD:Mpy[0-9][0-9]-*) || \
     defined(PKGNAME_REQD) && !empty(PKGNAME_REQD:M*-py[0-9][0-9]-*)
-PYTHON_VERSION_REQD?= ${PKGNAME_REQD:C/(^.*-|^)py([0-9][0-9])-.*/\2/}
+PYTHON_VERSION_REQD?=  ${PKGNAME_REQD:C/(^.*-|^)py([0-9][0-9])-.*/\2/}
 .elif defined(PKGNAME_OLD) && !empty(PKGNAME_OLD:Mpy[0-9][0-9]-*) || \
       defined(PKGNAME_OLD) && !empty(PKGNAME_OLD:M*-py[0-9][0-9]-*)
-PYTHON_VERSION_REQD?= ${PKGNAME_OLD:C/(^.*-|^)py([0-9][0-9])-.*/\2/}
+PYTHON_VERSION_REQD?=  ${PKGNAME_OLD:C/(^.*-|^)py([0-9][0-9])-.*/\2/}
 .endif
 
 .include "../../mk/bsd.prefs.mk"
@@ -90,10 +90,10 @@
 
 # transform the list into individual variables
 .for pv in ${PYTHON_VERSIONS_ACCEPTED}
-.if empty(PYTHON_VERSIONS_INCOMPATIBLE:M${pv})
+.  if empty(PYTHON_VERSIONS_INCOMPATIBLE:M${pv})
 _PYTHON_VERSION_${pv}_OK=      yes
 _PYTHON_VERSIONS_ACCEPTED+=    ${pv}
-.endif
+.  endif
 .endfor
 
 #
@@ -103,24 +103,24 @@
 # if a version is explicitely required, take it
 .if defined(PYTHON_VERSION_REQD)
 # but check if it is acceptable first, error out otherwise
-. if defined(_PYTHON_VERSION_${PYTHON_VERSION_REQD}_OK)
+.  if defined(_PYTHON_VERSION_${PYTHON_VERSION_REQD}_OK)
 _PYTHON_VERSION=       ${PYTHON_VERSION_REQD}
-. endif
+.  endif
 .else
 # if the default is accepted, it is first choice
-. if !defined(_PYTHON_VERSION)
-. if defined(_PYTHON_VERSION_${PYTHON_VERSION_DEFAULT}_OK)
+.  if !defined(_PYTHON_VERSION)
+.    if defined(_PYTHON_VERSION_${PYTHON_VERSION_DEFAULT}_OK)
 _PYTHON_VERSION=       ${PYTHON_VERSION_DEFAULT}
-. endif
-. endif
+.    endif
+.  endif
 # prefer an already installed version, in order of "accepted"
-. if !defined(_PYTHON_VERSION)
-. for pv in ${PYTHON_VERSIONS_ACCEPTED}
-. if defined(_PYTHON_VERSION_${pv}_OK)
+.  if !defined(_PYTHON_VERSION)
+.    for pv in ${PYTHON_VERSIONS_ACCEPTED}
+.      if defined(_PYTHON_VERSION_${pv}_OK)
 _PYTHON_VERSION?=      ${pv}
-. endif
-. endfor
-. endif
+.      endif
+.    endfor
+.  endif
 .endif
 
 #
@@ -135,27 +135,27 @@
 
 # Additional CONFLICTS
 .if ${PYTHON_SELF_CONFLICT:U:tl} == "yes"
-.for i in ${PYTHON_VERSIONS_ACCEPTED:N${_PYTHON_VERSION}}
-CONFLICTS +=   ${PKGNAME:S/py${_PYTHON_VERSION}/py${i}/:C/-[0-9].*$/-[0-9]*/}
-.endfor
+.  for i in ${PYTHON_VERSIONS_ACCEPTED:N${_PYTHON_VERSION}}
+CONFLICTS+=    ${PKGNAME:S/py${_PYTHON_VERSION}/py${i}/:C/-[0-9].*$/-[0-9]*/}
+.  endfor
 .endif # PYCONFLICTS
 
 #
 PLIST_VARS+=   py2x py3x
 
 .if empty(_PYTHON_VERSION:Mnone)
-PYPACKAGE=     python${_PYTHON_VERSION}
-PYVERSSUFFIX=  ${_PYTHON_VERSION:C/^([0-9])/\1./1}
-BUILDLINK_API_DEPENDS.${PYPACKAGE}?=           ${PYPACKAGE}>=${PYVERSSUFFIX}
-PYPKGSRCDIR=   ../../lang/${PYPACKAGE}
-PYDEPENDENCY=  ${BUILDLINK_API_DEPENDS.${PYPACKAGE}}:${PYPKGSRCDIR}
-PYPKGPREFIX=   py${_PYTHON_VERSION}
+PYPACKAGE=                             python${_PYTHON_VERSION}
+PYVERSSUFFIX=                          ${_PYTHON_VERSION:C/^([0-9])/\1./1}
+BUILDLINK_API_DEPENDS.${PYPACKAGE}?=   ${PYPACKAGE}>=${PYVERSSUFFIX}
+PYPKGSRCDIR=                           ../../lang/${PYPACKAGE}
+PYDEPENDENCY=                          ${BUILDLINK_API_DEPENDS.${PYPACKAGE}}:${PYPKGSRCDIR}
+PYPKGPREFIX=                           py${_PYTHON_VERSION}
 .endif
 .if !empty(_PYTHON_VERSION:M3*)
-PLIST.py3x=    yes
+PLIST.py3x=                            yes
 .endif
 .if !empty(_PYTHON_VERSION:M2*)
-PLIST.py2x=    yes
+PLIST.py2x=                            yes
 .endif
 
 PTHREAD_OPTS+= require
@@ -196,10 +196,10 @@
                        { gsub(/${PYLIB:S|/|\\/|g}/, "$${PYLIB}") }
 .endif
 
-ALL_ENV+=      PYTHON=${PYTHONBIN}
+ALL_ENV+=              PYTHON=${PYTHONBIN}
 .if defined(USE_CMAKE)
 # used by FindPythonInterp.cmake and FindPythonLibs.cmake
-CMAKE_ARGS+=   -DPYVERSSUFFIX:STRING=${PYVERSSUFFIX}
+CMAKE_ARGS+=           -DPYVERSSUFFIX:STRING=${PYVERSSUFFIX}
 # set this explicitly, as by default it will prefer the built in framework
 CMAKE_ARGS.Darwin+=    -DPYTHON_INCLUDE_DIR:PATH=${BUILDLINK_DIR}/${PYINC}
 CMAKE_ARGS.Darwin+=    -DPYTHON_INCLUDE_PATH:PATH=${BUILDLINK_DIR}/${PYINC}
diff -r bd42cb274d0a -r 2e20b4260734 lang/python/versioned_dependencies.mk
--- a/lang/python/versioned_dependencies.mk     Sat Jul 09 09:54:27 2016 +0000
+++ b/lang/python/versioned_dependencies.mk     Sat Jul 09 10:00:26 2016 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: versioned_dependencies.mk,v 1.24 2016/06/30 18:03:46 wiz Exp $
+# $NetBSD: versioned_dependencies.mk,v 1.25 2016/07/09 10:00:26 rillig Exp $
 #
 # This file determines which separate distribution of a Python
 # package is used as dependency, depending on the Python version
@@ -15,41 +15,41 @@
 
 .include "../../lang/python/pyversion.mk"
 
-_SUPPORTED_PACKAGES=# empty
-_SUPPORTED_PACKAGES+=Pmw x11/py-Pmw x11/py-Pmw2
-_SUPPORTED_PACKAGES+=X textproc/py-X2 textproc/py-X
-_SUPPORTED_PACKAGES+=cairo graphics/py-cairo graphics/py-cairo3
-_SUPPORTED_PACKAGES+=dateutil time/py-dateutil time/py-dateutil
-_SUPPORTED_PACKAGES+=dialog devel/py-dialog2 devel/py-dialog
-_SUPPORTED_PACKAGES+=ephem math/py-ephem math/py-ephem3
-_SUPPORTED_PACKAGES+=flup www/py-flup www/py-flup3
-_SUPPORTED_PACKAGES+=gobject devel/py-gobject devel/py-gobject3
-_SUPPORTED_PACKAGES+=google-api-python-client www/py-google-api-python-client www/py-google-api-python-client-py3
-_SUPPORTED_PACKAGES+=jsonlib textproc/py-jsonlib textproc/py-jsonlib3
-_SUPPORTED_PACKAGES+=python-digest www/py-python-digest www/py-python3-digest
+_SUPPORTED_PACKAGES=   # empty
+_SUPPORTED_PACKAGES+=  Pmw x11/py-Pmw x11/py-Pmw2
+_SUPPORTED_PACKAGES+=  X textproc/py-X2 textproc/py-X
+_SUPPORTED_PACKAGES+=  cairo graphics/py-cairo graphics/py-cairo3
+_SUPPORTED_PACKAGES+=  dateutil time/py-dateutil time/py-dateutil
+_SUPPORTED_PACKAGES+=  dialog devel/py-dialog2 devel/py-dialog
+_SUPPORTED_PACKAGES+=  ephem math/py-ephem math/py-ephem3
+_SUPPORTED_PACKAGES+=  flup www/py-flup www/py-flup3
+_SUPPORTED_PACKAGES+=  gobject devel/py-gobject devel/py-gobject3
+_SUPPORTED_PACKAGES+=  google-api-python-client www/py-google-api-python-client www/py-google-api-python-client-py3
+_SUPPORTED_PACKAGES+=  jsonlib textproc/py-jsonlib textproc/py-jsonlib3
+_SUPPORTED_PACKAGES+=  python-digest www/py-python-digest www/py-python3-digest
 
 .for pattern in ${PYTHON_VERSIONED_DEPENDENCIES}
 _PKG_MATCHED=  no
 pkg:=  ${pattern:C/:.*//}
 type:= ${pattern:C/[^:]*//}
-.for name py2dir py3dir in ${_SUPPORTED_PACKAGES}
-.if "${pkg}" == "${name}"
+.  for name py2dir py3dir in ${_SUPPORTED_PACKAGES}
+.    if "${pkg}" == "${name}"
 _PKG_MATCHED=  yes
-.if ${PYPKGPREFIX} == "py27"
+.      if ${PYPKGPREFIX} == "py27"
 dir:=  ${py2dir}
-.else
+.      else
 dir:=  ${py3dir}
-.endif
-.if "${type}" == ":link"
+.      endif
+.      if "${type}" == ":link"
 .include "../../${dir}/buildlink3.mk"
-.elif "${type}" == ":build"
+.      elif "${type}" == ":build"
 BUILD_DEPENDS:=        ${BUILD_DEPENDS} ${PYPKGPREFIX}-${pkg}-[0-9]*:../../${dir}
-.else
+.      else
 DEPENDS:=      ${DEPENDS} ${PYPKGPREFIX}-${pkg}-[0-9]*:../../${dir}
-.endif
-.endif
+.      endif
+.    endif
+.  endfor
+.  if ${_PKG_MATCHED} == "no"
+PKG_FAIL_REASON+=      "${pkg} unsupported in PYTHON_VERSIONED_DEPENDENCIES"
+.  endif
 .endfor
-.if ${_PKG_MATCHED} == "no"
-PKG_FAIL_REASON+=      "${pkg} unsupported in PYTHON_VERSIONED_DEPENDENCIES"
-.endif
-.endfor



Home | Main Index | Thread Index | Old Index