pkgsrc-Changes archive

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

CVS commit: pkgsrc



Module Name:    pkgsrc
Committed By:   nia
Date:           Wed Oct 19 13:37:22 UTC 2022

Modified Files:
        pkgsrc/lang/python: versioned_dependencies.mk
Added Files:
        pkgsrc/security/py-cryptography: dependency.mk

Log Message:
python: Special handling of py-cryptography for versioned_dependencies.mk


To generate a diff of this commit:
cvs rdiff -u -r1.86 -r1.87 pkgsrc/lang/python/versioned_dependencies.mk
cvs rdiff -u -r0 -r1.1 pkgsrc/security/py-cryptography/dependency.mk

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/lang/python/versioned_dependencies.mk
diff -u pkgsrc/lang/python/versioned_dependencies.mk:1.86 pkgsrc/lang/python/versioned_dependencies.mk:1.87
--- pkgsrc/lang/python/versioned_dependencies.mk:1.86   Sun Sep 11 18:10:43 2022
+++ pkgsrc/lang/python/versioned_dependencies.mk        Wed Oct 19 13:37:21 2022
@@ -1,4 +1,4 @@
-# $NetBSD: versioned_dependencies.mk,v 1.86 2022/09/11 18:10:43 wiz Exp $
+# $NetBSD: versioned_dependencies.mk,v 1.87 2022/10/19 13:37:21 nia Exp $
 #
 # This file determines which separate distribution of a Python
 # package is used as dependency, depending on the Python version
@@ -49,7 +49,11 @@ _PKG_MATCHED=        no
 pkg:=  ${pattern:C/:.*//}
 type:= ${pattern:C/[^:]*//}
 .  for name py2dir py3dir in ${_SUPPORTED_PACKAGES}
-.    if "${pkg}" == "${name}"
+.    if "${pkg}" == "cryptography"
+# Special due to Rust handling.
+_PKG_MATCHED=  yes
+.      include "../../security/py-cryptography/dependency.mk"
+.    elif "${pkg}" == "${name}"
 _PKG_MATCHED=  yes
 .      if ${_PYTHON_VERSION} == 27
 dir:=  ${py2dir}

Added files:

Index: pkgsrc/security/py-cryptography/dependency.mk
diff -u /dev/null pkgsrc/security/py-cryptography/dependency.mk:1.1
--- /dev/null   Wed Oct 19 13:37:22 2022
+++ pkgsrc/security/py-cryptography/dependency.mk       Wed Oct 19 13:37:21 2022
@@ -0,0 +1,40 @@
+# $NetBSD: dependency.mk,v 1.1 2022/10/19 13:37:21 nia Exp $
+#
+# Not for public use - use through versioned_dependencies.mk.
+#
+# User-settable variables:
+#
+# PYCRYPTOGRAPHY_TYPE
+#      Type of py-cryptography implementation used.
+#
+#      Possible values: c rust
+#      Default: rust on platforms were Rust is supported
+#
+
+.include "../../mk/bsd.fast.prefs.mk"
+
+.include "../../lang/rust/platform.mk"
+.if ${PLATFORM_SUPPORTS_RUST:tl} == "yes" && empty(_PYTHON_VERSION:M2*)
+PYCRYPTOGRAPHY_TYPE?=  rust
+.else
+PYCRYPTOGRAPHY_TYPE?=  c
+.endif
+
+.include "../../lang/python/pyversion.mk"
+.if ${PYCRYPTOGRAPHY_TYPE:tl} == "rust"
+PYCRYPTOGRAPHY_VERSION?=       cryptography>=0
+PYCRYPTOGRAPHY_DIR?=           security/py-cryptography
+.else
+PYCRYPTOGRAPHY_VERSION?=       cryptography>=0<3.4
+PYCRYPTOGRAPHY_DIR?=           security/py27-cryptography
+.endif
+
+.if "${type}" == ":build"
+BUILD_DEPENDS:=        ${BUILD_DEPENDS} ${PYPKGPREFIX}-${PYCRYPTOGRAPHY_VERSION}:../../${PYCRYPTOGRAPHY_DIR}
+.elif "${type}" == ":test"
+TEST_DEPENDS:= ${TEST_DEPENDS} ${PYPKGPREFIX}-${PYCRYPTOGRAPHY_VERSION}:../../${PYCRYPTOGRAPHY_DIR}
+.elif "${type}" == ":tool"
+TOOL_DEPENDS:= ${TOOL_DEPENDS} ${PYPKGPREFIX}-${PYCRYPTOGRAPHY_VERSION}:../../${PYCRYPTOGRAPHY_DIR}
+.else
+DEPENDS:=      ${DEPENDS} ${PYPKGPREFIX}-${PYCRYPTOGRAPHY_VERSION}:../../${PYCRYPTOGRAPHY_DIR}
+.endif



Home | Main Index | Thread Index | Old Index