diff --git a/.github/workflows/packages.yml b/.github/workflows/packages.yml new file mode 100644 index 000000000000000..766f5837b087762 --- /dev/null +++ b/.github/workflows/packages.yml @@ -0,0 +1,84 @@ +name: builder + +on: + workflow_dispatch: + push: + schedule: + - cron: '30 5 * * *' + +jobs: + packages: + runs-on: ubuntu-24.04 + steps: + - name: Check out the repo + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: merge upstream + run: | + git remote add upstream https://github.com/python/cpython.git + git fetch upstream + git -c user.name=Github -c user.email=none merge upstream/main + + - name: Cache ccache + uses: actions/cache@v4 + with: + path: /home/runner/.cache/ccache + key: ccache + + - name: Prepare build environment + run: | + sudo DEBIAN_FRONTEND=noninteractive apt update && sudo DEBIAN_FRONTEND=noninteractive apt install -y --no-install-recommends sbuild mmdebstrap debian-archive-keyring ccache uidmap + + mkdir -p "$HOME/.cache/sbuild" + # shellcheck disable=SC2016 + mmdebstrap --variant=buildd --include=apt,ccache,ca-certificates \ + --keyring=/usr/share/keyrings/debian-archive-keyring.gpg \ + --customize-hook='chroot "$1" update-ccache-symlinks' \ + testing "$HOME/.cache/sbuild/testing-amd64.tar" + + ccache --zero-stats --max-size=10.0G + chmod a+X "$HOME" "$HOME/.cache" + chmod -R a+rwX "$HOME/.cache/ccache" + + cat << "EOF" > "$HOME/.sbuildrc" + $build_environment = { "CCACHE_DIR" => "/build/ccache" }; + $path = "/usr/lib/ccache:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games"; + $build_path = "/build/package/"; + $dsc_dir = "package"; + $unshare_bind_mounts = [ { directory => "$HOME/.cache/ccache", mountpoint => "/build/ccache" } ]; + $verbose = 1; + EOF + mkdir "$HOME/apt_repo" + + - name: Run sbuild + run: | + # shellcheck disable=SC2016 + sed -i "1 s/([^)]*)/($(git describe --tags | sed 's/^[^0-9]*//;s/-/./g;s/_/./g')-$(date -u '+%Y%m%d.%H%M%S%N'))/" debian/changelog + sbuild -d testing --chroot-mode=unshare --no-clean-source --no-run-lintian \ + --extra-repository="deb [trusted=yes] https://github.com/defo-project/openssl/raw/packages/ ./" \ + --dpkg-source-opts="-Zgzip -z1 --format=1.0 -sn" --build-dir="$HOME/apt_repo" + cd "$HOME/apt_repo" + apt-ftparchive packages . > Packages + apt-ftparchive release . > Release + +# - name: Test packages +# run: | +# mmdebstrap --verbose --chrooted-customize-hook="curl --ech true --doh-url 'https://1.1.1.1/dns-query' 'https://defo.ie/ech-check.php' | grep 'SSL_ECH_STATUS: success'" \ +# --variant=essential --include=ca-certificates,curl testing /dev/null \ +# "deb [signed-by=/usr/share/keyrings/debian-archive-keyring.gpg] http://deb.debian.org/debian testing main" \ +# "deb [trusted=yes] https://github.com/defo-project/openssl/raw/packages/ /" \ +# "deb [trusted=yes] copy:/$HOME/apt_repo /" + + - name: Upload apt repository + run: | + cd "$HOME/apt_repo" + BRANCH=packages + REPOSITORY="$(printf "%s" "$GITHUB_REPOSITORY" | tr / _)" + echo "echo \"deb [trusted=yes] $GITHUB_SERVER_URL/$GITHUB_REPOSITORY/raw/$BRANCH/ /\" | sudo tee /etc/apt/sources.list.d/$REPOSITORY.list" >> README.md + git init -b "$BRANCH" + git remote add origin "$(echo "$GITHUB_SERVER_URL/$GITHUB_REPOSITORY.git" | sed "s#https://#https://x-access-token:${{ secrets.GITHUB_TOKEN }}@#")" + git add . + git -c user.name=Github -c user.email=none commit --message="Generated with $GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" + git push --force origin "$BRANCH" diff --git a/Doc/library/ssl.rst b/Doc/library/ssl.rst index b7fb1fc07d199f4..054415833d98fb4 100644 --- a/Doc/library/ssl.rst +++ b/Doc/library/ssl.rst @@ -214,7 +214,6 @@ purposes. The context now uses :data:`VERIFY_X509_PARTIAL_CHAIN` and :data:`VERIFY_X509_STRICT` in its default verify flags. - Exceptions ^^^^^^^^^^ @@ -990,6 +989,13 @@ Constants .. versionadded:: 3.6 +.. class:: ECHStatus + + :class:`enum.IntEnum` collection of Encrypted Client Hello (ECH) statuses + returned by :meth:`SSLSocket.get_ech_status`. + + .. versionadded:: TODO XXX + .. data:: Purpose.SERVER_AUTH Option for :func:`create_default_context` and @@ -1294,6 +1300,22 @@ SSL sockets also have the following additional methods and attributes: .. versionadded:: 3.3 +.. method:: SSLSocket.get_ech_retry_config() + + When the status returned by :meth:`SSLSocket.get_ech_status` after completion of the + handshake is :data:`ECHStatus.ECH_STATUS_GREASE_ECH`, this method returns the + configuration value provided by the server to be used for a new connection using + ECH. + + .. versionadded:: TODO XXX + +.. method:: SSLSocket.get_ech_status() + + Gets the status of Encrypted Client Hello (ECH) processing. Returns an + :class:`ECHStatus` instance. + + .. versionadded:: TODO XXX + .. method:: SSLSocket.selected_alpn_protocol() Return the protocol that was selected during the TLS handshake. If @@ -1366,6 +1388,15 @@ SSL sockets also have the following additional methods and attributes: .. versionadded:: 3.2 +.. attribute:: SSLSocket.outer_server_hostname + + Hostname of the server name used in the outer ClientHello when Encrypted Client + Hello (ECH) is used: :class:`str` type, or ``None`` for server-side socket or + if the outer server name was not specified in the constructor or the ECH + configuration. + + .. versionadded:: TODO XXX + .. attribute:: SSLSocket.server_side A boolean which is ``True`` for server-side sockets and ``False`` for @@ -1667,6 +1698,24 @@ to speed up repeated connections from the same clients. .. versionadded:: 3.5 +.. method:: SSLContext.set_ech_config(ech_config) + + Sets an Encrypted Client Hello (ECH) configuration, which may be discovered from + an HTTPS resource record in DNS or from :meth:`SSLSocket.get_ech_retry_config`. + Multiple calls to this functions will accumulate the set of values available for + a connection. + + If the input value provided contains no suitable value (e.g. if it only contains + ECH configuration versions that are not supported), an :class:`SSLError` will be + raised. + + The ech_config parameter should be a bytes-like object containing the raw ECH + configuration. + + This method will raise :exc:`NotImplementedError` if :data:`HAS_ECH` is ``False``. + + .. versionadded:: TODO XXX + .. method:: SSLContext.set_npn_protocols(protocols) Specify which protocols the socket should advertise during the SSL/TLS @@ -1686,6 +1735,28 @@ to speed up repeated connections from the same clients. NPN has been superseded by ALPN +.. method:: SSLContext.set_outer_alpn_protocols(protocols) + + Specify which protocols the socket should advertise during the TLS + handshake in the outer ClientHello when ECH is used. The *protocols* + argument accepts the same values as for + :meth:`~SSLContext.set_alpn_protocols`. + + This method will raise :exc:`NotImplementedError` if :data:`HAS_ECH` is + ``False``. + + .. versionadded:: TODO XXX + +.. method:: SSLContext.set_outer_server_hostname(server_hostname) + + Specify which hostname the socket should advertise during the TLS + handshake in the outer ClientHello when ECH is used. + + This method will raise :exc:`NotImplementedError` if :data:`HAS_ECH` is + ``False``. + + .. versionadded:: TODO XXX + .. attribute:: SSLContext.sni_callback Register a callback function that will be called after the TLS Client Hello @@ -2581,6 +2652,8 @@ provided. - :meth:`~SSLSocket.verify_client_post_handshake` - :meth:`~SSLSocket.unwrap` - :meth:`~SSLSocket.get_channel_binding` + - :meth:`~SSLSocket.get_ech_retry_config` + - :meth:`~SSLSocket.get_ech_status` - :meth:`~SSLSocket.version` When compared to :class:`SSLSocket`, this object lacks the following @@ -2800,6 +2873,52 @@ of TLS/SSL. Some new TLS 1.3 features are not yet available. - TLS 1.3 features like early data, deferred TLS client cert request, signature algorithm configuration, and rekeying are not supported yet. +Encrypted Client Hello +^^^^^^^^^^^^^^^^^^^^^^ + +.. versionadded:: TODO XXX + +Encrypted Client Hello (ECH) allows for encrypting values that have previously only been +included unencrypted in the ClientHello records when establishing a TLS connection. To use +ECH it is necessary to provide configuration values that contain a version, algorithm +parameters, the public key to use for HPKE encryption and the "public_name" that is by +default used for the unencrypted (outer) SNI when ECH is attempted. These configuration +values may be discovered through DNS or through the "retry config" mechanism. + +The following example assumes that you have discovered a set of ECH configuration values +from DNS, or *ech_configs* may be an empty list to rely on the "retry config" mechanism:: + + import socket + import ssl + + + def connect_with_tls_ech(hostname: str, ech_configs: List[str], + use_retry_config: bool=True) -> ssl.SSLSocket: + context = ssl.create_default_context() + for ech_config in ech_configs: + context.set_ech_config(ech_config) + with socket.create_connection((hostname, 443)) as sock: + with context.wrap_socket(sock, server_hostname=hostname) as ssock: + if (ssock.get_ech_status == ECHStatus.ECH_STATUS_GREASE_ECH + and use_retry_config): + return connect_with_ech(hostname, [ssock.get_ech_retry_config()], + False) + return ssock + + hostname = "www.python.org" + ech_configs = [] # Replace with a call to a function to lookup + # ECH configurations in DNS + + ssock = connect_with_tls_ech(hostname, ech_configs) + +The following classes, methods, and attributes will be useful for using ECH: + + - :class:`ECHStatus` + - :meth:`SSLContext.set_ech_config` + - :meth:`SSLContext.set_outer_alpn_protocols` + - :meth:`SSLContext.set_outer_server_hostname` + - :meth:`SSLSocket.get_ech_status` + - :meth:`SSLSocket.get_ech_retry_config` .. seealso:: diff --git a/Lib/ssl.py b/Lib/ssl.py index c8703b046cfd4b3..032e10b32631c75 100644 --- a/Lib/ssl.py +++ b/Lib/ssl.py @@ -150,6 +150,11 @@ lambda name: name.startswith('CERT_'), source=_ssl) +_IntEnum._convert_( + 'ECHStatus', __name__, + lambda name: name.startswith('ECH_STATUS_'), + source=_ssl) + PROTOCOL_SSLv23 = _SSLMethod.PROTOCOL_SSLv23 = _SSLMethod.PROTOCOL_TLS _PROTOCOL_NAMES = {value: name for name, value in _SSLMethod.__members__.items()} @@ -459,7 +464,7 @@ def wrap_socket(self, sock, server_side=False, suppress_ragged_eofs=suppress_ragged_eofs, server_hostname=server_hostname, context=self, - session=session + session=session, ) def wrap_bio(self, incoming, outgoing, server_side=False, @@ -502,16 +507,13 @@ def shim_cb(sslobj, servername, sslctx): self.sni_callback = shim_cb def set_alpn_protocols(self, alpn_protocols): - protos = bytearray() - for protocol in alpn_protocols: - b = bytes(protocol, 'ascii') - if len(b) == 0 or len(b) > 255: - raise SSLError('ALPN protocols must be 1 to 255 in length') - protos.append(len(b)) - protos.extend(b) - + protos = encode_alpn_protocol_list(alpn_protocols) self._set_alpn_protocols(protos) + def set_outer_alpn_protocols(self, alpn_protocols): + protos = encode_alpn_protocol_list(alpn_protocols) + self._set_outer_alpn_protocols(protos) + def _load_windows_store_certs(self, storename, purpose): try: for cert, encoding, trust in enum_certificates(storename): @@ -831,6 +833,14 @@ def context(self): def context(self, ctx): self._sslobj.context = ctx + @property + def outer_server_hostname(self) -> str: + """The server name used in the outer ClientHello.""" + if self._sslobj: + return self._sslobj.get_ech_status()[2] + else: + raise ValueError("No SSL wrapper around " + str(self)) + @property def session(self): """The SSLSession for client socket.""" @@ -968,6 +978,9 @@ def version(self): def verify_client_post_handshake(self): return self._sslobj.verify_client_post_handshake() + def get_ech_status(self): + return ECHStatus(self._sslobj.get_ech_status()[0]) + def _sslcopydoc(func): """Copy docstring from SSLObject to SSLSocket""" @@ -990,13 +1003,16 @@ def __init__(self, *args, **kwargs): @classmethod def _create(cls, sock, server_side=False, do_handshake_on_connect=True, suppress_ragged_eofs=True, server_hostname=None, - context=None, session=None): + context=None, session=None, outer_server_hostname=None): if sock.getsockopt(SOL_SOCKET, SO_TYPE) != SOCK_STREAM: raise NotImplementedError("only stream sockets are supported") if server_side: if server_hostname: raise ValueError("server_hostname can only be specified " "in client mode") + if outer_server_hostname: + raise ValueError("outer_server_hostname can only be specified " + "in client mode") if session is not None: raise ValueError("session can only be specified in " "client mode") @@ -1092,6 +1108,14 @@ def context(self, ctx): self._context = ctx self._sslobj.context = ctx + @property + def outer_server_hostname(self) -> str: + """The server name used in the outer ClientHello.""" + if self._sslobj: + return self._sslobj.get_ech_status()[2] + else: + raise ValueError("No SSL wrapper around " + str(self)) + @property @_sslcopydoc def session(self): @@ -1358,6 +1382,13 @@ def verify_client_post_handshake(self): else: raise ValueError("No SSL wrapper around " + str(self)) + + def get_ech_status(self): + if self._sslobj: + return ECHStatus(self._sslobj.get_ech_status()[0]) + else: + raise ValueError("No SSL wrapper around " + str(self)) + def _real_close(self): self._sslobj = None super()._real_close() @@ -1527,3 +1558,13 @@ def get_server_certificate(addr, ssl_version=PROTOCOL_TLS_CLIENT, def get_protocol_name(protocol_code): return _PROTOCOL_NAMES.get(protocol_code, '') + +def encode_alpn_protocol_list(alpn_protocols): + protos = bytearray() + for protocol in alpn_protocols: + b = bytes(protocol, 'ascii') + if len(b) == 0 or len(b) > 255: + raise SSLError('ALPN protocols must be 1 to 255 in length') + protos.append(len(b)) + protos.extend(b) + return protos diff --git a/Modules/_ssl.c b/Modules/_ssl.c index b6b5ebf094c938a..e2d5c54c0564d72 100644 --- a/Modules/_ssl.c +++ b/Modules/_ssl.c @@ -69,6 +69,10 @@ #include "openssl/bio.h" #include "openssl/dh.h" +#if __has_include("openssl/ech.h") +#include "openssl/ech.h" +#endif + #ifndef OPENSSL_THREADS # error "OPENSSL_THREADS is not defined, Python requires thread-safe OpenSSL" #endif @@ -2020,6 +2024,111 @@ cipher_to_dict(const SSL_CIPHER *cipher) ); } +/*[clinic input] +_ssl._SSLSocket.get_ech_status +[clinic start generated code]*/ + +static PyObject * +_ssl__SSLSocket_get_ech_status_impl(PySSLSocket *self) +/*[clinic end generated code: output=263bf7fc7888e2d6 input=4f68a05d59f39372]*/ +{ +#ifdef OPENSSL_ECH + char *inner_sni = NULL, *outer_sni = NULL; + + if (self->ssl == NULL) { + Py_RETURN_NONE; + } + + int status = SSL_ech_get_status(self->ssl, &inner_sni, &outer_sni); + PyObject *retval = PyTuple_New(3); + PyTuple_SetItem(retval, 0, PyLong_FromLong(status)); + + if (inner_sni != NULL) { + PyTuple_SetItem(retval, 1, PyUnicode_FromString(inner_sni)); + OPENSSL_free(inner_sni); + } else { + PyTuple_SetItem(retval, 1, Py_None); + Py_INCREF(Py_None); + } + + if (outer_sni != NULL) { + PyTuple_SetItem(retval, 2, PyUnicode_FromString(outer_sni)); + OPENSSL_free(outer_sni); + } else { + PyTuple_SetItem(retval, 2, Py_None); + Py_INCREF(Py_None); + } + + return retval; +#else + PyErr_SetString(PyExc_NotImplementedError, "OpenSSL does not have ECH support"); + return NULL; +#endif +} + +/*[clinic input] +_ssl._SSLSocket.get_ech_retry_config +[clinic start generated code]*/ + +static PyObject * +_ssl__SSLSocket_get_ech_retry_config_impl(PySSLSocket *self) +/*[clinic end generated code: output=967da2032df9a37a input=b9b3cee90aedc05d]*/ +{ +#ifdef OPENSSL_ECH + unsigned char *ec; + size_t eclen; + + if (self->ssl == NULL) { + Py_RETURN_NONE; + } + + SSL_ech_get_retry_config(self->ssl, &ec, &eclen); + + return PyBytes_FromStringAndSize((char *)ec, eclen); +#else + PyErr_SetString(PyExc_NotImplementedError, "OpenSSL does not have ECH support"); + return NULL; +#endif +} + +/*[clinic input] +_ssl._SSLSocket.set_outer_server_name + + outer_server_name: str + / +[clinic start generated code]*/ + +static PyObject * +_ssl__SSLSocket_set_outer_server_name_impl(PySSLSocket *self, + const char *outer_server_name) +/*[clinic end generated code: output=24e7c6b7b3c2ce84 input=5f68803fbe85a69c]*/ +{ +#ifdef OPENSSL_ECH + if (self->ssl == NULL) { + Py_RETURN_NONE; + } + + int result; + + if (outer_server_name != NULL) { + result = SSL_ech_set_outer_server_name(self->ssl, outer_server_name, 0); + } else { + /* Do not send an outer SNI */ + result = SSL_ech_set_outer_server_name(self->ssl, NULL, 1); + } + + if (result != 1) { + _setSSLError(get_state_sock(self), NULL, 0, __FILE__, __LINE__); + return NULL; + } + + Py_RETURN_NONE; +#else + PyErr_SetString(PyExc_NotImplementedError, "OpenSSL does not have ECH support"); + return NULL; +#endif +} + /*[clinic input] @critical_section _ssl._SSLSocket.shared_ciphers @@ -2961,6 +3070,9 @@ static PyMethodDef PySSLMethods[] = { _SSL__SSLSOCKET_COMPRESSION_METHODDEF _SSL__SSLSOCKET_SHUTDOWN_METHODDEF _SSL__SSLSOCKET_VERIFY_CLIENT_POST_HANDSHAKE_METHODDEF + _SSL__SSLSOCKET_GET_ECH_STATUS_METHODDEF + _SSL__SSLSOCKET_SET_OUTER_SERVER_NAME_METHODDEF + _SSL__SSLSOCKET_GET_ECH_RETRY_CONFIG_METHODDEF _SSL__SSLSOCKET_GET_UNVERIFIED_CHAIN_METHODDEF _SSL__SSLSOCKET_GET_VERIFIED_CHAIN_METHODDEF {NULL, NULL} @@ -3402,6 +3514,43 @@ _ssl__SSLContext__set_alpn_protocols_impl(PySSLContext *self, Py_RETURN_NONE; } +/*[clinic input] +@critical_section +_ssl._SSLContext._set_outer_alpn_protocols + protos: Py_buffer + / +[clinic start generated code]*/ + +static PyObject * +_ssl__SSLContext__set_outer_alpn_protocols_impl(PySSLContext *self, + Py_buffer *protos) +/*[clinic end generated code: output=823aea95e8dea835 input=b6ddf7d0791afd0e]*/ +{ +#ifdef OPENSSL_ECH + if ((size_t)protos->len > UINT_MAX) { + PyErr_Format(PyExc_OverflowError, + "protocols longer than %u bytes", UINT_MAX); + return NULL; + } + + PyMem_Free(self->alpn_protocols); + self->alpn_protocols = PyMem_Malloc(protos->len); + if (!self->alpn_protocols) { + return PyErr_NoMemory(); + } + memcpy(self->alpn_protocols, protos->buf, protos->len); + self->alpn_protocols_len = (unsigned int)protos->len; + if (SSL_CTX_ech_set_outer_alpn_protos(self->ctx, self->alpn_protocols, self->alpn_protocols_len)) { + return PyErr_NoMemory(); + } + + Py_RETURN_NONE; +#else + PyErr_SetString(PyExc_NotImplementedError, "OpenSSL does not have ECH support"); + return NULL; +#endif +} + /*[clinic input] @critical_section @getter @@ -4517,6 +4666,36 @@ _ssl__SSLContext_set_default_verify_paths_impl(PySSLContext *self) Py_RETURN_NONE; } +/*[clinic input] +_ssl._SSLContext.set_ech_config + + ech_config: Py_buffer + / + +Set the ECH configuration on the SSL context. + +The echconfig parameter should be a bytes-like object containing the raw ECH configuration. +[clinic start generated code]*/ + +static PyObject * +_ssl__SSLContext_set_ech_config_impl(PySSLContext *self, + Py_buffer *ech_config) +/*[clinic end generated code: output=cea53188b338cf80 input=09f9a38c5aaef091]*/ +{ +#ifdef OPENSSL_ECH + if (!SSL_CTX_ech_set1_echconfig(self->ctx, ech_config->buf, ech_config->len)) { + _setSSLError(get_state_ctx(self), NULL, 0, __FILE__, __LINE__); + return NULL; + } + + PyBuffer_Release(ech_config); + Py_RETURN_NONE; +#else + PyErr_SetString(PyExc_NotImplementedError, "OpenSSL does not have ECH support"); + return NULL; +#endif +} + /*[clinic input] @critical_section _ssl._SSLContext.set_ecdh_curve @@ -5153,6 +5332,8 @@ static struct PyMethodDef context_methods[] = { _SSL__SSLCONTEXT_SESSION_STATS_METHODDEF _SSL__SSLCONTEXT_SET_DEFAULT_VERIFY_PATHS_METHODDEF _SSL__SSLCONTEXT_SET_ECDH_CURVE_METHODDEF + _SSL__SSLCONTEXT_SET_ECH_CONFIG_METHODDEF + _SSL__SSLCONTEXT__SET_OUTER_ALPN_PROTOCOLS_METHODDEF _SSL__SSLCONTEXT_CERT_STORE_STATS_METHODDEF _SSL__SSLCONTEXT_GET_CA_CERTS_METHODDEF _SSL__SSLCONTEXT_GET_CIPHERS_METHODDEF @@ -6307,6 +6488,20 @@ sslmodule_init_constants(PyObject *m) ADD_INT_CONST("VERIFY_X509_PARTIAL_CHAIN", X509_V_FLAG_PARTIAL_CHAIN); #endif +#ifdef OPENSSL_ECH + ADD_INT_CONST("ECH_STATUS_BACKEND", SSL_ECH_STATUS_BACKEND); + ADD_INT_CONST("ECH_STATUS_GREASE_ECH", SSL_ECH_STATUS_GREASE_ECH); + ADD_INT_CONST("ECH_STATUS_GREASE", SSL_ECH_STATUS_GREASE); + ADD_INT_CONST("ECH_STATUS_SUCCESS", SSL_ECH_STATUS_SUCCESS); + ADD_INT_CONST("ECH_STATUS_FAILED", SSL_ECH_STATUS_FAILED); + ADD_INT_CONST("ECH_STATUS_BAD_CALL", SSL_ECH_STATUS_BAD_CALL); + ADD_INT_CONST("ECH_STATUS_NOT_TRIED", SSL_ECH_STATUS_NOT_TRIED); + ADD_INT_CONST("ECH_STATUS_BAD_NAME", SSL_ECH_STATUS_BAD_NAME); + ADD_INT_CONST("ECH_STATUS_NOT_CONFIGURED", SSL_ECH_STATUS_NOT_CONFIGURED); + ADD_INT_CONST("ECH_STATUS_FAILED_ECH", SSL_ECH_STATUS_FAILED_ECH); + ADD_INT_CONST("ECH_STATUS_FAILED_ECH_BAD_NAME", SSL_ECH_STATUS_FAILED_ECH_BAD_NAME); +#endif + /* Alert Descriptions from ssl.h */ /* note RESERVED constants no longer intended for use have been removed */ /* http://www.iana.org/assignments/tls-parameters/tls-parameters.xml#tls-parameters-6 */ @@ -6390,6 +6585,13 @@ sslmodule_init_constants(PyObject *m) ADD_OPTION("OP_NO_TICKET", SSL_OP_NO_TICKET); ADD_OPTION("OP_LEGACY_SERVER_CONNECT", SSL_OP_LEGACY_SERVER_CONNECT); +#ifdef OPENSSL_ECH + ADD_OPTION("OP_ECH_GREASE", SSL_OP_ECH_GREASE); + ADD_OPTION("OP_ECH_TRIALDECRYPT", SSL_OP_ECH_TRIALDECRYPT); + ADD_OPTION("OP_ECH_IGNORE_CID", SSL_OP_ECH_IGNORE_CID); + ADD_OPTION("OP_ECH_GREASE_RETRY_CONFIG", SSL_OP_ECH_GREASE_RETRY_CONFIG); + ADD_OPTION("OP_ECH_SPECIFIC_PADDING", SSL_OP_ECH_SPECIFIC_PADDING); +#endif #ifdef SSL_OP_SINGLE_ECDH_USE ADD_OPTION("OP_SINGLE_ECDH_USE", SSL_OP_SINGLE_ECDH_USE); #endif @@ -6505,6 +6707,12 @@ sslmodule_init_constants(PyObject *m) addbool(m, "HAS_PSK", 1); #endif +#ifdef OPENSSL_NO_ECH + addbool(m, "HAS_ECH", 0); +#else + addbool(m, "HAS_ECH", 1); +#endif + #undef addbool #undef ADD_INT_CONST diff --git a/Modules/clinic/_ssl.c.h b/Modules/clinic/_ssl.c.h index 582eef16c132446..55a610c98087bb6 100644 --- a/Modules/clinic/_ssl.c.h +++ b/Modules/clinic/_ssl.c.h @@ -149,6 +149,77 @@ _ssl__SSLSocket_get_unverified_chain(PySSLSocket *self, PyObject *Py_UNUSED(igno return return_value; } +PyDoc_STRVAR(_ssl__SSLSocket_get_ech_status__doc__, +"get_ech_status($self, /)\n" +"--\n" +"\n"); + +#define _SSL__SSLSOCKET_GET_ECH_STATUS_METHODDEF \ + {"get_ech_status", (PyCFunction)_ssl__SSLSocket_get_ech_status, METH_NOARGS, _ssl__SSLSocket_get_ech_status__doc__}, + +static PyObject * +_ssl__SSLSocket_get_ech_status_impl(PySSLSocket *self); + +static PyObject * +_ssl__SSLSocket_get_ech_status(PySSLSocket *self, PyObject *Py_UNUSED(ignored)) +{ + return _ssl__SSLSocket_get_ech_status_impl(self); +} + +PyDoc_STRVAR(_ssl__SSLSocket_get_ech_retry_config__doc__, +"get_ech_retry_config($self, /)\n" +"--\n" +"\n"); + +#define _SSL__SSLSOCKET_GET_ECH_RETRY_CONFIG_METHODDEF \ + {"get_ech_retry_config", (PyCFunction)_ssl__SSLSocket_get_ech_retry_config, METH_NOARGS, _ssl__SSLSocket_get_ech_retry_config__doc__}, + +static PyObject * +_ssl__SSLSocket_get_ech_retry_config_impl(PySSLSocket *self); + +static PyObject * +_ssl__SSLSocket_get_ech_retry_config(PySSLSocket *self, PyObject *Py_UNUSED(ignored)) +{ + return _ssl__SSLSocket_get_ech_retry_config_impl(self); +} + +PyDoc_STRVAR(_ssl__SSLSocket_set_outer_server_name__doc__, +"set_outer_server_name($self, outer_server_name, /)\n" +"--\n" +"\n"); + +#define _SSL__SSLSOCKET_SET_OUTER_SERVER_NAME_METHODDEF \ + {"set_outer_server_name", (PyCFunction)_ssl__SSLSocket_set_outer_server_name, METH_O, _ssl__SSLSocket_set_outer_server_name__doc__}, + +static PyObject * +_ssl__SSLSocket_set_outer_server_name_impl(PySSLSocket *self, + const char *outer_server_name); + +static PyObject * +_ssl__SSLSocket_set_outer_server_name(PySSLSocket *self, PyObject *arg) +{ + PyObject *return_value = NULL; + const char *outer_server_name; + + if (!PyUnicode_Check(arg)) { + _PyArg_BadArgument("set_outer_server_name", "argument", "str", arg); + goto exit; + } + Py_ssize_t outer_server_name_length; + outer_server_name = PyUnicode_AsUTF8AndSize(arg, &outer_server_name_length); + if (outer_server_name == NULL) { + goto exit; + } + if (strlen(outer_server_name) != (size_t)outer_server_name_length) { + PyErr_SetString(PyExc_ValueError, "embedded null character"); + goto exit; + } + return_value = _ssl__SSLSocket_set_outer_server_name_impl(self, outer_server_name); + +exit: + return return_value; +} + PyDoc_STRVAR(_ssl__SSLSocket_shared_ciphers__doc__, "shared_ciphers($self, /)\n" "--\n" @@ -873,6 +944,40 @@ _ssl__SSLContext__set_alpn_protocols(PySSLContext *self, PyObject *arg) return return_value; } +PyDoc_STRVAR(_ssl__SSLContext__set_outer_alpn_protocols__doc__, +"_set_outer_alpn_protocols($self, protos, /)\n" +"--\n" +"\n"); + +#define _SSL__SSLCONTEXT__SET_OUTER_ALPN_PROTOCOLS_METHODDEF \ + {"_set_outer_alpn_protocols", (PyCFunction)_ssl__SSLContext__set_outer_alpn_protocols, METH_O, _ssl__SSLContext__set_outer_alpn_protocols__doc__}, + +static PyObject * +_ssl__SSLContext__set_outer_alpn_protocols_impl(PySSLContext *self, + Py_buffer *protos); + +static PyObject * +_ssl__SSLContext__set_outer_alpn_protocols(PySSLContext *self, PyObject *arg) +{ + PyObject *return_value = NULL; + Py_buffer protos = {NULL, NULL}; + + if (PyObject_GetBuffer(arg, &protos, PyBUF_SIMPLE) != 0) { + goto exit; + } + Py_BEGIN_CRITICAL_SECTION(self); + return_value = _ssl__SSLContext__set_outer_alpn_protocols_impl(self, &protos); + Py_END_CRITICAL_SECTION(); + +exit: + /* Cleanup for protos */ + if (protos.obj) { + PyBuffer_Release(&protos); + } + + return return_value; +} + #if defined(_ssl__SSLContext_verify_mode_HAS_DOCSTR) # define _ssl__SSLContext_verify_mode_DOCSTR _ssl__SSLContext_verify_mode__doc__ #else @@ -1776,6 +1881,41 @@ _ssl__SSLContext_set_default_verify_paths(PySSLContext *self, PyObject *Py_UNUSE return return_value; } +PyDoc_STRVAR(_ssl__SSLContext_set_ech_config__doc__, +"set_ech_config($self, ech_config, /)\n" +"--\n" +"\n" +"Set the ECH configuration on the SSL context.\n" +"\n" +"The echconfig parameter should be a bytes-like object containing the raw ECH configuration."); + +#define _SSL__SSLCONTEXT_SET_ECH_CONFIG_METHODDEF \ + {"set_ech_config", (PyCFunction)_ssl__SSLContext_set_ech_config, METH_O, _ssl__SSLContext_set_ech_config__doc__}, + +static PyObject * +_ssl__SSLContext_set_ech_config_impl(PySSLContext *self, + Py_buffer *ech_config); + +static PyObject * +_ssl__SSLContext_set_ech_config(PySSLContext *self, PyObject *arg) +{ + PyObject *return_value = NULL; + Py_buffer ech_config = {NULL, NULL}; + + if (PyObject_GetBuffer(arg, &ech_config, PyBUF_SIMPLE) != 0) { + goto exit; + } + return_value = _ssl__SSLContext_set_ech_config_impl(self, &ech_config); + +exit: + /* Cleanup for ech_config */ + if (ech_config.obj) { + PyBuffer_Release(&ech_config); + } + + return return_value; +} + PyDoc_STRVAR(_ssl__SSLContext_set_ecdh_curve__doc__, "set_ecdh_curve($self, name, /)\n" "--\n" @@ -2839,4 +2979,4 @@ _ssl_enum_crls(PyObject *module, PyObject *const *args, Py_ssize_t nargs, PyObje #ifndef _SSL_ENUM_CRLS_METHODDEF #define _SSL_ENUM_CRLS_METHODDEF #endif /* !defined(_SSL_ENUM_CRLS_METHODDEF) */ -/*[clinic end generated code: output=4c2af0c8fab7ec4e input=a9049054013a1b77]*/ +/*[clinic end generated code: output=3b9063915c60ea1a input=a9049054013a1b77]*/ diff --git a/configure b/configure index b1ced3106618ba6..71977670cdceeed 100755 --- a/configure +++ b/configure @@ -28951,6 +28951,50 @@ LIBS=$save_LIBS + for ac_header in openssl/ech.h +do : + ac_fn_c_check_header_compile "$LINENO" "openssl/ech.h" "ac_cv_header_openssl_ech_h" "$ac_includes_default" +if test "x$ac_cv_header_openssl_ech_h" = xyes +then : + printf "%s\n" "#define HAVE_OPENSSL_ECH_H 1" >>confdefs.h + have_openssl_ech_h=yes +else $as_nop + have_openssl_ech_h=no +fi + +done +if test "$have_openssl_ech_h" = "yes"; then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OpenSSL ECH support" >&5 +printf %s "checking for OpenSSL ECH support... " >&6; } + ac_fn_check_decl "$LINENO" "SSL_ECH_STATUS_GREASE_ECH" "ac_cv_have_decl_SSL_ECH_STATUS_GREASE_ECH" "#include +" "$ac_c_undeclared_builtin_options" "CFLAGS" +if test "x$ac_cv_have_decl_SSL_ECH_STATUS_GREASE_ECH" = xyes +then : + ac_have_decl=1 +else $as_nop + ac_have_decl=0 +fi +printf "%s\n" "#define HAVE_DECL_SSL_ECH_STATUS_GREASE_ECH $ac_have_decl" >>confdefs.h +if test $ac_have_decl = 1 +then : + +printf "%s\n" "#define OPENSSL_ECH 1" >>confdefs.h + +else $as_nop + +printf "%s\n" "#define OPENSSL_NO_ECH 1" >>confdefs.h + +fi + + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_decl_SSL_ECH_STATUS_GREASE_ECH" >&5 +printf "%s\n" "$ac_cv_have_decl_SSL_ECH_STATUS_GREASE_ECH" >&6; } +else + +printf "%s\n" "#define OPENSSL_NO_ECH 1" >>confdefs.h + +fi + + # ssl module default cipher suite string diff --git a/configure.ac b/configure.ac index 3a55cbc13203933..f35bb405f74e7b5 100644 --- a/configure.ac +++ b/configure.ac @@ -7384,6 +7384,22 @@ WITH_SAVE_ENV([ ]) ]) +AC_CHECK_HEADERS([openssl/ech.h], [have_openssl_ech_h=yes], [have_openssl_ech_h=no]) +if test "$have_openssl_ech_h" = "yes"; then + AC_MSG_CHECKING([for OpenSSL ECH support]) + AC_CHECK_DECLS([SSL_ECH_STATUS_GREASE_ECH], + [AC_DEFINE([OPENSSL_ECH], [1], + [Define if OpenSSL has ECH support])], + [AC_DEFINE([OPENSSL_NO_ECH], [1], + [Define if OpenSSL does not have ECH support])], + [#include ]) + AC_MSG_RESULT([$ac_cv_have_decl_SSL_ECH_STATUS_GREASE_ECH]) +else + AC_DEFINE([OPENSSL_NO_ECH], [1], + [Define if OpenSSL does not have ECH support]) +fi + + # ssl module default cipher suite string AH_TEMPLATE([PY_SSL_DEFAULT_CIPHERS], [Default cipher suites list for ssl module. diff --git a/debian/2to3.1 b/debian/2to3.1 new file mode 100644 index 000000000000000..f896799dea4d5f8 --- /dev/null +++ b/debian/2to3.1 @@ -0,0 +1,41 @@ +.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.40.4. +.TH 2TO3-3.3 "1" "January 2012" "2to3-3.3 3.3" "User Commands" +.SH NAME +2to3-3.3 \- Python2 to Python3 converter +.SH SYNOPSIS +.B 2to3 +[\fIoptions\fR] \fIfile|dir \fR... +.SH OPTIONS +.TP +\fB\-h\fR, \fB\-\-help\fR +show this help message and exit +.TP +\fB\-d\fR, \fB\-\-doctests_only\fR +Fix up doctests only +.TP +\fB\-f\fR FIX, \fB\-\-fix\fR=\fIFIX\fR +Each FIX specifies a transformation; default: all +.TP +\fB\-j\fR PROCESSES, \fB\-\-processes\fR=\fIPROCESSES\fR +Run 2to3 concurrently +.TP +\fB\-x\fR NOFIX, \fB\-\-nofix\fR=\fINOFIX\fR +Prevent a transformation from being run +.TP +\fB\-l\fR, \fB\-\-list\-fixes\fR +List available transformations +.TP +\fB\-p\fR, \fB\-\-print\-function\fR +Modify the grammar so that print() is a function +.TP +\fB\-v\fR, \fB\-\-verbose\fR +More verbose logging +.TP +\fB\-\-no\-diffs\fR +Don't show diffs of the refactoring +.TP +\fB\-w\fR, \fB\-\-write\fR +Write back modified files +.TP +\fB\-n\fR, \fB\-\-nobackups\fR +Don't write backups for modified files diff --git a/debian/2to3.py b/debian/2to3.py new file mode 100755 index 000000000000000..bf4194b64ce0461 --- /dev/null +++ b/debian/2to3.py @@ -0,0 +1,5 @@ +#! /usr/bin/python3 +import sys +from lib2to3.main import main + +sys.exit(main("lib2to3.fixes")) diff --git a/debian/README.Debian b/debian/README.Debian new file mode 100644 index 000000000000000..898e0408de03681 --- /dev/null +++ b/debian/README.Debian @@ -0,0 +1,17 @@ +More documentation and README's for this package can be found in the directory + + /usr/share/doc/python3.6/ + +The upstream documentation can be found after installation +of the python-doc package in the directory + + /usr/share/doc/python3/html + + +A draft of the "Debian Python Policy", mostly needed for Debian package +maintainers can be found in + + /usr/share/doc/python + +Sometime it will be moved to /usr/share/doc/debian-policy in the +debian-policy package. diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 000000000000000..77460b9c2902cdd --- /dev/null +++ b/debian/changelog @@ -0,0 +1,1862 @@ +python3-defaults (3.12.6-1) unstable; urgency=medium + + * Bump version to 3.12.6 + * 2to3: Remove obsolete breaks/replaces. + * Make python3 maintainer scripts more robust for runtime updates. + LP: #2078356. + + -- Matthias Klose Mon, 16 Sep 2024 17:21:13 +0200 + +python3-defaults (3.12.5-1) unstable; urgency=medium + + * Bump version to 3.12.5 + * debpython/files.py: Set LC_ALL="C.UTF-8" before calling dpkg -L to avoid + localization issues (LP: #2075337) + * Bump standards version. + + -- Matthias Klose Thu, 08 Aug 2024 07:30:33 +0200 + +python3-defaults (3.12.4-1) unstable; urgency=medium + + * Bump version to 3.12.4 + * python3: Conflict with python3-distutils. + + -- Matthias Klose Sat, 20 Jul 2024 11:46:46 +0200 + +python3-defaults (3.12.3-1) unstable; urgency=medium + + * Bump version to 3.12.3 + * Drop dependencies on python3-distutils. + * Remove Python 3.11 as a supported version. + + -- Matthias Klose Tue, 09 Jul 2024 13:01:35 +0200 + +python3-defaults (3.12.2-1) unstable; urgency=medium + + [ Stefano Rivera ] + * Migrate to html2text 2.x, which dropped the -pretty flag. + Closes: #1064737. + * Fix typo in py3clean manpage. Thanks JT Hundley. Closes: #1070728. + + [ Matthias Klose ] + * Bump version. + * Depend on libpython3.XYt64-dbg, tighten python3.12 build dependency. + + -- Matthias Klose Mon, 24 Jun 2024 10:23:35 +0200 + +python3-defaults (3.12.1-1) experimental; urgency=medium + + * Default to Python 3.12. + * Bump hardcoded Provides: python3-supported-max to 3.12. + * Stop building the transitional idle3 package. Closes: #1032789. + + -- Matthias Klose Sat, 20 Jan 2024 09:02:48 +0100 + +python3-defaults (3.11.6-1) unstable; urgency=medium + + * Add 3.12 as a supported Python3 version. + * Bump version to 3.11.6. + + -- Matthias Klose Sun, 03 Dec 2023 10:21:41 +0100 + +python3-defaults (3.11.4-5) unstable; urgency=medium + + * Source-only upload. + + -- Piotr Ożarowski Wed, 05 Jul 2023 11:27:27 +0200 + +python3-defaults (3.11.4-4) unstable; urgency=high + + * Fix importlib.util import (-3 regression, closes: 1040316) + + -- Piotr Ożarowski Tue, 04 Jul 2023 19:49:27 +0200 + +python3-defaults (3.11.4-3) unstable; urgency=medium + + * debpython/interpreter.py: Stop using the imp module, removed in 3.12. + Closes: #1040261. + + -- Matthias Klose Tue, 04 Jul 2023 12:08:14 +0200 + +python3-defaults (3.11.4-2) experimental; urgency=medium + + * Add new binary package: python3-all-venv. Closes: #1039988. + + -- Stefano Rivera Sat, 01 Jul 2023 09:38:35 -0400 + +python3-defaults (3.11.4-1) unstable; urgency=medium + + * Bump version to 3.11.4. + + -- Matthias Klose Sun, 25 Jun 2023 14:41:31 +0200 + +python3-defaults (3.11.2-1) unstable; urgency=high + + * Bump version to 3.11.2. Closes: #1031336. + * Bump standards version. + + -- Matthias Klose Wed, 15 Feb 2023 11:07:00 +0100 + +python3-defaults (3.11.1-3) unstable; urgency=medium + + * Update python-policy doc-base metadata. (Closes: #1013185) + * Avoid an unnecessary shell in debpython and py3compile. (Closes: #1025976) + * Avoid use of lsb-release, to ease bootstrapping. + * Avoid circular Build-Depends on python3-minimal, to ease bootstrapping. + * Support the nodoc build profile, to allow bootstrapping. (Closes: #869959) + * py3compile: Correctly parse the PEP-552 (3.7+) expanded bytecode file + header, avoiding unnecessary re-compilation. (Closes: #1006136) + * py3compile: Handle post-2038 mtimes, by treating them as unsigned ints. + + -- Stefano Rivera Sun, 29 Jan 2023 18:22:38 -0400 + +python3-defaults (3.11.1-2) unstable; urgency=medium + + * Provide python3-supported-min and python3-supported-max versioned virtual + packages, to allow modules to easily declare dependencies for all + supported versions. + * Bump Depends to 3.11.1-1. + * Drop support for Python 3.10. + + -- Stefano Rivera Sat, 28 Jan 2023 09:46:57 -0400 + +python3-defaults (3.11.1-1) unstable; urgency=medium + + * Default to python 3.11. + * Bump version to 3.11.1. + * Bump standards version. + + -- Matthias Klose Mon, 02 Jan 2023 16:35:47 +0100 + +python3-defaults (3.10.6-3) unstable; urgency=medium + + * Update python.mk to use distutils from setuptools, to determine build + directory names. Thanks YOKOTA Hiroshi. + * Add --{min,max}-supported to py3versions, thanks Julian Gilbey. + Closes: #1016073 + + -- Stefano Rivera Tue, 15 Nov 2022 21:36:57 +0200 + +python3-defaults (3.10.6-2) unstable; urgency=medium + + [ Matthias Klose ] + * Add 3.11 as a supported Python3 version + * Bump version to 3.10.8. + * Update valgrind suppression file. + + -- Stefano Rivera Fri, 11 Nov 2022 11:10:31 +0200 + +python3-defaults (3.10.6-1) unstable; urgency=medium + + * Bump version to 3.10.6. + + -- Matthias Klose Thu, 11 Aug 2022 14:57:39 +0200 + +python3-defaults (3.10.5-3) unstable; urgency=medium + + * Source-only upload. + + -- Matthias Klose Tue, 19 Jul 2022 16:23:40 +0200 + +python3-defaults (3.10.5-2) unstable; urgency=medium + + * Build a python3-nopie package. + + -- Matthias Klose Sun, 17 Jul 2022 12:13:55 +0200 + +python3-defaults (3.10.5-1) unstable; urgency=medium + + * Bump version to 3.10.5. + * Remove Python 3.9 as a supported version. + + -- Matthias Klose Sun, 17 Jul 2022 12:02:10 +0200 + +python3-defaults (3.10.4-1) unstable; urgency=medium + + * Default to python 3.10. + * Bump version to 3.10.4. + + -- Matthias Klose Sun, 27 Mar 2022 19:53:47 +0200 + +python3-defaults (3.9.8-1) unstable; urgency=medium + + * Bump version to 3.9.8. + + -- Matthias Klose Wed, 17 Nov 2021 16:56:56 +0100 + +python3-defaults (3.9.7-4) experimental; urgency=medium + + * Support 2-digit minor versions in py3versions. + + -- Stefano Rivera Thu, 04 Nov 2021 17:20:48 -0700 + +python3-defaults (3.9.7-3) experimental; urgency=medium + + * Add 3.10 as a supported Python3 version + + -- Matthias Klose Wed, 03 Nov 2021 13:57:32 +0200 + +python3-defaults (3.9.7-1) unstable; urgency=medium + + [ Matthias Klose ] + * Bump version to 3.9.7. + * Bump standards version. + + [ Dimitri John Ledkov ] + * Correct command-not-found XB-Cnf headers LP: #1867157: + - Drop Extra-Commands headers not needed + - Add XB- to ensure Visible-Pkgname actually is included in the binary + package headers + + [ Graham Inggs ] + * Fix py3versions -i for two-digit minor versions. + + -- Matthias Klose Wed, 03 Nov 2021 12:51:45 +0100 + +python3-defaults (3.9.4-1) experimental; urgency=medium + + * Bump version to 3.9.4. + + -- Matthias Klose Tue, 06 Apr 2021 19:28:56 +0200 + +python3-defaults (3.9.2-3) unstable; urgency=medium + + * Ship index.html to unbreak links in python-policy.html. Closes: #985313. + * Don't ship html policy links in the python3.9 doc directory. + Closes: #984961. + + -- Matthias Klose Mon, 05 Apr 2021 14:00:48 +0200 + +python3-defaults (3.9.2-2) unstable; urgency=medium + + * Upload to unstable. + + -- Stefano Rivera Tue, 02 Mar 2021 10:55:41 -0800 + +python3-defaults (3.9.2-1) experimental; urgency=medium + + [ Stefano Rivera ] + * Update Python Policy to describe python3-full and other interpreter + packaging changes. + * Convert Python Policy to Sphinx. + * Add myself to uploaders. + + [ Matthias Klose ] + * Bump version to 3.9.2. + * Make the Sphinx generated documents more compact. + * Clarify that python3-full must not be used neither as a build dependency + nor a recommendation. + * Move the html version of the policy into the python3-dev package. + * policy: Add paragraphs "Removal of the unversioned packages" and + "Unversioned python commands. + + -- Stefano Rivera Tue, 02 Mar 2021 10:37:38 -0800 + +python3-defaults (3.9.2~rc1-1) experimental; urgency=medium + + * Bump version to 3.9.2 rc1. + + [ Stefano Rivera ] + * Improve package descriptions, describing venv, stdlib, and lib2to3 package + contents. + + [ Matthias Klose ] + * Build a python3-full package. + - Depends on ca-certificates. Closes: #960869. + + -- Matthias Klose Thu, 18 Feb 2021 12:16:46 +0100 + +python3-defaults (3.9.1-1) unstable; urgency=medium + + * Bump version to 3.9.1. + + -- Matthias Klose Wed, 23 Dec 2020 07:05:58 +0100 + +python3-defaults (3.9.0-4) unstable; urgency=medium + + * Remove 3.8 as a supported Python3 versions. + + -- Matthias Klose Sun, 06 Dec 2020 11:36:08 +0100 + +python3-defaults (3.9.0-3) unstable; urgency=medium + + * Bump standards version. + + -- Matthias Klose Wed, 18 Nov 2020 21:21:16 +0100 + +python3-defaults (3.9.0-2) experimental; urgency=medium + + * Relax dependencies on packages built by python3-stdlib-extensions. + + -- Matthias Klose Mon, 19 Oct 2020 13:35:56 +0200 + +python3-defaults (3.9.0-1) experimental; urgency=medium + + * Default python3 version to 3.9. + * Drop the venv binary and man page. Closes: #970764. + + -- Matthias Klose Thu, 15 Oct 2020 12:10:47 +0200 + +python3-defaults (3.8.6-1) unstable; urgency=medium + + * Bump version to 3.8.6. + * Re-introduce the the python3-venv package. + + -- Matthias Klose Tue, 13 Oct 2020 21:25:54 +0200 + +python3-defaults (3.8.5-1) experimental; urgency=medium + + [ Scott Kitterman ] + * Policy: Update wheel policy to allow python3 only wheels for packages + (like setuptools) that no longer support python2 (Scott Kitterman). + + [ Matthias Klose ] + * Bump version to 3.8.5. + * Add 3.9 as a supported Python3 version. + * Stop building the python3-venv package. + * Bump debhelper version. + + -- Matthias Klose Thu, 13 Aug 2020 14:51:41 +0200 + +python3-defaults (3.8.2-3) unstable; urgency=medium + + * Remove 3.7 as a supported Python3 versions. + * Fix policy for location for Python 3 local modules. Closes: #884736. + * Policy: Clarify module package naming (Simon McVittie). + * Policy: Prefer to document python3-foo in python-foo-doc (Simon McVittie). + + -- Matthias Klose Tue, 07 Apr 2020 12:43:18 +0200 + +python3-defaults (3.8.2-2) unstable; urgency=medium + + [ Stuart Prescott ] + * py3compile: use unbuffered IO to pass filenames to py_compile + (closes: 953056) + + [ Piotr Ożarowski ] + * Byte compile exception patterns (bcep) changes: + - new "file" type to list just one file + example: file|-4.0|/usr/share/foo/test.py + - ignore lines that start with hash char. (to allow comments) + - tighten checking directory name (partial match was possible before) + - in "re" type's pattern - check relative paths in addition to full path + (i.e. no need to include directory path in the pattern) + example: re|-4.0|/usr/lib/bar|baz/test.*\.py + - only warn about invalid patterns (instead of failing) + + -- Piotr Ożarowski Sat, 21 Mar 2020 17:18:03 +0100 + +python3-defaults (3.8.2-1) unstable; urgency=medium + + * Bump version to 3.8.2. + * Bump standards version. + + -- Matthias Klose Mon, 02 Mar 2020 13:40:23 +0100 + +python3-defaults (3.8.0-3) experimental; urgency=medium + + * Drop the symlinks with the m modifier. + + -- Matthias Klose Sun, 15 Dec 2019 13:49:16 +0100 + +python3-defaults (3.8.0-2) experimental; urgency=medium + + * Bump the defaults version in the python_defaults file as well- + + -- Matthias Klose Tue, 26 Nov 2019 17:31:54 +0100 + +python3-defaults (3.8.0-1) experimental; urgency=medium + + * Default python3 version to 3.8. + * python3-dbg: Provide a python3-dbg-embed.pc pkg-config file. + * Move the pkg-config files into libpython3-dev and libpython3-dbg. + + -- Matthias Klose Mon, 25 Nov 2019 12:38:19 +0100 + +python3-defaults (3.7.5-3) unstable; urgency=medium + + [ Matthias Klose ] + * Update the Python policy for the Python2 removal (Neil Williams). + Closes: #943666. + * Prepare to ship the python*-embed pkg-config files with 3.8 as the + default Python3 version. + + [ Piotr Ożarowski ] + * Remove dh-python dependency from python3-all and python3-dev packages. + Packages should build depend on dh-python or dh-sequence-python3 instead. + + -- Matthias Klose Thu, 14 Nov 2019 15:13:23 +0100 + +python3-defaults (3.7.5-2) experimental; urgency=medium + + * Add 3.8 as a supported Python3 versions. + + -- Matthias Klose Sun, 20 Oct 2019 11:41:55 +0200 + +python3-defaults (3.7.5-1) unstable; urgency=medium + + * Bump version to 3.7.5. + * Bump standards version. + + -- Matthias Klose Wed, 02 Oct 2019 14:31:29 +0200 + +python3-defaults (3.7.3-1) unstable; urgency=medium + + * Bump version to 3.7.3. + + -- Matthias Klose Tue, 26 Mar 2019 11:25:14 +0100 + +python3-defaults (3.7.2-1) unstable; urgency=medium + + * Bump version to 3.7.2. + * Bump standards version. + + -- Matthias Klose Fri, 18 Jan 2019 08:54:49 +0100 + +python3-defaults (3.7.1-3) unstable; urgency=medium + + * Remove 3.6 as a supported Python3 versions. + + -- Matthias Klose Wed, 19 Dec 2018 03:54:07 +0100 + +python3-defaults (3.7.1-2) unstable; urgency=medium + + * Default python3 version to 3.7, targeting sid/buster. + * Fix FTCBFS: Annotate python build dependencies with :any (Helmut Grohne). + Closes: #912899. + + -- Matthias Klose Wed, 21 Nov 2018 13:04:27 +0100 + +python3-defaults (3.7.1-1) experimental; urgency=medium + + * Default python3 version to 3.7. + + -- Matthias Klose Sun, 21 Oct 2018 14:23:45 +0200 + +python3-defaults (3.6.7-1) unstable; urgency=high + + * Really ship the policy in the python3 package, and update from the last + version found in the python package. Closes: #910113. + * Bump version to 3.6.7. + + -- Matthias Klose Sun, 21 Oct 2018 11:21:31 +0200 + +python3-defaults (3.6.6-1) unstable; urgency=medium + + [ Matthias Klose ] + * Fix the idle desktop file. Closes: #901096. + * Install the policy files in the python3 package. Closes: #901486. + * python3-minimal: Pre-Depend on python3.6-minimal. Closes: #901001. + * Bump version to 3.6.6. + + [ Scott Kitterman ] + * Remove myself from uploaders + + -- Matthias Klose Wed, 27 Jun 2018 18:18:20 +0200 + +python3-defaults (3.6.5-5) experimental; urgency=medium + + * Fix typo in the defaults file. Closes: #900937, #900949. + + -- Matthias Klose Thu, 07 Jun 2018 17:57:53 +0200 + +python3-defaults (3.6.5-4) experimental; urgency=medium + + * Update Vcs attributes. + * Add Python 3.7 to the list of supported Python3 versions. + + -- Matthias Klose Wed, 06 Jun 2018 18:26:50 +0200 + +python3-defaults (3.6.5-3) unstable; urgency=medium + + * Update valgrind support file. LP: #1513364. + * debian/control.in (Michael Vogt): + - add Cnf-Visible-Pkgname hint to ensure command-not-found recommends + installing "python3" instead of "python3-minimal" when it is missing. + + -- Matthias Klose Tue, 10 Apr 2018 11:48:03 +0200 + +python3-defaults (3.6.5-2) unstable; urgency=medium + + * Distinguish between python3.6 and python3-stdlib-extensions versions. + Closes: #894168. + * python3-venv: Depend on python3-distutils. + + -- Matthias Klose Mon, 02 Apr 2018 07:06:32 +0200 + +python3-defaults (3.6.5-1) unstable; urgency=medium + + [ Matthias Klose ] + * Bump version to 3.6.5. + + [ Michael Vogt ] + * debian/control.in: LP: #1752415 + - add "XB-Cnf-Extra-Commands: python" to ensure command-not-found + outputs the python3 package when searching for "python" + - add XB-Cnf-Priority-Bonus to ensure python3 is listed on the + top when typing "python" + + -- Matthias Klose Sat, 31 Mar 2018 16:26:32 +0800 + +python3-defaults (3.6.5~rc1-1) unstable; urgency=medium + + * Bump version to 3.6.5~rc1. + * Remove dh-python dependency from python3. + * Add dh-python and python3-distutils dependencies to python3-all and + python3-dev. + + -- Matthias Klose Sun, 25 Mar 2018 19:05:26 +0800 + +python3-defaults (3.6.4-1) unstable; urgency=medium + + * Bump version to 3.6.4. + * 2to3: Depend on python3-lib2to3 and provide the 2to3 launcher. + + -- Matthias Klose Fri, 29 Dec 2017 23:53:39 +0100 + +python3-defaults (3.6.4~rc1-2) unstable; urgency=medium + + * 2to3: Fix breaks/replaces relation with python. Closes: #884418. + + -- Matthias Klose Fri, 15 Dec 2017 08:24:00 +0100 + +python3-defaults (3.6.4~rc1-1) unstable; urgency=medium + + * Bump version to 3.6.4~rc1. + * Stop using priority extra for the -dbg packages. + * Build a 2to3 package. + + -- Matthias Klose Wed, 13 Dec 2017 23:52:01 +0100 + +python3-defaults (3.6.3-2) unstable; urgency=medium + + * Remove python3.5 as a supported Python3 version. + + -- Matthias Klose Thu, 26 Oct 2017 21:09:05 +0200 + +python3-defaults (3.6.3-1) unstable; urgency=medium + + * Bump version to 3.6.3. + * Update more references from 3.5 to 3.6. + * Rename the idle3 package to idle, keep a transitional idle3 package. + * Fix idle script to run with Python3. + * Bump standards version to 4.1.1. + + -- Matthias Klose Tue, 10 Oct 2017 08:36:04 +0200 + +python3-defaults (3.6.2-1) experimental; urgency=medium + + * Default python3 version to 3.6. + * Bump standards version to 4.1.0. + * Change policy format from debiandoc SGML to DocBook/XML (W. Martin Borgert). + Closes: #871526, #872581. + * Fix some invalid escape sequences that make autopkgtests fail by causing + warnings on stderr (Michael Hudson-Doyle). + * python3-doc, python3-examples: Mark M-A: foreign. + + -- Matthias Klose Mon, 18 Sep 2017 19:52:28 +0200 + +python3-defaults (3.5.3-3) unstable; urgency=medium + + * Upload to unstable + * Update python3 version number in debian/README.Debian (Closes: + #826565) + * Add debian/watch, thanks to Taylor Kline for the patch (Closes: + #850789) + * No VCS cruft in the tarball this time (Closes: #854974) + * Bump standards version to 4.0.0 without further change + * Delete ancient Breaks/Replaces for idle3 and python3-minimal + + -- Scott Kitterman Wed, 28 Jun 2017 23:07:12 -0400 + +python3-defaults (3.5.3-2) experimental; urgency=medium + + * Add python3.6 to supported python3 versions for experimental + + -- Scott Kitterman Fri, 16 Jun 2017 22:09:52 -0400 + +python3-defaults (3.5.3-1) unstable; urgency=medium + + * Bump version to 3.5.3. + + -- Matthias Klose Fri, 20 Jan 2017 11:03:28 +0100 + +python3-defaults (3.5.1-4) unstable; urgency=medium + + * Bump standards version. + * Rebuild to pick up the GNU triplet change on i386 archs. Addresses: #826128. + + -- Matthias Klose Fri, 03 Jun 2016 01:34:07 +0200 + +python3-defaults (3.5.1-3) unstable; urgency=medium + + * Drop build dependency on python3.4. + * Bump standards and debhelper versions. + + -- Matthias Klose Mon, 21 Mar 2016 12:58:34 +0100 + +python3-defaults (3.5.1-2) unstable; urgency=medium + + * Drop Python 3.4 as a supported python3 version. + + -- Matthias Klose Mon, 22 Feb 2016 12:53:25 +0100 + +python3-defaults (3.5.1-1) unstable; urgency=medium + + * Upload to unstable + + [ Scott Kitterman ] + * Drop redundant supported/default version definitions in debpython/ + version.py + + [ Matthias Klose ] + * Bump version to 3.5.1. + * Stop shipping menu files. + + -- Scott Kitterman Mon, 11 Jan 2016 11:35:49 -0500 + +python3-defaults (3.5.0-2) experimental; urgency=medium + + * Update py3versions to list versions in a consistent order: default listed + last and non-default listed first in ascending order (Closes: #801376) + + -- Scott Kitterman Sat, 10 Oct 2015 21:21:44 -0400 + +python3-defaults (3.5.0-1) experimental; urgency=medium + + * Set python3.5 as the default python3 for testing in experimental + + -- Scott Kitterman Mon, 05 Oct 2015 16:44:27 -0400 + +python3-defaults (3.4.3-7) unstable; urgency=medium + + * Update py3versions to list versions in a consistent order: default listed + last and non-default listed first in ascending order (Closes: #801376) + + -- Scott Kitterman Sun, 11 Oct 2015 12:50:01 -0400 + +python3-defaults (3.4.3-6) unstable; urgency=medium + + * Upload to unstable + - Adds python3.5 as a supported python3 version in unstable + * Update idle3 desktop file to better support use from file managers such as + nautilus (Closes: #796125) + - Thanks to Pat Hooper for the patch + + -- Scott Kitterman Thu, 24 Sep 2015 21:47:47 -0400 + +python3-defaults (3.4.3-5) experimental; urgency=medium + + * Readd python3.5 as a supported version for experimental + + -- Scott Kitterman Sat, 27 Jun 2015 18:50:26 -0400 + +python3-defaults (3.4.3-4) unstable; urgency=medium + + * Upload to unstable + + [ Matthias Klose ] + * Update README for python 3.4. Closes: #772545. + + [ Scott Kitterman ] + * Drop python3.5 as a supported version for upload to unstable + + -- Scott Kitterman Sat, 27 Jun 2015 18:47:18 -0400 + +python3-defaults (3.4.3-2) experimental; urgency=medium + + * Add python3.5 as a supported Python version. + + -- Matthias Klose Wed, 03 Jun 2015 01:41:07 +0200 + +python3-defaults (3.4.3-1) experimental; urgency=medium + + * Bump version to 3.4.3. + * Make python3-minimal a pre-dependency for python3. + + -- Matthias Klose Sat, 28 Feb 2015 17:05:58 +0100 + +python3-defaults (3.4.2-2) unstable; urgency=medium + + * py3clean: remove pyc files generated from files with dot in its name + (workaraunds http://bugs.python.org/issue22966) + + -- Piotr Ożarowski Sat, 29 Nov 2014 18:14:17 +0100 + +python3-defaults (3.4.2-1) unstable; urgency=medium + + [ Scott Kitterman ] + * Drop unused B-D-I on libhtml-tree-perl + * Use dpkg-vendor instead of lsb-release to determine distribution. + + [ Matthias Klose ] + * Bump version to 3.4.2. + * Bump standards version to 3.9.6. + * Build-depend on python3.4 and dpkg-dev versions to consistently + generate the i586-* symlinks. Closes: #762980. + + -- Matthias Klose Wed, 08 Oct 2014 12:52:49 +0200 + +python3-defaults (3.4.1-1) unstable; urgency=medium + + * Bump version to 3.4.1. + * Drop python3.3 as a supported python version. + * Build a python3-venv binary package. + * Fix lintian warnings. + * py3versions: Ignore blank lines before the source section in the control + file. Closes: #739935. + + -- Matthias Klose Wed, 04 Jun 2014 12:39:42 +0200 + +python3-defaults (3.4.1~rc1-1) unstable; urgency=medium + + * Upload to unstable + * Bump version to 3.4.1~rc1 + + -- Scott Kitterman Tue, 27 May 2014 22:49:41 -0400 + +python3-defaults (3.4~rc1-1) experimental; urgency=medium + + * Default to python3.4. + + -- Matthias Klose Wed, 12 Feb 2014 13:03:28 +0100 + +python3-defaults (3.3.4-1) unstable; urgency=medium + + * Bump version to 3.3.4. + + -- Matthias Klose Wed, 12 Feb 2014 11:15:40 +0100 + +python3-defaults (3.3.3-1) experimental; urgency=low + + * Add python3.4 as a supported python version. + + -- Matthias Klose Thu, 26 Dec 2013 00:39:55 +0100 + +python3-defaults (3.3.2-17) unstable; urgency=low + + * Add Multi-Arch: allowed for python3-all-dev. + + -- Matthias Klose Wed, 18 Sep 2013 15:46:08 +0200 + +python3-defaults (3.3.2-16) unstable; urgency=low + + * Restore :any relationship for python3-minimal build-dep now that it is + supported on the buildds + + -- Scott Kitterman Sat, 07 Sep 2013 17:11:07 -0400 + +python3-defaults (3.3.2-15) unstable; urgency=low + + * Drop non-existing :any from python3-minimal build-dep. + + -- Scott Kitterman Sun, 18 Aug 2013 11:38:29 -0400 + +python3-defaults (3.3.2-14) unstable; urgency=low + + * Add python3.1 and python3.2 to unsupported-versions + * Build-depend on python3-minimal:any instead of python since that's what's + used during the build now + * Build-depend on python3-docutils instead of python-docutils + * Add Multi-Arch: allowed for python3-all and python3-all-dbg + * Add libpython3-dbg to python3-dbg depends + * Add libpython3-dev to python3-dev depends + * Use generated depends in control.in for libpython3-stdlib as with other + binaries + * Set UPSTRVER for Ubuntu in debian/rules so correct results are produced in + both Debian and Ubuntu + + -- Scott Kitterman Sun, 18 Aug 2013 06:22:22 -0400 + +python3-defaults (3.3.2-13) unstable; urgency=low + + * Bump python3-minimal Breaks/Replaces python3 versions to 3.3.2-13~ to + account for files moved in -4 and later (Closes: #718734) + * Fix broken libpython3-all-dbg symlink + + -- Scott Kitterman Mon, 05 Aug 2013 02:25:13 -0400 + +python3-defaults (3.3.2-12) unstable; urgency=low + + * Re-upload with a version newer than the one in experimental. + * Build libpython3-all-{dev,dbg} and libpython3-stdlib packages. + * Move debiandoc-sgml and lsb-release from Build-Depends-Indep to + Build-Depends. + + -- Matthias Klose Sat, 03 Aug 2013 09:52:26 +0200 + +python3-defaults (3.3.2-5) unstable; urgency=low + + * Drop python3.2 from supported python3 versions + + -- Scott Kitterman Fri, 02 Aug 2013 22:58:22 -0400 + +python3-defaults (3.3.2-4) unstable; urgency=low + + * Upload to unstable + * Remove /usr/share/python3/debpython/__pycache__ in python3-minimal's prerm + * Change source format back to 1.0 (native) + + -- Piotr Ożarowski Thu, 01 Aug 2013 21:41:34 +0200 + +python3-defaults (3.3.2-11) experimental; urgency=low + + * Make datetime module optional in debpython (it's not available in + python3.X-minimal, closes: #717232) + + -- Piotr Ożarowski Thu, 18 Jul 2013 22:50:17 +0200 + +python3-defaults (3.3.2-10) experimental; urgency=low + + [ Matthias Klose ] + * Move py3compile and py3clean back to the python3-minimal package. + + [ Piotr Ożarowski ] + * Remove pybuild and dh_python3, dh-python source package provides it now + * Add dh-python dependency in python3 package (to make sure dh_python3 is + installed) + * Bump Standards-Version to 3.9.4 + + -- Piotr Ożarowski Mon, 15 Jul 2013 23:48:04 +0200 + +python3-defaults (3.3.2-3) unstable; urgency=low + + * Bump python3-minimal Breaks/Replaces python3 versions to 3.3.2-1~ to + account for files moved in -2 (closes: #717373) + + -- Scott Kitterman Sun, 21 Jul 2013 09:30:39 -0400 + +python3-defaults (3.3.2-2) unstable; urgency=low + + [ Matthias Klose ] + * Build dependency packages as architecture dependent packages. + * Make python3, python3-{minimal,dev,dbg} Multi-Arch: allowed. + * Don't use the `u' abi flag when defaulting to 3.3. + * Build Multi-Arch: same packages libpython3-{dev,dbg} packages providing + $(DEB_HOST_MULTIARCH)-python3-config symlinks. + + [ Piotr Ożarowski ] + * Move python-docutils to Build-Depends (python3 package is now arch:any) + + [ Dmitry Shachnev ] + * Include architecture.mk in debian/rules instead of defining + DEB_HOST_* manually. + + [ Scott Kitterman ] + * Correct doc directory in README.Debian + * Bump standards version to 3.9.4 without further change + + -- Scott Kitterman Wed, 17 Jul 2013 17:14:22 -0400 + +python3-defaults (3.3.2-1) unstable; urgency=low + + [ Scott Kitterman ] + * Make python3.3 the default python3 + * When X-Python3-Version is not present, do not describe it as missing, + just indicate it is not there + + [ Matthias Klose ] + * Bump version to 3.3.2. + * Don't use the `u' abi flag when defaulting to 3.3. + + -- Scott Kitterman Sun, 14 Jul 2013 18:35:33 -0400 + +python3-defaults (3.3.0-3) experimental; urgency=low + + [ Piotr Ożarowski ] + * pybuild: + - add --ext-dest-dir (PYBUILD_EXT_DESTDIR) and --ext-pattern + (PYBUILD_EXT_PATTERN) options to move files after install step + - save before/after command logs if quiet mode is on + - do not warn about limiting versions if there's only one + - distutils plugin: do not skip build in install target + (ugly workaround for yet another distutils "feature", + closes: #701137) + - do not run tests if DEB_BUILD_OPTIONS contains "nocheck" + * dh_python3: + - add version range to py3compile in maintainer scripts + - no longer sensitive to trailing slash in private dir names + (closes: #701215) + * Bump minimum required dpkg-dev build dependency to 1.16.1~ + (due to architecture.mk in debian/rules) + + [ Dmitry Shachnev ] + * Include architecture.mk in debian/rules instead of defining + DEB_HOST_* manually. + * tests/t1: Build-depend on python3-all instead of python-all. + * Make tests work without python-support installed. + * debian/tests/control: Add a dependency on libjs-jquery (test1 contains + a symlink to /usr/share/javascript/jquery/jquery.js). + * Added missing docinfo to man pages, to fix a lintian warning + (Closes: #702777). + + [ Matthias Klose ] + * dh_python3: Use the multiarch tuple for the host (if DEB_HOST_MULTIARCH + is set in the environment). + * Add a libpython3-stdlib package (not yet built). + + -- Piotr Ożarowski Sun, 17 Mar 2013 13:47:29 +0100 + +python3-defaults (3.3.0-2) experimental; urgency=low + + [ Piotr Ożarowski ] + * dh_python3: + - add multiarch support (rename extensions in dist-packages) + - rename foomodule.so to foo.so in dist-packages (for Python >= 3.3) + * pybuild: + - add --{before,after}-{clean,configure,build,install,test} + command line options and many more PYBUILD_FOO environment vars + (f.e. PYBUILD_DESTDIR, PYBUILD_DESTDIR_python3, + PYBUILD_DESTDIR_python3.3-dbg) + - add --disable command line option (to disable step, interpreter, version + or any mix of them); drop --no-clean and --no-tests arguments + (replaced by --disable clean, --disable test or --disable 'clean test') + - add new build system to dh sequencer (dh --buildsystem=pybuild) + - add manpage + * Move python-docutils to Build-Depends (python3 package is now arch:any) + + [ Matthias Klose ] + * Build dependency packages as architecture dependent packages. + * Make python3, python3-{minimal,dev,dbg} Multi-Arch: allowed. + * Don't use the `u' abi flag when defaulting to 3.3. + * Build Multi-Arch: same packages libpython3-{dev,dbg} packages providing + $(DEB_HOST_MULTIARCH)-python3-config symlinks. + * Add Multi-Arch: same packages libpython3-all-{dev,dbg} (not yet built, + python3.2 doesn't have support for multiarch). + + [ Dmitry Shachnev ] + * debpython/interpreter.py: fix failing doctest + (architecture no longer hardcoded) + * Added DEP-8 tests (Closes: #698002). + + -- Piotr Ożarowski Sat, 12 Jan 2013 17:13:14 +0100 + +python3-defaults (3.3.0-1) experimental; urgency=low + + [ Piotr Ożarowski ] + * Add Python 3.3 to the list of supported Python 3 versions and make it a + default one. + * dh_python3: + - remove egg-info file/dir while moving files to common directory + if the later one already contains it + * rewrite dh_python3.1, py3compile.1 and py3clean.1 manpages in + ReStructured Text + * Add pybuild + + [ Scott Kitterman ] + * Update Makefile to install pybuild + * Fix file name typo in README.derivatives + + -- Scott Kitterman Mon, 26 Nov 2012 09:20:46 -0500 + +python3-defaults (3.2.3-7) unstable; urgency=low + + * Add Python 3.3 as a supported Python version. + + -- Matthias Klose Mon, 06 May 2013 03:05:02 +0200 + +python3-defaults (3.2.3-6) unstable; urgency=low + + [ Piotr Ożarowski ] + * dh_python3 + - ignore empty files while trying to normalize shebangs + - mention the right file (debian/py3dist-overrides) while warning about + guessed dependency - thanks to Sebastian Ramacher for the patch + (Closes: #685067) + - fix generating dependencies when maximum version is specified + (Closes: #687060) + * py3versions.py: fix parsing DEBPYTHON3_SUPPORTED env. variable + (versions should be separated using comma, as in debian_defaults + config file) + * py3versions, debpython: close previously opened files - thanks to Dmitry + Shachnev for the patch (Closes: #686587) + + [ Dmitry Shachnev ] + [ Barry Warsaw ] + * py3clean: Don't remove everything in the __pycache__ directory for + system site package directories. Prevents bogus cleaning of unrelated + *.pyc files. Original patch by Dmitry, with review, clean up, small + modifications, and additional comments by Barry. (Closes: #685167) + + [ Barry Warsaw ] + * dh_python3: Rework calculation of extension tags to add support for + Python 3.3's different suffixes, and to allow for unadorned .so files + to assume they are built with the default Python 3 version. + Closes: 672178 + * README.derivatives: It is no longer necessary to edit + debian/py3versions.py since the values are taken from + debian_defaults. Also added some text on how to separate the + specification when multiple versions are supported. + * Makefile: Fix the nosetests3 command. Closes: 690259 + + -- Piotr Ożarowski Sun, 21 Oct 2012 21:29:45 +0200 + +python3-defaults (3.2.3-5) unstable; urgency=low + + * dh_python3: + - do not rewrite /usr/bin/python{,2.*} shebangs + (Closes: #683294, /me still thinks it was a feature, not a bug) + - parsing debian/control fields is now case insensitive + * Change source format from native to 3.0 (native) + + -- Piotr Ożarowski Thu, 02 Aug 2012 23:26:08 +0200 + +python3-defaults (3.2.3-4) unstable; urgency=high + + * py3clean: really close #681389 + + -- Piotr Ożarowski Thu, 12 Jul 2012 22:45:47 -0600 + +python3-defaults (3.2.3-3) unstable; urgency=high + + * Yet another update in SHEBANG_RE to handle even more cases + * test4 fixed to catch missing /usr/bin/python → /usr/bin/python3 rewrites + * py3clean: accept --package *and* directory name at the same time + (change missed in -1 upload, closes: #681389) + * Bump minimum required python3 version to 3.2.3-3~ in packages with .py files + (due to --package option that is added to py3compile/py3clean in rtupdate + scripts) + + -- Piotr Ożarowski Thu, 12 Jul 2012 12:40:42 -0600 + +python3-defaults (3.2.3-2) unstable; urgency=high + + * Urgency high for grave bug because this will cause other packages to + misbuild + * Correct SHEBANG_RE in debpython/tools.py to not capture the 3 from python3 + (Closes: #681235) + + -- Scott Kitterman Wed, 11 Jul 2012 11:51:46 -0400 + +python3-defaults (3.2.3-1) unstable; urgency=low + + * Bump upstream version to match current unstable/wheezy python3.2 version + * dh_python3: + - generates rtupdate scripts for private directories that compile files + from given package only, add --compile-all to dh_python3's call if you + want the old behaviour (i.e. compile also files (plugins?) provided by + other packages, which do not use a helper/bytecompile them) + - rewrite shebangs by default (disable via --no-shebang-rewrite), + examples: + + "/usr/bin/env python3*" → "/usr/bin/python3*" + + "/usr/local/bin/python3 foo" → "/usr/bin/python3 foo" + - new --shebang option to replace all shebangs in bin dirs + (example: --shebang /usr/bin/python3) + - translate Python version numbers into Debian ones for those + require.txt items that have a pydist file with (uscan like) rules + or PEP386 flag + * py3versions, dh_python3, py3compile: allow to override system's list of + supported Python3 versions via DEBPYTHON3_SUPPORTED and default Python3 + version via DEBPYTHON3_DEFAULT env. variables + * Debhelper's python3 sequence now inserts dh_python3 before dh_installinit + + -- Piotr Ożarowski Sat, 30 Jun 2012 15:20:39 +0200 + +python3-defaults (3.2.3~rc2-1) unstable; urgency=low + + [ Scott Kitterman ] + * Drop unused XS-Python-Version support from dh_python3 + * Remove unused debian/pyversions support from dh_python3 + * Remove unused support for comma delimited lists of versions with + X-Python3-Version from py3versions and debpython/debhelper.py (dh_python3) + * Clean up log messages in py3versions a bit + * Remove unused code related to parsing debian/pyversions from + debian/py3versions + * idle3 should Break as well as Replace python3 + * Correct Python package names with hyphens in them being ignored + (Closes: #657667) + * Fix python3.2 related deprecation and resource warnings in + debian/py3versions.py (Closes: #670471) + * Drop -n from /usr/bin/idle3 invocations in debian/idle.desktop and + debian/idle.menu (Closes: #671704) + * dh_python3, py3versions: make comparison of X-Python-Version field names + case-insensitive (Closes: #676225) + - Change based on Piotr Ożarowski's change for python-defaults + * Bump upstream version number to match python3.2 (3.2.3~rc2) + * Bump minimum debhelper version to 7.0.50~ to support minumum version + needed by tests + * Add debian/python3-minimal.postinst.in and python3-minimal.prerm to + support byte compiling py3versions.py (Closes: #672226) + - byte compiling only works if py3compile is present, which it may not be + on fresh installs, but removing .pyc files is reliable (best we can do + without moving py3compile to python3-minimal + * Move /usr/bin/py3versions -> ../share/python3/py3versions.py symlink from + python3 to python3-minimal to match the change in python-defaults + - Add Breaks/Replaces + + [ Piotr Ożarowski ] + * Generate correct python3 (<< 3.X) dependencies when maximum Python 3 + version is specified (Closes: #675703) + + -- Scott Kitterman Tue, 05 Jun 2012 23:58:13 -0400 + +python3-defaults (3.2.3~rc1-2) unstable; urgency=low + + * Fix max version expansion for -V/X-P-V to be the max version and not +1 + * Move idle3.xpm symlink from python3 to idle3 and add Replaces + * Add 'dependency package' to long description of python3-all, + python3-all-dev, and python3-all-dbg + + -- Scott Kitterman Fri, 16 Mar 2012 17:19:58 -0400 + +python3-defaults (3.2.3~rc1-1) unstable; urgency=low + + * debpython/depends.py: + - Add functional support for -V, specify list of supported Python versions + for dh_python3 + * Adjust upstream version number to match current python3.2 version + * Bump standards version to 3.9.3 without further change + + -- Scott Kitterman Thu, 15 Mar 2012 00:43:38 -0400 + +python3-defaults (3.2.2-1) unstable; urgency=low + + [ Scott Kitterman ] + * Update upstream version to match python3.2 + * Add versioned idle3 package to idle3 depends (Closes: #637973) + * Fix typo in debian/py3versions.1 (Closes: #651342) + - Patch thanks to Daniel Stender + * Specify Python 3 and not just Python in python3-doc/dbg descriptions + * Add build-arch and build-indep targets in debian/rules + * Add native-package-with-dash-version to source lintian overrides + * Add idle3.lintian-overrides for menu-icon-missing since it is provided + in the python3 package + * Bump standards version to 3.9.2 without further change + + [ Matthias Klose ] + * Add symlinks for python3-config man page. + * Add symlinks for binaries and man pages including the abi flags. + + [ Piotr Ożarowski ] + * py3compile: + - fix -O option + - speed up a bit (remove unnecessary interpreter calls) + + -- Scott Kitterman Wed, 11 Jan 2012 17:26:18 -0500 + +python3-defaults (3.2.2~rc1-2) unstable; urgency=medium + + * Medium urgency to avoid blocking the python2.7 transition + * python3 now provides python3-profiler + * Drop suggests on old (non-free) python3-profiler package + + -- Scott Kitterman Wed, 28 Sep 2011 11:29:05 -0400 + +python3-defaults (3.2.2~rc1-1) unstable; urgency=low + + * Update upstream version to match python3.2 + * dh_python3: Assume .so files without tag in /usr/lib/python3/ are built for + Python 3.2 instead of for Python 3.1 + * dh_python3 and dh_python3.1: add --no-dbg-cleaning option (to disable + removing files from debug packages) from dh_python2 + + -- Scott Kitterman Sun, 25 Sep 2011 01:14:16 -0400 + +python3-defaults (3.2-3) unstable; urgency=low + + * Fix a typo in dh_python3 and generate correct prerm scripts + (with py3clean rather than pyclean, thanks to IRIE Shinsuke for bug + reporta and a patch, closes: 622708, LP: #760401) + + -- Piotr Ożarowski Thu, 14 Apr 2011 21:44:29 +0200 + +python3-defaults (3.2-2) unstable; urgency=low + + [ Piotr Ożarowski ] + * Drop Python 3.1 from supported Python 3 versions + * python.mk: add py_builddir and py_builddir_sh macros. + $(call py_builddir, 3.2) returns "build/lib.linux-x86_64-3.2" on amd64 + + [ Scott Kitterman ] + * Upload to unstable + + -- Scott Kitterman Sun, 03 Apr 2011 19:02:43 -0400 + +python3-defaults (3.2-1) experimental; urgency=low + + [ Piotr Ożarowski ] + * dh_python3 and py3compile: read /usr/share/python3/debian_defaults to get + default Python 3 version and a list of supported Python 3 versions + * py3compile: + - let py_compile.py warn about syntax errors again + * dh_python3: + - fix checking shebangs in private directories (executable bit wasn't + checked correctly) + - private modules without extensions will not cause FTBFS anymore + (closes: 617358, thanks to IRIE Shinsuke for the patch) + - generate "python3 (>= 3.X), python3 (<< 3.Y)" dependencies if package + provides public extensions + - make egg-info files/dirs searches case insensitive + + [ Scott Kitterman ] + * More Python/Python 3 in package descriptions + + -- Scott Kitterman Wed, 23 Mar 2011 22:48:56 -0400 + +python3-defaults (3.2~rc1-2) experimental; urgency=low + + * dh_python3: add support for DH_OPTIONS env. variable + * disable check_versions test and drop python3 package from Build-Depends + + -- Piotr Ożarowski Thu, 20 Jan 2011 23:29:04 +0100 + +python3-defaults (3.2~rc1-1) experimental; urgency=low + + * Bump Python minimum version to >= 3.2~rc1 + * dh_python3: ignore binary files while checking shebangs + * py3compile: fix magic number check + + -- Piotr Ożarowski Wed, 19 Jan 2011 19:16:30 +0100 + +python3-defaults (3.2~b2-2) experimental; urgency=low + + * dh_python3 + - fix moving files from old debug locations + - move as many files to /usr/lib/python3/dist-packages as possible + (files that cannot be shared between Python 3.X versions are left in + original location for now) + - add tag name to Python >= 3.2 extensions if they're missing (due to + custom build system) in /usr/lib/pythonX.Y/dist-packages directories + + -- Piotr Ożarowski Thu, 06 Jan 2011 21:22:51 +0100 + +python3-defaults (3.2~b2-1) experimental; urgency=low + + [ Matthias Klose ] + * Default to Python 3.2. + * py3compile: + - Don't over-optimize, check the timestamps of byte-code files. + - Add options -f/--force, -O. + - Copy stdout/stderr of py_compile processes in case of error. + - Propagate the exit value of the py_compile processes. + - Update manual page. + * Bump depends to require the fixed pycompile for dh_python3 based package + builds. + * Don't touch the standard python library in rtupdate scripts. + + [ Piotr Ożarowski ] + * dh_python3: + - do not rename .so files outside dist-packages directory + (Python 3.1 tag name will be added only in public directories) + - generate proper dependencies/maintainer scripts for private + directories with private extensions for more than one Python version + - fix a crash in packages with private extension, test2 added (to test + architecture dependent packages) + * Invoke /usr/share/python3/runtime.d/ hooks in python3's preinst and + postinst + + [ Scott Kitterman ] + * Convert python.desktop to python3.desktop + + -- Scott Kitterman Thu, 23 Dec 2010 17:55:40 -0500 + +python3-defaults (3.1.3-15) experimental; urgency=low + + [ Matthias Klose ] + * Depend on the 3.1.1 versions of the packages. + + [ Piotr Ożarowski ] + * py3compile: do not try to check if interpreter is present when version + range is empty + + -- Matthias Klose Tue, 30 Nov 2010 18:43:11 +0100 + +python3-defaults (3.1.2-15) experimental; urgency=low + + * debpython/version.py: Add 3.2 as supported version. + + -- Matthias Klose Sat, 16 Oct 2010 15:03:53 +0200 + +python3-defaults (3.1.2-14) experimental; urgency=low + + * Add python3.2 as a supported version. + + -- Matthias Klose Thu, 14 Oct 2010 16:42:31 +0200 + +python3-defaults (3.1.2-12) unstable; urgency=low + + * Upload to unstable + + -- Piotr Ożarowski Wed, 22 Sep 2010 23:20:10 +0200 + +python3-defaults (3.1.2-11) experimental; urgency=low + + * dh_python3: + - egg renaming fixed + - generate correct dependency for /usr/bin/python3 shebangs + + -- Piotr Ożarowski Wed, 15 Sep 2010 23:18:56 +0200 + +python3-defaults (3.1.2-10) experimental; urgency=low + + * dh_python3: fix python3:Versions and python3:Provides (now lists Python + versions for which public extensions are provided by binary package) + + -- Piotr Ożarowski Mon, 13 Sep 2010 23:03:02 +0200 + +python3-defaults (3.1.2-9) experimental; urgency=low + + * dh_python3: add tag name to extension files that are missing it + (to avoid conflicts with python3.2 in Wheezy) + + -- Piotr Ożarowski Sun, 12 Sep 2010 19:05:46 +0200 + +python3-defaults (3.1.2-8) experimental; urgency=low + + * py3compile: recognize /usr/lib/python3/ directories correctly + (dh_python3: minimum required python version bumped to 3.1.2-8) + + -- Piotr Ożarowski Sun, 12 Sep 2010 17:26:21 +0200 + +python3-defaults (3.1.2-7) experimental; urgency=low + + [ Piotr Ożarowski ] + * py3versions.py: open debian/control files with encoding='utf-8' as + otherwise all my packages (with "ż" in debian/control) will FTBFS if + user's locale is not set to UTF-8 (f.e. in build daemons) + * dh_python3: + - adjust to python3.1 3.1.2+20100909-1 changes + - move files from /usr/lib/python3.X/dist-packages to + /usr/lib/python3/dist-packages + - set the right minimum required python3 package version in + packages with private modules (for py3compile) + - add dist_fallback file with a list of Python distribution name and + Debian package name pairs (to be used as a fall back source for + PyDist feature) + - if dist_fallback and `dpkg -S` fails to find the right package name, + fall back to package name recommended by Debian Python Policy (use + debian/py3dist-overrides file to override) + * py3compile, py3clean: adjust to PEP 3147 changes, -R option removed + * Add manpages for dh_python3, py3compile and py3clean + * Add README.derivatives (source package) + + [ Matthias Klose ] + * python3: Install /usr/share/python3/python.mk. + * python.mk (py_libdir): Return /usr/lib/python3/dist-packages for 3.x + versions. + * python.mk (py_pkgname): New macro to refer the package name depending + on the python version. + * Generate dependencies on python3 (>= 3.1.2-7~). + * Require python3.1 3.1.2+20100909 as minimal version. + + -- Piotr Ożarowski Sun, 12 Sep 2010 15:54:25 +0200 + +python3-defaults (3.1.2-6) unstable; urgency=low + + [ Matthias Klose ] + * Substitution variables for control files always start with a `python3' + prefix (python:Versions -> python3:Versions, python:Provides -> + python3:Provides). + * Generate dependencies on python3 (>= 3.1.2-6~). + + [ Piotr Ożarowski ] + * py3compile: do not hang if interpreters are not started in the same order + as they're used + * dh_python3: pass shallow=False to cmpfiles to make sure file comparison + works as expected + + [ Scott Kitterman ] + * Us X-Python3-Version for Python 3 instead of XS-Python-Version (which + should just be used for Python) + + -- Piotr Ożarowski Fri, 13 Aug 2010 23:27:45 +0200 + +python3-defaults (3.1.2-5) unstable; urgency=medium + + * Add README.PyDist to python3-doc package + * py3compile: compile public module for the right Python version + * dh_python3: rename --depend to --depends, --recommend to --recommends and + --suggest to --suggests + * Bump Standards-Version to 3.9.1 + + -- Piotr Ożarowski Wed, 28 Jul 2010 22:34:17 +0200 + +python3-defaults (3.1.2-4) unstable; urgency=low + + * dh_python3: + - add --depend, --recommend and --suggest command line options + (use it if requires.txt doesn't contain dependency that package needs) + - add {/usr,}/sbin to the list of directories with checked shebangs + * py3compile: do not exit before all background byte compilation is finished + + -- Piotr Ożarowski Sun, 25 Jul 2010 16:25:04 +0200 + +python3-defaults (3.1.2-3) unstable; urgency=low + + [ Piotr Ożarowski ] + * pyclean, pycompile: use .communicate() instead of .wait() to avoid hanging + `dpkg -L PACKAGE` in few situations + * dh_python3: follow Distribute and replace all non-alphanumeric + characters with underscore in distribution name + * Add python3.{postinst,prerm} scripts + * python3-doc now suggests python3-examples + * Bump Standards-Version to 3.9.0 + + [ Scott Kitterman ] + * Drop deprecated call to dh_desktop from debian/rules + * Bump PREVVER to 3.1.2-3~ for support for stdin in py_compile.py + + [ Matthias Klose ] + * Provide the python3.pc symlink in python3-dev. + * Call py3clean/py3compile on rtupdate in generated scripts. + + -- Matthias Klose Tue, 20 Jul 2010 20:20:01 +0200 + +python3-defaults (3.1.2-2) unstable; urgency=low + + * Add Vcs-Browser field + * Add some lintian overrides (for false positives) + - bump minimum required debhelper version to 6.0.7 (due to dh_lintian) + * py3compile, py3clean and dh_python3 moved to python3 package + * dh_python3: + - some bugs fixed (encoding problems, parsing Python-Version, + few python vs python3 leftovers) + + -- Piotr Ożarowski Wed, 23 Jun 2010 22:57:23 +0200 + +python3-defaults (3.1.2-1) unstable; urgency=low + + [ Matthias Klose ] + * Depend on the 3.1.2 versions of the packages. + * Add py3clean, py3compile binaries to be called from python3-* + maintainer scripts. + * Don't allow installation of a mix of defaults packages for different + python3 versions. + + [ Scott Kitterman ] + * Provide default and supported Python3 versions (3.1 to start) + - Rename pyversions(.py)(.1) to py3versions(.py)(.1) + - Port py3versions.py to Python 3 + - Update py3versions to use python3 specific locations + - Update py3versions to ignore all, current and python versions < 3.0 and + not to use debian/pyversions + - Update debian_defaults for python3 + - Install debian_defaults for python3 + - Update debian/rules + * Update debian/copyright from python3.1 LICENSE file + * Add myself to uploaders + + [ Piotr Ożarowski ] + * Add dh_python3, py3compile and py3clean + * Add myself to Uploaders + + -- Matthias Klose Fri, 18 Jun 2010 00:10:21 +0200 + +python3-defaults (3.1.1-1) unstable; urgency=low + + * Depend on the 3.1.1 versions of the packages. + + -- Matthias Klose Fri, 22 Jan 2010 17:44:37 +0100 + +python3-defaults (3.1-1) experimental; urgency=low + + * Depend on the 3.1 versions of the packages. + + -- Matthias Klose Thu, 23 Jul 2009 17:27:33 +0200 + +python3-defaults (3.0.1-0ubuntu4) jaunty; urgency=low + + * Make idle3 actually run with /usr/bin/python3. (LP: #336381) + * Remove unused idle.sh that led to the previous confusion. + + -- Anders Kaseorg Thu, 12 Mar 2009 15:37:50 -0400 + +python3-defaults (3.0.1-0ubuntu3) jaunty; urgency=low + + * Make idle3 run with /usr/bin/python3, not /usr/bin/python. + (LP: #336381) + * Remove Essential: yes from python3-minimal, and reduce the Priority of + python3 and python3-minimal to optional. (LP: #330613) + + -- Anders Kaseorg Sun, 08 Mar 2009 18:30:38 -0400 + +python3-defaults (3.0.1-0ubuntu2) jaunty; urgency=low + + * Depend on the 3.0.1 versions of the packages. + + -- Matthias Klose Mon, 16 Feb 2009 23:23:06 +0100 + +python3-defaults (3.0~b3-0ubuntu1) intrepid; urgency=low + + * Build new defaults for python3. + + -- Matthias Klose Mon, 15 Sep 2008 22:21:59 +0000 + +python-defaults (2.5.2-1ubuntu1) intrepid; urgency=low + + * Merge with Debian; remaining changes: + - Build the -doc package from this source package. + - Omit Debian specific upgrade code. + - Regenerate the control file. + + -- Matthias Klose Mon, 23 Jun 2008 13:13:51 +0200 + +python-defaults (2.5.2-0ubuntu1) hardy; urgency=low + + * Depend on the 2.5.2 versions of the packages. + + -- Matthias Klose Mon, 10 Mar 2008 18:03:30 +0000 + +python-defaults (2.5.1-1ubuntu2) gutsy; urgency=low + + * Temporarily loosen the dependency on python2.5 to allow python2.5 + to build on powerpc and sparc. + + -- Matthias Klose Fri, 27 Apr 2007 00:00:32 +0200 + +python-defaults (2.5.1-1ubuntu1) gutsy; urgency=low + + * Depend on the 2.5.1 versions of the packages. + + -- Matthias Klose Thu, 26 Apr 2007 11:23:17 +0200 + +python-defaults (2.5.1~rc1-0ubuntu3) feisty; urgency=low + + * Fix versioned build dependency on python2.5. + + -- Matthias Klose Fri, 13 Apr 2007 06:37:58 +0200 + +python-defaults (2.5.1~rc1-0ubuntu2) feisty; urgency=low + + * Add a sanity check, that /usr/bin/python points to the default + python version. Users tend to modify this symlink, which then + breaks stuff in obscure ways. Ubuntu #75557, Debian #418002. + + -- Matthias Klose Fri, 6 Apr 2007 17:47:24 +0200 + +python-defaults (2.5.1~rc1-0ubuntu1) feisty; urgency=low + + * Depend on the 2.5.1~rc1 versions of the packages. + + -- Matthias Klose Fri, 6 Apr 2007 11:13:10 +0000 + +python-defaults (2.5-0ubuntu6) feisty; urgency=low + + * python-dbg: Add a python-dbg-config binary. + + -- Matthias Klose Sat, 17 Feb 2007 21:39:44 +0100 + +python-defaults (2.5-0ubuntu5) feisty; urgency=low + + * python-all-dbg: Tighten dependencies on the python2.x-dbg packages. + * python-dbg: Provide python-gdbm-dbg, python-tk-dbg, + link to README.debug, SpecialBuilds.txt.gz. + * python-dev: Add an unversioned python-config binary. + * Readd build-dependency on python-docutils. + * Set Ubuntu maintainer address. + * Update the FAQ. + + -- Matthias Klose Fri, 16 Feb 2007 18:18:06 +0100 + +python-defaults (2.5-0ubuntu4) feisty; urgency=low + + * New package python-all-dbg. + + -- Matthias Klose Fri, 9 Feb 2007 01:16:09 +0100 + +python-defaults (2.5-0ubuntu3) feisty; urgency=low + + * Temporarily remove build-dependency on python-docutils. + + -- Matthias Klose Fri, 12 Jan 2007 13:06:50 +0000 + +python-defaults (2.5-0ubuntu2) feisty; urgency=low + + * Fix icon for desktop file. + * Robustify building the faq html pages. + * Make the suggestions of various packages versioned. + * Recommend depending on "pythonX.X-foo, python-foo" instead of recommending + to only depend on "pythonX.X-foo" when a particular version is needed to + permit upgrades from real packages to virtual ones. (Loic Minier). + + -- Matthias Klose Fri, 12 Jan 2007 11:42:02 +0000 + +python-defaults (2.5-0ubuntu1) feisty; urgency=low + + * Make python2.5 the default version. + + -- Matthias Klose Fri, 12 Jan 2007 09:10:52 +0000 + +python-defaults (2.4.4-1ubuntu2) feisty; urgency=low + + * python-minimal is essential, not python. + + -- Matthias Klose Thu, 7 Dec 2006 14:25:20 +0000 + +python-defaults (2.4.4-1ubuntu1) feisty; urgency=low + + * Merge with Debian unstable. + - Backout: Add 2.5 to unsupported-versions. + * Build the FAQ again. + + -- Matthias Klose Thu, 16 Nov 2006 15:21:31 -0800 + +python-defaults (2.4.4-1) unstable; urgency=medium + + * Depend on the 2.4.4 versions of the packages. + * Sync pyversions.py with python-central. + * Move 2.3 to old-versions, from supported-versions. + * Add 2.5 to unsupported-versions. + + -- Matthias Klose Sun, 29 Oct 2006 11:06:39 +0100 + +python-defaults (2.4.3-11ubuntu3) edgy; urgency=low + + * Temporarily remove the FAQ and the build-dependency on python-docutils, + so that the build dependencies can be installed. + + -- Matthias Klose Wed, 20 Sep 2006 17:28:47 +0000 + +python-defaults (2.4.3-11ubuntu2) edgy; urgency=low + + * debian/pyversions: + - merged the changes from python-central to support older python + version (and not break on upgrades) + + -- Michael Vogt Wed, 20 Sep 2006 16:42:12 +0200 + +python-defaults (2.4.3-11ubuntu1) edgy; urgency=low + + * Merge with Debian unstable. + + -- Matthias Klose Fri, 8 Sep 2006 00:22:21 +0200 + +python-defaults (2.4.3-11) unstable; urgency=low + + * Add a conflict to python-central (<< 0.5.5). + + -- Matthias Klose Sun, 13 Aug 2006 19:32:59 +0000 + +python-defaults (2.4.3-10) unstable; urgency=low + + * Upload to unstable. Closes: #347440, #360851. + * Let the preinst fail on the first failing pre-rtupdate hook, + after running the corresponding failed-pre-rtupdate hook. + * Reflect renaming of the docutils binaries. Closes: #377601. + * Update the upstream FAQ. + + -- Matthias Klose Sat, 12 Aug 2006 20:28:30 +0200 + +python-defaults (2.4.3-9) experimental; urgency=low + + * Fix syntax error in python.preinst. Closes: #381673. + + -- Matthias Klose Sun, 6 Aug 2006 12:39:34 +0000 + +python-defaults (2.4.3-8) experimental; urgency=low + + * idle: Depend on python-tk, add desktop and menu files. + + -- Matthias Klose Sat, 5 Aug 2006 18:38:31 +0000 + +python-defaults (2.4.3-7) experimental; urgency=low + + * Update pyversions.py from 2.3.5-11. + * Fix pyversions(1), -r takes exactly one parameter. + * idle: Remove the dependency on idle-pythonX.Y, add start script + and man page. + + -- Matthias Klose Sat, 5 Aug 2006 17:34:43 +0000 + +python-defaults (2.4.3-6) experimental; urgency=low + + * Remove python's dependency on python-central. Closes: #372658. + * On upgrade of the runtime to a new major version, call the hooks + (executable files) in /usr/share/python/runtime.d/*.rtupdate. + - in python.preinst, call the script with parameters + pre-rtupdate . + run all hooks, then return exit with the correct exit status. + - in python.postinst, call the script with parameters + rtupdate . + run all hooks, then return exit with the correct exit status. + - in python.postinst, call the script with parameters + post-rtupdate . + run all hooks, then return exit with the correct exit status. + * pyversions -r: If the XS-Python-Version field cannot be found in + debian/control, fall back to debian/pyversions for the version + information. Return with an error code, if the intersection of + the versions in debian/pyversions and the supported python versions + is empty. Fall back to the supported versions if no version + information can be found. Based on a patch from Raphael Hertzog. + * Reflect renaming of the docutils binaries. Closes: #377601. + + -- Matthias Klose Sat, 5 Aug 2006 17:54:43 +0200 + +python-defaults (2.4.3-5ubuntu1) edgy; urgency=low + + * Synchronize with Debian experimental. + * Remove python's dependency on python-central. On upgrade of + the runtime, call hooks /usr/share/python/runtime.d/*.rtupdate. + Addresses: #372658. + * pyversions -r: If the XS-Python-Version field cannot be found in + debian/control, fall back to debian/pyversions for the version + information. Return with an error code, if the intersection of + the versions in debian/pyversions and the supported python versions + is empty. Fall back to the supported versions if no version + information can be found. Based on a patch from Raphael Hertzog. + + -- Matthias Klose Wed, 5 Jul 2006 05:11:42 +0000 + +python-defaults (2.4.3-5) experimental; urgency=low + + * Tighten dependencies between packages built from this source. + A versioned dependency on python-all / python-all-dev is enough + to depend on the same version of python / python-dev. + * python: Conflict with python-central (<< 0.4.17). + * python: Depend on a python2.4 built for the updated Python policy. + * python: Conflict with a python2.3 using the old Python policy. + + -- Matthias Klose Fri, 16 Jun 2006 18:15:00 +0200 + +python-defaults (2.4.3-4) experimental; urgency=low + + * Include version 0.4.1.0 of the python policy. + * Fix 'pyversions -i'. + + -- Matthias Klose Tue, 13 Jun 2006 09:44:22 +0200 + +python-defaults (2.4.3-3) experimental; urgency=low + + * Point to the draft of the reworked Python policy. + * Fix 'pyversions -r current' (Raphael Hertzog). + + -- Matthias Klose Mon, 12 Jun 2006 13:40:52 +0200 + +python-defaults (2.4.3-02) experimental; urgency=low + + * Really do not build python-doc. + + -- Matthias Klose Sun, 11 Jun 2006 23:25:02 +0000 + +python-defaults (2.4.3-1ubuntu1) edgy; urgency=low + + * Let the -all packages depend on the default packages (closes: #365219). + * Add /usr/share/python/debian_defaults for some default values (i.e. + the supported python versions). + * Add /etc/python/debian_config for byte-compilation options. + * Add a pyversions script to give information about python versions and + parse the XS-Python-Version attribute. + * Include version 0.4.1.0 of the python policy. + + -- Matthias Klose Tue, 13 Jun 2006 13:22:43 +0200 + +python-defaults (2.4.3-01) experimental; urgency=low + + * Do not build the python-doc package from this source. + + -- Matthias Klose Sun, 11 Jun 2006 23:59:17 +0200 + +python-defaults (2.4.3-0) experimental; urgency=low + + * Upload to experimental. + * Do not build the python-tk and python-gdbm packages from this source. + * Let the -all packages depend on the default packages (closes: #365219). + * Add /usr/share/python/debian_defaults for some default values (i.e. + the supported python versions). + * Add /etc/python/debian_config for byte-compilation options. + * Add a pyversions script to give information about python versions and + parse the XS-Python-Version attribute. + + -- Matthias Klose Sun, 11 Jun 2006 12:57:03 +0000 + +python-defaults (2.4.2-1) unstable; urgency=low + + * Change the default python version to 2.4. + * Depend on python-central. + + -- Matthias Klose Thu, 12 Jan 2006 01:16:10 +0000 + +python-defaults (2.3.5-4) unstable; urgency=low + + * Add a package python-minimal. This package still depends on python2.3, + will depend on python2.4-minimal when changing the default python version. + * Add two dependency packages python-all and python-all-dev. These + packages are used as build dependencies to determine the set of + python version and implementations, which should be / currently are + supported. Currently it depends on python2.3 and python2.4. Future + versions may add an updated version of jython and ironpython. + * Update FAQ. + + -- Matthias Klose Thu, 12 Jan 2006 00:32:32 +0100 + +python-defaults (2.3.5-3) unstable; urgency=low + + * Add python-dbg package. + * debian/control.in: idle enhances python. + + -- Matthias Klose Sun, 19 Jun 2005 13:49:16 +0200 + +python-defaults (2.3.5-2) unstable; urgency=low + + * Add valgrind support file /usr/lib/valgrind/python.supp (closes: #291128). + * python-doc: Add an conflict/replace to older python packages. + Closes: #297266. + + -- Matthias Klose Sat, 19 Mar 2005 22:49:29 +0100 + +python-defaults (2.3.5-1) unstable; urgency=low + + * Depend on python-2.3.5 packages. + * Update FAQ. + * python suggests python-profiler. + + -- Matthias Klose Sat, 12 Feb 2005 19:26:48 +0100 + +python-defaults (2.3.4-6) unstable; urgency=low + + * Add an 'Enhances: konsole' to the python package (closes: #286161). + + -- Matthias Klose Sun, 16 Jan 2005 12:53:58 +0100 + +python-defaults (2.3.4-5) unstable; urgency=low + + * Add conflict/replaces to ooold python-base package (closes: #279035). + + -- Matthias Klose Sun, 14 Nov 2004 11:44:14 +0100 + +python-defaults (2.3.4-4) unstable; urgency=low + + * Regenerate control file after adding python-docutils build dependency. + Closes: #270177. + + -- Matthias Klose Mon, 6 Sep 2004 07:19:49 +0200 + +python-defaults (2.3.4-3) testing-proposed-updates; urgency=low + + * Unmodified 2.3.4-3sid, destination sarge, fixing build failure. + + -- Matthias Klose Fri, 20 Aug 2004 18:24:25 +0200 + +python-defaults (2.3.4-3sid) unstable; urgency=low + + * Add build dependency on python-docutils (closes: #266550). + + -- Matthias Klose Wed, 18 Aug 2004 12:30:37 +0200 + +python-defaults (2.3.4-2sid) unstable; urgency=low + + * Add pdb and pdb.1 symlinks. + * Update FAQ. + + -- Matthias Klose Tue, 17 Aug 2004 16:17:06 +0200 + +python-defaults (2.3.4-1) unstable; urgency=low + + * Depend on python-2.3.4 packages. + * Update FAQ. + + -- Matthias Klose Mon, 10 May 2004 06:58:24 +0200 + +python-defaults (2.3.3-7) unstable; urgency=low + + * Fix symlinks to proposed policy files (closes: #234874). + + -- Matthias Klose Thu, 26 Feb 2004 22:28:07 +0100 + +python-defaults (2.3.3-6) unstable; urgency=low + + * Build the default packages from a separate source package to ease + migration between python versions. + * Update to the proposed python-policy: byte-compile using -E. + + -- Matthias Klose Wed, 4 Feb 2004 23:16:35 +0100 diff --git a/debian/compat b/debian/compat new file mode 100644 index 000000000000000..b4de3947675361a --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +11 diff --git a/debian/control b/debian/control new file mode 100644 index 000000000000000..f445e317552685f --- /dev/null +++ b/debian/control @@ -0,0 +1,322 @@ +Source: python3-defaults +Section: python +Priority: optional +Maintainer: Matthias Klose +Uploaders: Piotr Ożarowski , Stefano Rivera +Build-Depends: debhelper (>= 11), dpkg-dev (>= 1.17.11), python3.12:any (>= 3.12.6-1~), + python3.12-minimal:any, + python3-docutils , + python3-sphinx , + html2text (>= 2) , +Standards-Version: 4.7.0 +Homepage: https://www.python.org/ +Vcs-Git: https://salsa.debian.org/cpython-team/python3-defaults.git +Vcs-Browser: https://salsa.debian.org/cpython-team/python3-defaults + +Package: python3 +Architecture: any +Multi-Arch: allowed +Pre-Depends: python3-minimal (= ${binary:Version}) +Depends: python3.12 (>= 3.12.6-1~), libpython3-stdlib (= ${binary:Version}), ${misc:Depends} +Suggests: python3-doc (>= ${binary:Version}), python3-tk (>= 3.12.6-1~) , python3-venv (>= ${binary:Version}) +Replaces: python3-minimal (<< 3.1.2-2) +Provides: python3-profiler, python3-supported-min (= 3.12), python3-supported-max (= 3.12) +Conflicts: python3-distutils +Description: interactive high-level object-oriented language (default python3 version) + Python, the high-level, interactive object oriented language, + includes an extensive class library with lots of goodies for + network programming, system administration, sounds and graphics. + . + This package is a dependency package, which depends on Debian's default + Python 3 version (currently v3.12). + +Package: python3-venv +Architecture: any +Multi-Arch: allowed +Depends: python3.12-venv (>= 3.12.6-1~), python3 (= ${binary:Version}), + ${misc:Depends} +Description: venv module for python3 (default python3 version) + This package contains the venv module for the Python language (default python3 + version). + . + The venv module provides support for creating lightweight "virtual + environments" with their own site directories, optionally isolated from system + site directories. Each virtual environment has its own Python binary (which + matches the version of the binary that was used to create this environment) + and can have its own independent set of installed Python packages in its site + directories. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's venv module (currently v3.12). + +Package: python3-minimal +Architecture: any +Multi-Arch: allowed +Pre-Depends: python3.12-minimal (>= 3.12.6-1~) +Depends: dpkg (>= 1.13.20), ${misc:Depends} +Description: minimal subset of the Python language (default python3 version) + This package contains the interpreter and some essential modules. It's used + in the boot process for some basic tasks. + See /usr/share/doc/python3.12-minimal/README.Debian for a list of the modules + contained in this package. +XB-Cnf-Visible-Pkgname: python3 + +Package: python3-nopie +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + python3.12-nopie (>= 3.12.6-1~), ${misc:Depends} +Description: Python interpreter linked without PIE (default python3 version) + This package contains the interpreter not built as position independent + executable. This interpreter is diverting the python3 executable, and making + the interpreter built with PIE available as python3-pie. +XB-Cnf-Visible-Pkgname: python3 + +Package: python3-examples +Architecture: all +Multi-Arch: foreign +Depends: python3 (>= ${binary:Version}), python3.12-examples (>= 3.12.6-1~), ${misc:Depends} +Description: examples for the Python language (default version) + Examples, Demos and Tools for Python. These are files included in + the upstream Python distribution. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's examples (currently v3.12). + +Package: python3-dev +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), libpython3-dev (= ${binary:Version}), + python3.12-dev (>= 3.12.6-1~), + ${misc:Depends}, ${sphinxdoc:Depends} +Breaks: python3 (<< 3.9.2-1~) +Replaces: python3.1 (<< 3.1.2+20100706-3), python3 (<< 3.9.2-1~) +Built-Using: ${sphinxdoc:Built-Using} +Description: header files and a static library for Python (default) + Header files, a static library and development tools for building + Python modules, extending the Python interpreter or embedding Python + in applications. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's headers (currently v3.12). + +Package: libpython3-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Depends: libpython3.12-dev (>= 3.12.6-1~), ${misc:Depends} +Breaks: libpython3.8-dev (<< 3.8.0-2), python3-dev (<< 3.8.0-1) +Replaces: libpython3.8-dev (<< 3.8.0-2), python3-dev (<< 3.8.0-1) +Description: header files and a static library for Python (default) + Header files, a static library and development tools for building + Python modules, extending the Python interpreter or embedding Python + in applications. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's headers (currently v3.12). + +Package: libpython3-stdlib +Architecture: any +Multi-Arch: same +Depends: libpython3.12-stdlib (>= 3.12.6-1~), ${misc:Depends} +Description: interactive high-level object-oriented language (default python3 version) + This package contains the majority of the standard library for the Python + language (default python3 version). + . + This package is a dependency package, which depends on Debian's default + Python 3 version's standard library (currently v3.12). + +Package: idle +Architecture: all +Depends: python3 (>= ${binary:Version}), python3-tk, ${misc:Depends}, idle-python3.12 +Enhances: python3 +Breaks: idle3 (<< 3.6.2-2) +Replaces: idle3 (<< 3.6.2-2) +Description: IDE for Python using Tkinter (default version) + IDLE is an Integrated Development Environment for Python. + IDLE is written using Tkinter and therefore quite platform-independent. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's IDLE (currently v3.12). + +Package: python3-doc +Section: doc +Architecture: all +Multi-Arch: foreign +Depends: python3.12-doc (>= 3.12.6-1~), ${misc:Depends} +Suggests: python3 (>= ${binary:Version}), python3-examples +Description: documentation for the high-level object-oriented language Python 3 + This is the official set of documentation for the interactive high-level + object-oriented language Python 3 (v3.12). All documents are provided + in HTML format, some in info format. The package consists of nine documents: + . + * Tutorial + * Python Library Reference + * Macintosh Module Reference + * Python Language Reference + * Extending and Embedding Python + * Python/C API Reference + * Installing Python Modules + * Documenting Python + * Distributing Python Modules + . + This package is a dependency package, which depends on Debian's default + Python 3 version's documentation (currently v3.12). + +Package: python3-dbg +Architecture: any +Multi-Arch: allowed +Section: debug +Depends: python3 (= ${binary:Version}), libpython3-dbg (= ${binary:Version}), python3.12-dbg (>= 3.12.6-1~), ${misc:Depends} +Description: debug build of the Python 3 Interpreter (version 3.12) + Python 3 interpreter configured with --pydebug. Dynamically loaded modules + are searched in /usr/lib/python3.12/lib-dynload/debug first. + +Package: libpython3-dbg +Architecture: any +Multi-Arch: same +Section: debug +Depends: libpython3.12t64-dbg (>= 3.12.6-1~), ${misc:Depends} +Breaks: python3-dbg (<< 3.8.0-1) +Replaces: python3-dbg (<< 3.8.0-1) +Description: debug build of the Python 3 Interpreter (version 3.12) + Python 3 interpreter configured with --pydebug. Dynamically loaded modules + are searched in /usr/lib/python3.12/lib-dynload/debug first. + +Package: python3-all +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + ${misc:Depends}, + python3.12, +Description: package depending on all supported Python 3 runtime versions + The package currently depends on python3.12, in the future, dependencies on + jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 runtimes. + +Package: python3-all-dev +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + libpython3-all-dev (= ${binary:Version}), + python3-all (= ${binary:Version}), + python3-dev (= ${binary:Version}), + ${misc:Depends}, + python3.12-dev, +Description: package depending on all supported Python 3 development packages + The package currently depends on python3.12-dev, in the future, dependencies + on jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 development + packages. + +Package: python3-all-dbg +Architecture: any +Multi-Arch: allowed +Section: debug +Depends: python3 (= ${binary:Version}), + libpython3-all-dbg (= ${binary:Version}), + python3-all (= ${binary:Version}), + python3-dbg (= ${binary:Version}), + ${misc:Depends}, + python3.12-dbg, +Description: package depending on all supported Python 3 debugging packages + The package currently depends on python3.12-dbg, in the future, dependencies + on jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 debug packages. + +Package: python3-all-venv +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + python3-all (= ${binary:Version}), + python3-venv (= ${binary:Version}), + ${misc:Depends}, + python3.12-venv, +Description: package depending on all supported Python 3 venv modules + The package currently depends on python3.12-venv, in the future, dependencies + on jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 venv packages. + +Package: libpython3-all-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Depends: libpython3-dev (= ${binary:Version}), + ${misc:Depends}, + libpython3.12-dev, +Description: package depending on all supported Python 3 development packages + The package currently depends on libpython3.12-dev, in the future, + dependencies on jython (Python for a JVM) and ironpython (Python for Mono) may + be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 development + packages. + +Package: libpython3-all-dbg +Architecture: any +Multi-Arch: same +Section: debug +Depends: libpython3-dbg (= ${binary:Version}), + ${misc:Depends}, + libpython3.12t64-dbg, +Description: package depending on all supported Python 3 debugging packages + The package currently depends on libpython3.12-dbg, in the future, + dependencies on jython (Python for a JVM) and ironpython (Python for Mono) may + be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 debug packages. + +Package: 2to3 +Architecture: all +Multi-Arch: foreign +Depends: python3-lib2to3 (>= 3.12.6-1~), python3 (>= ${binary:Version}), ${misc:Depends} +Description: 2to3 binary using python3 + 2to3 is a Python program that reads Python 2.x source code and applies a + series of fixers to transform it into valid Python 3.x code. The standard + library contains a rich set of fixers that will handle almost all code. 2to3 + supporting library lib2to3 is, however, a flexible and generic library, so it + is possible to write your own fixers for 2to3. lib2to3 could also be adapted + to custom applications in which Python code needs to be edited automatically. + . + This package is a dependency package, which depends on Debian's default + Python 3 2to3 version (currently v3.12). + +Package: python3-full +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + python3.12-full (>= 3.12.6-1~), + python3-venv (= ${binary:Version}), + 2to3, + idle, + python3-gdbm, + python3-lib2to3, + python3-tk, + ${shlibs:Depends}, ${misc:Depends} +Recommends: python3-doc, python3-examples, +Suggests: python3-dev +Description: Default Python Interpreter with complete class library + Python, the high-level, interactive object oriented language, + includes an extensive class library with lots of goodies for + network programming, system administration, sounds and graphics. + . + This package is a dependency package, which depends on the full + standard library of Python for Python developers. Including modules + used only at build-time, such as venv, and modules with + complex dependencies, such as tk and IDLE. All batteries included. + . + This package depends on Debian's default python 3 version's full + standard library (currently v3.12). + . + According to the Debian Python policy, this package must not be used in + build dependencies, dependencies and recommendations. diff --git a/debian/control.in b/debian/control.in new file mode 100644 index 000000000000000..9205551de9377c4 --- /dev/null +++ b/debian/control.in @@ -0,0 +1,322 @@ +Source: python3-defaults +Section: python +Priority: optional +Maintainer: Matthias Klose +Uploaders: Piotr Ożarowski , Stefano Rivera +Build-Depends: debhelper (>= 11), @bd_i586@ + python@VER@-minimal:any, + python3-docutils , + python3-sphinx , + html2text (>= 2) , +Standards-Version: 4.7.0 +Homepage: https://www.python.org/ +Vcs-Git: https://salsa.debian.org/cpython-team/python3-defaults.git +Vcs-Browser: https://salsa.debian.org/cpython-team/python3-defaults + +Package: python3 +Architecture: any +Multi-Arch: allowed +Pre-Depends: python3-minimal (= ${binary:Version}) +Depends: python@VER@ (>= @UPSTRVER@), libpython3-stdlib (= ${binary:Version}), ${misc:Depends} +Suggests: python3-doc (>= ${binary:Version}), python3-tk (>= @STDLIBVER@) , python3-venv (>= ${binary:Version}) +Replaces: python3-minimal (<< 3.1.2-2) +Provides: python3-profiler, python3-supported-min (= 3.12), python3-supported-max (= 3.12) +Conflicts: python3-distutils +Description: interactive high-level object-oriented language (default python3 version) + Python, the high-level, interactive object oriented language, + includes an extensive class library with lots of goodies for + network programming, system administration, sounds and graphics. + . + This package is a dependency package, which depends on Debian's default + Python 3 version (currently v@VER@). + +Package: python3-venv +Architecture: any +Multi-Arch: allowed +Depends: python@VER@-venv (>= @UPSTRVER@), python3 (= ${binary:Version}), + ${misc:Depends} +Description: venv module for python3 (default python3 version) + This package contains the venv module for the Python language (default python3 + version). + . + The venv module provides support for creating lightweight "virtual + environments" with their own site directories, optionally isolated from system + site directories. Each virtual environment has its own Python binary (which + matches the version of the binary that was used to create this environment) + and can have its own independent set of installed Python packages in its site + directories. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's venv module (currently v@VER@). + +Package: python3-minimal +Architecture: any +Multi-Arch: allowed +Pre-Depends: python@VER@-minimal (>= @UPSTRVER@) +Depends: dpkg (>= 1.13.20), ${misc:Depends} +Description: minimal subset of the Python language (default python3 version) + This package contains the interpreter and some essential modules. It's used + in the boot process for some basic tasks. + See /usr/share/doc/python@VER@-minimal/README.Debian for a list of the modules + contained in this package. +XB-Cnf-Visible-Pkgname: python3 + +Package: python3-nopie +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + python@VER@-nopie (>= @UPSTRVER@), ${misc:Depends} +Description: Python interpreter linked without PIE (default python3 version) + This package contains the interpreter not built as position independent + executable. This interpreter is diverting the python3 executable, and making + the interpreter built with PIE available as python3-pie. +XB-Cnf-Visible-Pkgname: python3 + +Package: python3-examples +Architecture: all +Multi-Arch: foreign +Depends: python3 (>= ${binary:Version}), python@VER@-examples (>= @UPSTRVER@), ${misc:Depends} +Description: examples for the Python language (default version) + Examples, Demos and Tools for Python. These are files included in + the upstream Python distribution. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's examples (currently v@VER@). + +Package: python3-dev +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), libpython3-dev (= ${binary:Version}), + python@VER@-dev (>= @UPSTRVER@), + ${misc:Depends}, ${sphinxdoc:Depends} +Breaks: python3 (<< 3.9.2-1~) +Replaces: python3.1 (<< 3.1.2+20100706-3), python3 (<< 3.9.2-1~) +Built-Using: ${sphinxdoc:Built-Using} +Description: header files and a static library for Python (default) + Header files, a static library and development tools for building + Python modules, extending the Python interpreter or embedding Python + in applications. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's headers (currently v@VER@). + +Package: libpython3-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Depends: libpython@VER@-dev (>= @UPSTRVER@), ${misc:Depends} +Breaks: libpython3.8-dev (<< 3.8.0-2), python3-dev (<< 3.8.0-1) +Replaces: libpython3.8-dev (<< 3.8.0-2), python3-dev (<< 3.8.0-1) +Description: header files and a static library for Python (default) + Header files, a static library and development tools for building + Python modules, extending the Python interpreter or embedding Python + in applications. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's headers (currently v@VER@). + +Package: libpython3-stdlib +Architecture: any +Multi-Arch: same +Depends: libpython@VER@-stdlib (>= @UPSTRVER@), ${misc:Depends} +Description: interactive high-level object-oriented language (default python3 version) + This package contains the majority of the standard library for the Python + language (default python3 version). + . + This package is a dependency package, which depends on Debian's default + Python 3 version's standard library (currently v@VER@). + +Package: idle +Architecture: all +Depends: python3 (>= ${binary:Version}), python3-tk, ${misc:Depends}, idle-python@VER@ +Enhances: python3 +Breaks: idle3 (<< 3.6.2-2) +Replaces: idle3 (<< 3.6.2-2) +Description: IDE for Python using Tkinter (default version) + IDLE is an Integrated Development Environment for Python. + IDLE is written using Tkinter and therefore quite platform-independent. + . + This package is a dependency package, which depends on Debian's default + Python 3 version's IDLE (currently v@VER@). + +Package: python3-doc +Section: doc +Architecture: all +Multi-Arch: foreign +Depends: python@VER@-doc (>= @UPSTRVER@), ${misc:Depends} +Suggests: python3 (>= ${binary:Version}), python3-examples +Description: documentation for the high-level object-oriented language Python 3 + This is the official set of documentation for the interactive high-level + object-oriented language Python 3 (v@VER@). All documents are provided + in HTML format, some in info format. The package consists of nine documents: + . + * Tutorial + * Python Library Reference + * Macintosh Module Reference + * Python Language Reference + * Extending and Embedding Python + * Python/C API Reference + * Installing Python Modules + * Documenting Python + * Distributing Python Modules + . + This package is a dependency package, which depends on Debian's default + Python 3 version's documentation (currently v@VER@). + +Package: python3-dbg +Architecture: any +Multi-Arch: allowed +Section: debug +Depends: python3 (= ${binary:Version}), libpython3-dbg (= ${binary:Version}), python@VER@-dbg (>= @UPSTRVER@), ${misc:Depends} +Description: debug build of the Python 3 Interpreter (version @VER@) + Python 3 interpreter configured with --pydebug. Dynamically loaded modules + are searched in /usr/lib/python@VER@/lib-dynload/debug first. + +Package: libpython3-dbg +Architecture: any +Multi-Arch: same +Section: debug +Depends: libpython@VER@t64-dbg (>= @UPSTRVER@), ${misc:Depends} +Breaks: python3-dbg (<< 3.8.0-1) +Replaces: python3-dbg (<< 3.8.0-1) +Description: debug build of the Python 3 Interpreter (version @VER@) + Python 3 interpreter configured with --pydebug. Dynamically loaded modules + are searched in /usr/lib/python@VER@/lib-dynload/debug first. + +Package: python3-all +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + ${misc:Depends}, + python3.12, +Description: package depending on all supported Python 3 runtime versions + The package currently depends on python3.12, in the future, dependencies on + jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 runtimes. + +Package: python3-all-dev +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + libpython3-all-dev (= ${binary:Version}), + python3-all (= ${binary:Version}), + python3-dev (= ${binary:Version}), + ${misc:Depends}, + python3.12-dev, +Description: package depending on all supported Python 3 development packages + The package currently depends on python3.12-dev, in the future, dependencies + on jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 development + packages. + +Package: python3-all-dbg +Architecture: any +Multi-Arch: allowed +Section: debug +Depends: python3 (= ${binary:Version}), + libpython3-all-dbg (= ${binary:Version}), + python3-all (= ${binary:Version}), + python3-dbg (= ${binary:Version}), + ${misc:Depends}, + python3.12-dbg, +Description: package depending on all supported Python 3 debugging packages + The package currently depends on python3.12-dbg, in the future, dependencies + on jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 debug packages. + +Package: python3-all-venv +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + python3-all (= ${binary:Version}), + python3-venv (= ${binary:Version}), + ${misc:Depends}, + python3.12-venv, +Description: package depending on all supported Python 3 venv modules + The package currently depends on python3.12-venv, in the future, dependencies + on jython (Python for a JVM) and ironpython (Python for Mono) may be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 venv packages. + +Package: libpython3-all-dev +Architecture: any +Multi-Arch: same +Section: libdevel +Depends: libpython3-dev (= ${binary:Version}), + ${misc:Depends}, + libpython3.12-dev, +Description: package depending on all supported Python 3 development packages + The package currently depends on libpython3.12-dev, in the future, + dependencies on jython (Python for a JVM) and ironpython (Python for Mono) may + be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 development + packages. + +Package: libpython3-all-dbg +Architecture: any +Multi-Arch: same +Section: debug +Depends: libpython3-dbg (= ${binary:Version}), + ${misc:Depends}, + libpython3.12t64-dbg, +Description: package depending on all supported Python 3 debugging packages + The package currently depends on libpython3.12-dbg, in the future, + dependencies on jython (Python for a JVM) and ironpython (Python for Mono) may + be added. + . + This package is a dependency package used as a build dependency for other + packages to avoid hardcoded dependencies on specific Python 3 debug packages. + +Package: 2to3 +Architecture: all +Multi-Arch: foreign +Depends: python3-lib2to3 (>= @STDLIBVER@), python3 (>= ${binary:Version}), ${misc:Depends} +Description: 2to3 binary using python3 + 2to3 is a Python program that reads Python 2.x source code and applies a + series of fixers to transform it into valid Python 3.x code. The standard + library contains a rich set of fixers that will handle almost all code. 2to3 + supporting library lib2to3 is, however, a flexible and generic library, so it + is possible to write your own fixers for 2to3. lib2to3 could also be adapted + to custom applications in which Python code needs to be edited automatically. + . + This package is a dependency package, which depends on Debian's default + Python 3 2to3 version (currently v@VER@). + +Package: python3-full +Architecture: any +Multi-Arch: allowed +Depends: python3 (= ${binary:Version}), + python@VER@-full (>= @UPSTRVER@), + python3-venv (= ${binary:Version}), + 2to3, + idle, + python3-gdbm, + python3-lib2to3, + python3-tk, + ${shlibs:Depends}, ${misc:Depends} +Recommends: python3-doc, python3-examples, +Suggests: python3-dev +Description: Default Python Interpreter with complete class library + Python, the high-level, interactive object oriented language, + includes an extensive class library with lots of goodies for + network programming, system administration, sounds and graphics. + . + This package is a dependency package, which depends on the full + standard library of Python for Python developers. Including modules + used only at build-time, such as venv, and modules with + complex dependencies, such as tk and IDLE. All batteries included. + . + This package depends on Debian's default python 3 version's full + standard library (currently v@VER@). + . + According to the Debian Python policy, this package must not be used in + build dependencies, dependencies and recommendations. diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 000000000000000..b96d7cd724db1eb --- /dev/null +++ b/debian/copyright @@ -0,0 +1,319 @@ +This is the Debian GNU/Linux prepackaged version of the Python programming +language. Python was written by Guido van Rossum and others. + +This package was put together by Klee Dienes from +sources from ftp.python.org:/pub/python, based on the Debianization by +the previous maintainers Bernd S. Brentrup and +Bruce Perens. + +Current maintainer is Matthias Klose until the final +2.3 version is released. + + +Copyright notice (as found in LICENSE in the original source). +-------------------------------------------------------------- + +A. HISTORY OF THE SOFTWARE +========================== + +Python was created in the early 1990s by Guido van Rossum at Stichting +Mathematisch Centrum (CWI, see http://www.cwi.nl) in the Netherlands +as a successor of a language called ABC. Guido remains Python's +principal author, although it includes many contributions from others. + +In 1995, Guido continued his work on Python at the Corporation for +National Research Initiatives (CNRI, see http://www.cnri.reston.va.us) +in Reston, Virginia where he released several versions of the +software. + +In May 2000, Guido and the Python core development team moved to +BeOpen.com to form the BeOpen PythonLabs team. In October of the same +year, the PythonLabs team moved to Digital Creations (now Zope +Corporation, see http://www.zope.com). In 2001, the Python Software +Foundation (PSF, see http://www.python.org/psf/) was formed, a +non-profit organization created specifically to own Python-related +Intellectual Property. Zope Corporation is a sponsoring member of +the PSF. + +All Python releases are Open Source (see http://www.opensource.org for +the Open Source Definition). Historically, most, but not all, Python +releases have also been GPL-compatible; the table below summarizes +the various releases. + + Release Derived Year Owner GPL- + from compatible? (1) + + 0.9.0 thru 1.2 1991-1995 CWI yes + 1.3 thru 1.5.2 1.2 1995-1999 CNRI yes + 1.6 1.5.2 2000 CNRI no + 2.0 1.6 2000 BeOpen.com no + 1.6.1 1.6 2001 CNRI yes (2) + 2.1 2.0+1.6.1 2001 PSF no + 2.0.1 2.0+1.6.1 2001 PSF yes + 2.1.1 2.1+2.0.1 2001 PSF yes + 2.2 2.1.1 2001 PSF yes + 2.1.2 2.1.1 2002 PSF yes + 2.1.3 2.1.2 2002 PSF yes + 2.2.1 2.2 2002 PSF yes + 2.2.2 2.2.1 2002 PSF yes + 2.2.3 2.2.2 2003 PSF yes + 2.3 2.2.2 2002-2003 PSF yes + 2.3.1 2.3 2002-2003 PSF yes + 2.3.2 2.3.1 2002-2003 PSF yes + 2.3.3 2.3.2 2002-2003 PSF yes + 2.3.4 2.3.3 2004 PSF yes + 2.3.5 2.3.4 2005 PSF yes + 2.4 2.3 2004 PSF yes + 2.4.1 2.4 2005 PSF yes + 2.4.2 2.4.1 2005 PSF yes + 2.4.3 2.4.2 2006 PSF yes + 2.4.4 2.4.3 2006 PSF yes + 2.5 2.4 2006 PSF yes + 2.5.1 2.5 2007 PSF yes + 2.5.2 2.5.1 2008 PSF yes + 2.5.3 2.5.2 2008 PSF yes + 2.6 2.5 2008 PSF yes + 2.6.1 2.6 2008 PSF yes + 2.6.2 2.6.1 2009 PSF yes + 2.6.3 2.6.2 2009 PSF yes + 2.6.4 2.6.3 2009 PSF yes + 3.0 2.6 2008 PSF yes + 3.0.1 3.0 2009 PSF yes + 3.1 3.0.1 2009 PSF yes + 3.1.1 3.1 2009 PSF yes + +Footnotes: + +(1) GPL-compatible doesn't mean that we're distributing Python under + the GPL. All Python licenses, unlike the GPL, let you distribute + a modified version without making your changes open source. The + GPL-compatible licenses make it possible to combine Python with + other software that is released under the GPL; the others don't. + +(2) According to Richard Stallman, 1.6.1 is not GPL-compatible, + because its license has a choice of law clause. According to + CNRI, however, Stallman's lawyer has told CNRI's lawyer that 1.6.1 + is "not incompatible" with the GPL. + +Thanks to the many outside volunteers who have worked under Guido's +direction to make these releases possible. + + +B. TERMS AND CONDITIONS FOR ACCESSING OR OTHERWISE USING PYTHON +=============================================================== + +PYTHON SOFTWARE FOUNDATION LICENSE VERSION 2 +-------------------------------------------- + +1. This LICENSE AGREEMENT is between the Python Software Foundation +("PSF"), and the Individual or Organization ("Licensee") accessing and +otherwise using this software ("Python") in source or binary form and +its associated documentation. + +2. Subject to the terms and conditions of this License Agreement, PSF hereby +grants Licensee a nonexclusive, royalty-free, world-wide license to reproduce, +analyze, test, perform and/or display publicly, prepare derivative works, +distribute, and otherwise use Python alone or in any derivative version, +provided, however, that PSF's License Agreement and PSF's notice of copyright, +i.e., "Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 +Python Software Foundation; All Rights Reserved" are retained in Python alone or +in any derivative version prepared by Licensee. + +3. In the event Licensee prepares a derivative work that is based on +or incorporates Python or any part thereof, and wants to make +the derivative work available to others as provided herein, then +Licensee hereby agrees to include in any such work a brief summary of +the changes made to Python. + +4. PSF is making Python available to Licensee on an "AS IS" +basis. PSF MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, PSF MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +5. PSF SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON +FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS +A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON, +OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +6. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +7. Nothing in this License Agreement shall be deemed to create any +relationship of agency, partnership, or joint venture between PSF and +Licensee. This License Agreement does not grant permission to use PSF +trademarks or trade name in a trademark sense to endorse or promote +products or services of Licensee, or any third party. + +8. By copying, installing or otherwise using Python, Licensee +agrees to be bound by the terms and conditions of this License +Agreement. + + +BEOPEN.COM LICENSE AGREEMENT FOR PYTHON 2.0 +------------------------------------------- + +BEOPEN PYTHON OPEN SOURCE LICENSE AGREEMENT VERSION 1 + +1. This LICENSE AGREEMENT is between BeOpen.com ("BeOpen"), having an +office at 160 Saratoga Avenue, Santa Clara, CA 95051, and the +Individual or Organization ("Licensee") accessing and otherwise using +this software in source or binary form and its associated +documentation ("the Software"). + +2. Subject to the terms and conditions of this BeOpen Python License +Agreement, BeOpen hereby grants Licensee a non-exclusive, +royalty-free, world-wide license to reproduce, analyze, test, perform +and/or display publicly, prepare derivative works, distribute, and +otherwise use the Software alone or in any derivative version, +provided, however, that the BeOpen Python License is retained in the +Software, alone or in any derivative version prepared by Licensee. + +3. BeOpen is making the Software available to Licensee on an "AS IS" +basis. BEOPEN MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, BEOPEN MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF THE SOFTWARE WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +4. BEOPEN SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF THE +SOFTWARE FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS +AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THE SOFTWARE, OR ANY +DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +5. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +6. This License Agreement shall be governed by and interpreted in all +respects by the law of the State of California, excluding conflict of +law provisions. Nothing in this License Agreement shall be deemed to +create any relationship of agency, partnership, or joint venture +between BeOpen and Licensee. This License Agreement does not grant +permission to use BeOpen trademarks or trade names in a trademark +sense to endorse or promote products or services of Licensee, or any +third party. As an exception, the "BeOpen Python" logos available at +http://www.pythonlabs.com/logos.html may be used according to the +permissions granted on that web page. + +7. By copying, installing or otherwise using the software, Licensee +agrees to be bound by the terms and conditions of this License +Agreement. + + +CNRI LICENSE AGREEMENT FOR PYTHON 1.6.1 +--------------------------------------- + +1. This LICENSE AGREEMENT is between the Corporation for National +Research Initiatives, having an office at 1895 Preston White Drive, +Reston, VA 20191 ("CNRI"), and the Individual or Organization +("Licensee") accessing and otherwise using Python 1.6.1 software in +source or binary form and its associated documentation. + +2. Subject to the terms and conditions of this License Agreement, CNRI +hereby grants Licensee a nonexclusive, royalty-free, world-wide +license to reproduce, analyze, test, perform and/or display publicly, +prepare derivative works, distribute, and otherwise use Python 1.6.1 +alone or in any derivative version, provided, however, that CNRI's +License Agreement and CNRI's notice of copyright, i.e., "Copyright (c) +1995-2001 Corporation for National Research Initiatives; All Rights +Reserved" are retained in Python 1.6.1 alone or in any derivative +version prepared by Licensee. Alternately, in lieu of CNRI's License +Agreement, Licensee may substitute the following text (omitting the +quotes): "Python 1.6.1 is made available subject to the terms and +conditions in CNRI's License Agreement. This Agreement together with +Python 1.6.1 may be located on the Internet using the following +unique, persistent identifier (known as a handle): 1895.22/1013. This +Agreement may also be obtained from a proxy server on the Internet +using the following URL: http://hdl.handle.net/1895.22/1013". + +3. In the event Licensee prepares a derivative work that is based on +or incorporates Python 1.6.1 or any part thereof, and wants to make +the derivative work available to others as provided herein, then +Licensee hereby agrees to include in any such work a brief summary of +the changes made to Python 1.6.1. + +4. CNRI is making Python 1.6.1 available to Licensee on an "AS IS" +basis. CNRI MAKES NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR +IMPLIED. BY WAY OF EXAMPLE, BUT NOT LIMITATION, CNRI MAKES NO AND +DISCLAIMS ANY REPRESENTATION OR WARRANTY OF MERCHANTABILITY OR FITNESS +FOR ANY PARTICULAR PURPOSE OR THAT THE USE OF PYTHON 1.6.1 WILL NOT +INFRINGE ANY THIRD PARTY RIGHTS. + +5. CNRI SHALL NOT BE LIABLE TO LICENSEE OR ANY OTHER USERS OF PYTHON +1.6.1 FOR ANY INCIDENTAL, SPECIAL, OR CONSEQUENTIAL DAMAGES OR LOSS AS +A RESULT OF MODIFYING, DISTRIBUTING, OR OTHERWISE USING PYTHON 1.6.1, +OR ANY DERIVATIVE THEREOF, EVEN IF ADVISED OF THE POSSIBILITY THEREOF. + +6. This License Agreement will automatically terminate upon a material +breach of its terms and conditions. + +7. This License Agreement shall be governed by the federal +intellectual property law of the United States, including without +limitation the federal copyright law, and, to the extent such +U.S. federal law does not apply, by the law of the Commonwealth of +Virginia, excluding Virginia's conflict of law provisions. +Notwithstanding the foregoing, with regard to derivative works based +on Python 1.6.1 that incorporate non-separable material that was +previously distributed under the GNU General Public License (GPL), the +law of the Commonwealth of Virginia shall govern this License +Agreement only as to issues arising under or with respect to +Paragraphs 4, 5, and 7 of this License Agreement. Nothing in this +License Agreement shall be deemed to create any relationship of +agency, partnership, or joint venture between CNRI and Licensee. This +License Agreement does not grant permission to use CNRI trademarks or +trade name in a trademark sense to endorse or promote products or +services of Licensee, or any third party. + +8. By clicking on the "ACCEPT" button where indicated, or by copying, +installing or otherwise using Python 1.6.1, Licensee agrees to be +bound by the terms and conditions of this License Agreement. + + ACCEPT + + +CWI LICENSE AGREEMENT FOR PYTHON 0.9.0 THROUGH 1.2 +-------------------------------------------------- + +Copyright (c) 1991 - 1995, Stichting Mathematisch Centrum Amsterdam, +The Netherlands. All rights reserved. + +Permission to use, copy, modify, and distribute this software and its +documentation for any purpose and without fee is hereby granted, +provided that the above copyright notice appear in all copies and that +both that copyright notice and this permission notice appear in +supporting documentation, and that the name of Stichting Mathematisch +Centrum or CWI not be used in advertising or publicity pertaining to +distribution of the software without specific, written prior +permission. + +STICHTING MATHEMATISCH CENTRUM DISCLAIMS ALL WARRANTIES WITH REGARD TO +THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS, IN NO EVENT SHALL STICHTING MATHEMATISCH CENTRUM BE LIABLE +FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT +OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + + +py3compile, py3clean and debpython module: +========================================== +Copyright © 2010-2013 Piotr Ożarowski + +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. diff --git a/debian/debian_defaults b/debian/debian_defaults new file mode 100644 index 000000000000000..e99ec2033938d4e --- /dev/null +++ b/debian/debian_defaults @@ -0,0 +1,12 @@ +[DEFAULT] +# the default python3 version +default-version = python3.12 + +# all supported python3 versions +supported-versions = python3.12 + +# formerly supported python3 versions +old-versions = python3.1, python3.2, python3.3, python3.4, python3.5, python3.6, python3.7, python3.8, python3.9, python3.10, python3.11 + +# unsupported versions, including older versions +unsupported-versions = python3.1, python3.2, python3.3, python3.4, python3.5, python3.6, python3.7, python3.8, python3.9, python3.10, python3.11 diff --git a/debian/idle.1 b/debian/idle.1 new file mode 100644 index 000000000000000..cc229ece6422a15 --- /dev/null +++ b/debian/idle.1 @@ -0,0 +1,104 @@ +.TH IDLE 1 "21 September 2004" +.SH NAME +\fBIDLE\fP \- An Integrated DeveLopment Environment for Python +.SH SYNTAX +.B idle [ \fI-dins\fP ] [ \fI-t title\fP ] [ \fIfile\fP ...] +.PP +.B idle [ \fI-dins\fP ] [ \fI-t title\fP ] ( \fI-c cmd\fP | \fI-r file\fP ) [ \fIarg\fP ...] +.PP +.B idle [ \fI-dins\fP ] [ \fI-t title\fP ] - [ \fIarg\fP ...] +.SH DESCRIPTION +This manual page documents briefly the +.BR idle +command. +This manual page was written for Debian +because the original program does not have a manual page. +For more information, refer to IDLE's help menu. +.PP +.B IDLE +is an Integrated DeveLopment Environment for Python. IDLE is based on +Tkinter, Python's bindings to the Tk widget set. Features are 100% pure +Python, multi-windows with multiple undo and Python colorizing, a Python +shell window subclass, a debugger. IDLE is cross-platform, i.e. it works +on all platforms where Tk is installed. +.LP +.SH OPTIONS +.TP +.B \-h +.PD +Print this help message and exit. +.TP +.B \-n +.PD +Run IDLE without a subprocess (see Help/IDLE Help for details). +.PP +The following options will override the IDLE 'settings' configuration: +.TP +.B \-e +.PD +Open an edit window. +.TP +.B \-i +.PD +Open a shell window. +.PP +The following options imply \-i and will open a shell: +.TP +.B \-c cmd +.PD +Run the command in a shell, or +.TP +.B \-r file +.PD +Run script from file. +.PP +.TP +.B \-d +.PD +Enable the debugger. +.TP +.B \-s +.PD +Run $IDLESTARTUP or $PYTHONSTARTUP before anything else. +.TP +.B \-t title +.PD +Set title of shell window. +.PP +A default edit window will be bypassed when \-c, \-r, or \- are used. +.PP +[arg]* and [file]* are passed to the command (\-c) or script (\-r) in sys.argv[1:]. +.SH EXAMPLES +.TP +idle +.PD +Open an edit window or shell depending on IDLE's configuration. +.TP +idle foo.py foobar.py +.PD +Edit the files, also open a shell if configured to start with shell. +.TP +idle \-est "Baz" foo.py +.PD +Run $IDLESTARTUP or $PYTHONSTARTUP, edit foo.py, and open a shell +window with the title "Baz". +.TP +idle \-c "import sys; print sys.argv" "foo" +.PD +Open a shell window and run the command, passing "\-c" in sys.argv[0] +and "foo" in sys.argv[1]. +.TP +idle \-d \-s \-r foo.py "Hello World" +.PD +Open a shell window, run a startup script, enable the debugger, and +run foo.py, passing "foo.py" in sys.argv[0] and "Hello World" in +sys.argv[1]. +.TP +echo "import sys; print sys.argv" | idle - "foobar" +.PD +Open a shell window, run the script piped in, passing '' in sys.argv[0] +and "foobar" in sys.argv[1]. +.SH SEE ALSO +python(1). +.SH AUTHORS +Various. diff --git a/debian/idle.desktop b/debian/idle.desktop new file mode 100644 index 000000000000000..420e7e7b87029a0 --- /dev/null +++ b/debian/idle.desktop @@ -0,0 +1,11 @@ +[Desktop Entry] +Name=IDLE +Comment=Integrated DeveLopment Environment for Python3 +Exec=/usr/bin/idle %F +TryExec=/usr/bin/idle +Icon=/usr/share/pixmaps/idle.xpm +Terminal=false +Type=Application +Categories=Application;Development; +StartupNotify=true +MimeType=text/x-python; diff --git a/debian/idle.lintian-overrides b/debian/idle.lintian-overrides new file mode 100644 index 000000000000000..112d2a6dcd3e646 --- /dev/null +++ b/debian/idle.lintian-overrides @@ -0,0 +1 @@ +menu-icon-missing diff --git a/debian/idle.py b/debian/idle.py new file mode 100755 index 000000000000000..ba0519b38d8b68f --- /dev/null +++ b/debian/idle.py @@ -0,0 +1,5 @@ +#! /usr/bin/python3 + +from idlelib.pyshell import main +if __name__ == '__main__': + main() diff --git a/debian/py3versions b/debian/py3versions new file mode 100755 index 000000000000000..b2f04a50fbe2c8b --- /dev/null +++ b/debian/py3versions @@ -0,0 +1,6 @@ +#! /usr/bin/python3 + +import sys +sys.path[0:0] = ['/usr/share/python3'] +import py3versions +py3versions.main() diff --git a/debian/py3versions.1 b/debian/py3versions.1 new file mode 100644 index 000000000000000..5f78abc4c4c03db --- /dev/null +++ b/debian/py3versions.1 @@ -0,0 +1,53 @@ +.TH PY3VERSIONS +.SH NAME +py3versions \- print python3 version information +.SH SYNOPSIS +.PP +.B py3versions +.I [-h] [-v] [] +.SH DESCRIPTION +.PP +.B py3versions +prints information about installed, supported python3 runtimes, the +default runtime, and parses the information of the PythonVersion +fields in the package control file for Python3. +.SH OPTIONS +.TP +.I -d, --default +Show the default python3 version. +.TP +.I -s, --supported +Show the supported python3 versions. List is lowest version to highest +version with the default version last (e.g. python3.4 python3.6 python3.5 if +python3.4, 3.5, and 3.6 are supported, but python3.5 is the default python3). +.TP +.I -r, --requested [|] +Reads the value of the +.B X-Python3-Version +field in the source section of a control file and shows all matching +python3 versions. The parameter is interpreted as a version string, if +it is not the name of a file. If the X-Python3-Version field is +missing, it will fall back to list the supported Python3 +versions after checking debian/control. Versions less than 3 are +ignored. The keyword all is ignored because it covers all Python2 +versions. The former keyword current is not supported at all in +Python3. Uses the same sort order as the -s, --supported option. +.TP +.I -i, --installed +Show the installed supported python3 versions. +.TP +.I --min-supported +Show the minimum supported python3 version. +.TP +.I --max-supported +Show the maximum supported python3 version. +.TP +.I -v, --version +Limit the output to the version numbers of the python3 versions. +.TP +.I -h, --help +Print a help text. +.SH SEE ALSO +Python policy. +.SH AUTHOR +Matthias Klose diff --git a/debian/py3versions.py b/debian/py3versions.py new file mode 100755 index 000000000000000..76f9e6e3224bdb5 --- /dev/null +++ b/debian/py3versions.py @@ -0,0 +1,359 @@ +#! /usr/bin/python3 + +import os +import re +import sys + +_defaults = None +_old_versions = None +_unsupported_versions = None +_supported_versions = ["python%s" % ver.strip() for ver in + os.environ.get('DEBPYTHON3_SUPPORTED', '').split(',') + if ver.strip()] +#_default_version = "python%s" % os.environ.get('DEBPYTHON3_DEFAULT', '') +#if _default_version == 'python': +# _default_version = None +_default_version = None + + +def read_default(name=None): + global _defaults + from configparser import ConfigParser, NoOptionError + if not _defaults: + if os.path.exists('/usr/share/python3/debian_defaults'): + config = ConfigParser() + defaultsfile = open('/usr/share/python3/debian_defaults') + config.read_file(defaultsfile) + defaultsfile.close() + _defaults = config + + if _defaults and name: + try: + value = _defaults.get('DEFAULT', name) + except NoOptionError: + raise ValueError + return value + return None + + +def version_to_tuple(version): + return tuple(int(part) for part in version.split('.')) + + +def parse_versions(vstring): + if len(vstring.split(',')) > 2: + raise ValueError('too many arguments provided for X-Python3-Version: min and max only.') + import operator + operators = {None: operator.eq, '=': operator.eq, + '>=': operator.ge, '<=': operator.le, + '<<': operator.lt} + vinfo = {} + exact_versions = set() + version_range = set(supported_versions(version_only=True)) + relop_seen = False + for field in vstring.split(','): + field = field.strip() + if field == 'all': + continue + if field in ('current', 'current_ext'): + continue + vinfo.setdefault('versions', set()) + ve = re.compile(r'(>=|<=|<<|=)? *(\d\.\d+)$') + m = ve.match(field) + try: + if not m: + raise ValueError('error parsing Python3-Version attribute') + op, v = m.group(1), m.group(2) + vmaj, vmin = v.split('.') + if int(vmaj) < 3: + continue + if op in (None, '='): + exact_versions.add(v) + else: + relop_seen = True + filtop = operators[op] + version_range = [av for av in version_range if filtop( + version_to_tuple(av), version_to_tuple(v))] + except Exception: + raise ValueError('error parsing Python3-Version attribute') + if 'versions' in vinfo: + vinfo['versions'] = exact_versions + if relop_seen: + vinfo['versions'] = exact_versions.union(version_range) + return vinfo + + +def old_versions(version_only=False): + global _old_versions + if not _old_versions: + try: + value = read_default('old-versions') + _old_versions = [s.strip() for s in value.split(',')] + except ValueError: + _old_versions = [] + if version_only: + return [v[6:] for v in _old_versions] + else: + return _old_versions + + +def unsupported_versions(version_only=False): + global _unsupported_versions + if not _unsupported_versions: + try: + value = read_default('unsupported-versions') + _unsupported_versions = [s.strip() for s in value.split(',')] + except ValueError: + _unsupported_versions = [] + if version_only: + return [v[6:] for v in _unsupported_versions] + else: + return _unsupported_versions + + +def supported_versions(version_only=False): + global _supported_versions,_default_version + default_version() + if not _supported_versions: + try: + value = read_default('supported-versions') + _supported_versions = [s.strip() for s in value.split(',')] + except ValueError: + cmd = ['/usr/bin/apt-cache', '--no-all-versions', + 'show', 'python3-all'] + try: + import subprocess + p = subprocess.Popen(cmd, bufsize=1, + shell=False, stdout=subprocess.PIPE) + fd = p.stdout + except ImportError: + fd = os.popen(' '.join(cmd)) + depends = None + for line in fd: + if line.startswith('Depends:'): + depends = line.split(':', 1)[1].strip().split(',') + fd.close() + depends = [re.sub(r'\s*(\S+)[ (]?.*', r'\1', s) for s in depends] + _supported_versions = depends + default = _supported_versions.pop(_supported_versions.index(_default_version)) + _supported_versions.sort() + _supported_versions.append(default) + if version_only: + return [v[6:] for v in _supported_versions] + else: + return _supported_versions + + +def default_version(version_only=False): + global _default_version + if not _default_version: + _default_version = os.readlink('/usr/bin/python3') + # consistency check + debian_default = read_default('default-version') + if not _default_version in (debian_default, os.path.join('/usr/bin', debian_default)): + raise ValueError("the symlink /usr/bin/python3 does not point to the " + "python3 default version. It must be reset " + "to point to %s" % debian_default) + _default_version = debian_default + if version_only: + return _default_version[6:] + else: + return _default_version + + +def requested_versions(vstring, version_only=False): + global _default_version + default_version() + versions = None + vinfo = parse_versions(vstring) + supported = supported_versions(version_only=True) + if len(vinfo) == 1: + versions = vinfo['versions'].intersection(supported) + vl = [] + for version in versions: vl.append(version) + try: + default = vl.pop(vl.index(_default_version[6:])) + except: + default = '' + vl.sort() + if default: + vl.append(default) + else: + raise ValueError('No supported python3 versions in version string') + if not versions: + raise ValueError('empty set of versions') + if version_only: + return vl + else: + return ['python%s' % v for v in vl] + + +def installed_versions(version_only=False): + import glob + supported = supported_versions() + versions = [os.path.basename(s) + for s in glob.glob('/usr/bin/python3.[0-9]') + glob.glob('/usr/bin/python3.[0-9][0-9]') + if os.path.basename(s) in supported] + versions.sort() + if version_only: + return [v[6:] for v in versions] + else: + return versions + + +def minmax_supported_version(minmax, version_only=False): + supported_versions_list = supported_versions(True) + version = minmax(version_to_tuple(ver) for ver in supported_versions_list) + version_str = '%d.%d' % version + if version_only: + return version_str + else: + return 'python' + version_str + + +class ControlFileValueError(ValueError): + pass + + +class MissingVersionValueError(ValueError): + pass + + +def extract_pyversion_attribute(fn, pkg): + """read the debian/control file, extract the X-Python3-Version + field.""" + + version = None + sversion = None + section = None + with open(fn, encoding='utf-8') as controlfile: + lines = [line.strip() for line in controlfile] + for line in lines: + if line == '' and section != None: + if pkg == 'Source': + break + section = None + elif line.startswith('Source:'): + section = 'Source' + elif line.startswith('Package: ' + pkg): + section = pkg + elif line.lower().startswith('x-python3-version:'): + if section != 'Source': + raise ValueError('attribute X-Python3-Version not in Source section') + sversion = line.split(':', 1)[1].strip() + if section is None: + raise ControlFileValueError('not a control file') + if pkg == 'Source': + if sversion is None: + raise MissingVersionValueError('no X-Python3-Version in control file') + return sversion + return version + + +''' +def requested_versions_bis(vstring, version_only=False): + versions = [] + py_supported_short = supported_versions(version_only=True) + for item in vstring.split(','): + v=item.split('-') + if len(v)>1: + if not v[0]: + v[0] = py_supported_short[0] + if not v[1]: + v[1] = py_supported_short[-1] + for ver in py_supported_short: + try: + if version_cmp(ver,v[0]) >= 0 \ + and version_cmp(ver,v[1]) <= 0: + versions.append(ver) + except ValueError: + pass + else: + if v[0] in py_supported_short: + versions.append(v[0]) + versions.sort(version_cmp) + if not versions: + raise ValueError('empty set of versions') + if not version_only: + versions=['python'+i for i in versions] + return versions +''' + + +def main(): + from optparse import OptionParser + usage = '[-v] [-h] [-d|--default] [-s|--supported] [-i|--installed] ' + '[-r|--requested |]' + parser = OptionParser(usage=usage) + parser.add_option('-d', '--default', + help='print the default python3 version', + action='store_true', dest='default') + parser.add_option('-s', '--supported', + help='print the supported python3 versions', + action='store_true', dest='supported') + parser.add_option('-r', '--requested', + help='print the python3 versions requested by a build; ' + 'the argument is either the name of a control file ' + 'or the value of the X-Python3-Version attribute', + action='store_true', dest='requested') + parser.add_option('-i', '--installed', + help='print the installed supported python3 versions', + action='store_true', dest='installed') + parser.add_option('--min-supported', + help='print the minimum supported python3 version', + action='store_true', dest='minsupported') + parser.add_option('--max-supported', + help='print the maximum supported python3 version', + action='store_true', dest='maxsupported') + parser.add_option('-v', '--version', + help='print just the version number(s)', + default=False, action='store_true', dest='version_only') + opts, args = parser.parse_args() + program = os.path.basename(sys.argv[0]) + + if opts.default and len(args) == 0: + try: + print(default_version(opts.version_only)) + except ValueError as msg: + print("%s:" % program, msg) + sys.exit(1) + elif opts.supported and len(args) == 0: + print(' '.join(supported_versions(opts.version_only))) + elif opts.installed and len(args) == 0: + print(' '.join(installed_versions(opts.version_only))) + elif opts.minsupported and len(args) == 0: + print(minmax_supported_version(min, opts.version_only)) + elif opts.maxsupported and len(args) == 0: + print(minmax_supported_version(max, opts.version_only)) + elif opts.requested and len(args) <= 1: + if len(args) == 0: + versions = 'debian/control' + else: + versions = args[0] + try: + if os.path.isfile(versions): + fn = versions + try: + vstring = extract_pyversion_attribute(fn, 'Source') + vs = requested_versions(vstring, opts.version_only) + except ControlFileValueError: + sys.stderr.write("%s: not a control file: %s, " + % (program, fn)) + sys.exit(1) + except MissingVersionValueError: + sys.stderr.write("%s: no X-Python3-Version in control " + "file, using supported versions\n" % + program) + vs = supported_versions(opts.version_only) + else: + vs = requested_versions(versions, opts.version_only) + print(' '.join(vs)) + except ValueError as msg: + sys.stderr.write("%s: %s\n" % (program, msg)) + sys.exit(1) + else: + sys.stderr.write("usage: %s %s\n" % (program, usage)) + sys.exit(1) + +if __name__ == '__main__': + main() diff --git a/debian/python.mk b/debian/python.mk new file mode 100644 index 000000000000000..648117793b83581 --- /dev/null +++ b/debian/python.mk @@ -0,0 +1,46 @@ +# some macros useful for packaging python packages + +# to include it unconditionally: +# include /usr/share/python3/python.mk +# +# to include it conditionally, and have the packaging working with earlier releases +# and backports: +# -include /usr/share/python/python.mk +# ifeq (,$(py_sitename)) +# py_sitename = site-packages +# py_libdir = /usr/lib/python$(subst python,,$(1))/site-packages +# py_sitename_sh = $(py_sitename) +# py_libdir_sh = $(py_libdir) +# endif + +# py_sitename: name of the site-packages/dist-packages directory depending +# on the python version. Call as: $(call py_sitename, ). +# Don't use this in shell snippets inside loops. + +py_sitename = $(if $(filter $(subst python,,$(1)), 2.3 2.4 2.5),site,dist)-packages + +# py_libdir: absolute path to the default python library for third party +# stuff. Call as: $(call py_libdir, ). +# Don't use this in shell snippets inside loops. + +py_libdir = /usr/lib/python$(strip $(if $(findstring 3.,$(subst python,,$(1))),3,$(subst python,,$(1))))/$(py_sitename) + +# py_pkgname: package name corresponding to the python version. +# Call as: $(call py_pkgname, , ). + +py_pkgname = $(if $(findstring 3.,$(2)),$(subst python-,python3-,$(1)),$(1)) + +# setuptools' build directory +py_builddir = $(shell python$(strip $(subst python,,$(1))) -c 'import setuptools; from distutils.command.build import build; from distutils.core import Distribution; b = build(Distribution()); b.finalize_options(); print(b.build_platlib)') + + +# The same macros for use inside loops in shell snippets + +py_sitename_sh = $$(basename $$(_py_=$(strip $(1)); python$${_py_\#python*} -c 'import setuptools; from distutils import sysconfig; print(sysconfig.get_python_lib())')) + +py_libdir_sh = $$(_py_=$(strip $(1)); python$${_py_\#python*} -c 'import setuptools; from distutils import sysconfig; print(sysconfig.get_python_lib())') + +py_builddir_sh = $$(_py_=$(strip $(1)); python$${_py_\#python*} -c 'import setuptools; from distutils.command.build import build; from distutils.core import Distribution; b = build(Distribution()); b.finalize_options(); print(b.build_platlib)') + +# Arguments to pass to setup.py install +py_setup_install_args = --install-layout=deb diff --git a/debian/python3-minimal.manpages b/debian/python3-minimal.manpages new file mode 100644 index 000000000000000..fa9104ee130426d --- /dev/null +++ b/debian/python3-minimal.manpages @@ -0,0 +1,2 @@ +py3clean.1 +py3compile.1 diff --git a/debian/python3-minimal.postinst.in b/debian/python3-minimal.postinst.in new file mode 100644 index 000000000000000..a7e55a7f194eb63 --- /dev/null +++ b/debian/python3-minimal.postinst.in @@ -0,0 +1,8 @@ +#! /bin/sh +set -e + +if which py3compile >/dev/null 2>&1; then + py3compile -p python3-minimal /usr/share/python3/ +fi + +#DEBHELPER# diff --git a/debian/python3-minimal.prerm b/debian/python3-minimal.prerm new file mode 100644 index 000000000000000..fc276a88f6dc1e2 --- /dev/null +++ b/debian/python3-minimal.prerm @@ -0,0 +1,7 @@ +#! /bin/sh +set -e + +rm -rf /usr/share/python3/__pycache__ +rm -rf /usr/share/python3/debpython/__pycache__ + +#DEBHELPER# diff --git a/debian/python3.desktop b/debian/python3.desktop new file mode 100644 index 000000000000000..2e6829c8ee2a0e6 --- /dev/null +++ b/debian/python3.desktop @@ -0,0 +1,6 @@ +[Desktop Entry] +Type=KonsoleApplication +Name=Python3 Interpreter +Comment=Python3 +Exec=/usr/bin/python3 +Icon=/usr/share/pixmaps/python3.xpm diff --git a/debian/python3.doc-base.python-policy b/debian/python3.doc-base.python-policy new file mode 100644 index 000000000000000..ad05fd2c4c01559 --- /dev/null +++ b/debian/python3.doc-base.python-policy @@ -0,0 +1,14 @@ +Document: python-policy +Title: Debian Python Policy +Author: Neil Schemenauer, Matthias Klose, Gregor Hoffleit +Abstract: This document describes the packaging of Python within the Debian + GNU/Linux distribution and the policy requirements for packaged Python + programs and modules. +Section: Debian + +Format: text +Files: /usr/share/doc/python3/python-policy.txt.gz + +Format: HTML +Files: /usr/share/doc/python3/python-policy.html +Index: /usr/share/doc/python3/python-policy.html diff --git a/debian/python3.lintian-overrides b/debian/python3.lintian-overrides new file mode 100644 index 000000000000000..e4c9c0e38e86f9c --- /dev/null +++ b/debian/python3.lintian-overrides @@ -0,0 +1,2 @@ +# this is the only package that can depend on it +python3 binary: depends-on-python-minimal diff --git a/debian/python3.postinst.in b/debian/python3.postinst.in new file mode 100644 index 000000000000000..57a03c4ffb15b75 --- /dev/null +++ b/debian/python3.postinst.in @@ -0,0 +1,51 @@ +#! /bin/sh +set -e + +new_config_file() +{ + cat > /etc/python3/debian_config <<-EOF + [DEFAULT] + # how to byte-compile (comma separated: standard, optimize) + byte-compile = standard + EOF +} + +case "$1" in + configure) + _py_errors= + [ -d /etc/python3 ] || mkdir /etc/python3 + [ -f /etc/python3/debian_config ] || new_config_file + + oldv=$(echo $2 | sed 's/^\(...\).*/\1/') + if [ "$DEBIAN_FRONTEND" != noninteractive ]; then + echo "running python rtupdate hooks for @PVER@..." + fi + for hook in /usr/share/python3/runtime.d/*.rtupdate; do + [ -x $hook ] || continue + if ! $hook rtupdate python$oldv @PVER@; then + hb=$(basename $hook .rtupdate) + echo >&2 "error running python rtupdate hook $hb" + _py_errors=yes + fi + done + [ -z "$_py_errors" ] || exit 4 + + if [ "$DEBIAN_FRONTEND" != noninteractive ]; then + echo "running python post-rtupdate hooks for @PVER@..." + fi + for hook in /usr/share/python3/runtime.d/*.rtupdate; do + [ -x $hook ] || continue + if ! $hook post-rtupdate python$oldv @PVER@; then + hb=$(basename $hook .rtupdate) + echo >&2 "error running python post-rtupdate hook $hb" + _py_errors=yes + fi + done + [ -z "$_py_errors" ] || exit 5 +esac + +if which py3compile >/dev/null 2>&1; then + py3compile -p python3 /usr/share/python3/ +fi + +#DEBHELPER# diff --git a/debian/python3.postrm.in b/debian/python3.postrm.in new file mode 100644 index 000000000000000..c51b8c12ceff63b --- /dev/null +++ b/debian/python3.postrm.in @@ -0,0 +1,9 @@ +#! /bin/sh +set -e + +case "$1" in + purge) + rm -rf /etc/python3 +esac + +#DEBHELPER# diff --git a/debian/python3.preinst.in b/debian/python3.preinst.in new file mode 100644 index 000000000000000..e2b6ae2a0b3f29c --- /dev/null +++ b/debian/python3.preinst.in @@ -0,0 +1,31 @@ +#! /bin/sh +set -e + +# remove the python3 alternatives before installing our own python3 link + +update-alternatives --auto /usr/bin/python3 >/dev/null 2>&1 || true + +[ -L /usr/share/doc/python3/html ] || rm -rf /usr/share/doc/python3/html + +case "$1" in + upgrade) + _py_errors= + oldv=$(echo $2 | sed 's/^\(...\).*/\1/') + if [ "$DEBIAN_FRONTEND" != noninteractive ]; then + echo "running python pre-rtupdate hooks for @PVER@..." + fi + for hook in /usr/share/python3/runtime.d/*.rtupdate; do + [ -x $hook ] || continue + if ! $hook pre-rtupdate python$oldv @PVER@; then + hb=$(basename $hook .rtupdate) + echo >&2 "error running python pre-rtupdate hook $hb" + echo >&2 "running python failed-pre-rtupdate hook $hb" + $hook failed-pre-rtupdate python$oldv @PVER@ + _py_errors=yes + break + fi + done + [ -z "$_py_errors" ] || exit 3 +esac + +#DEBHELPER# diff --git a/debian/python3.prerm b/debian/python3.prerm new file mode 100644 index 000000000000000..75756aed39767ea --- /dev/null +++ b/debian/python3.prerm @@ -0,0 +1,8 @@ +#! /bin/sh +set -e + +if which py3clean >/dev/null 2>&1; then + py3clean -p python3 +fi + +#DEBHELPER# diff --git a/debian/rules b/debian/rules new file mode 100755 index 000000000000000..0b583ae80ddfa05 --- /dev/null +++ b/debian/rules @@ -0,0 +1,437 @@ +#!/usr/bin/make -f +# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess. + +export SHELL = /bin/bash + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +include /usr/share/dpkg/architecture.mk + +changelog_values := $(shell dpkg-parsechangelog \ + | awk '/^(Version|Source):/ {print $$2}') +PKGSOURCE := $(word 1, $(changelog_values)) +PKGVERSION := $(word 2, $(changelog_values)) +UPSTRVER := $(shell echo $(PKGVERSION) | sed 's,(.*)-.*,\1,') +VER := $(shell echo $(PKGVERSION) | awk 'BEGIN{FS="." }{print $$1 "." $$2}') +NVER := $(shell echo $(VER) | awk 'BEGIN{FS="." }{print $$1 "." $$2 + 1}') + + +distribution := $(shell dpkg-vendor --query Vendor) +distrelease := $(shell . /etc/os-release; echo $$VERSION_CODENAME) + +# required python3.x version +UPSTRVER := 3.12.6-1~ + +# required versions of python3-lib2to3 and python3-distutils +STDLIBVER := 3.12.6-1~ + +ifeq (,$(filter $(distrelease),lenny etch squeeze wheezy lucid maverick natty oneiric precise quantal raring saucy trusty)) + bd_i586 = dpkg-dev (>= 1.17.11), python3.12:any (>= 3.12.6-1~), +else + bd_i586 = dpkg-dev (>= 1.16.1~), +endif + +PWD := $(shell pwd) + +d := debian/tmp +scriptdir = usr/share/lib/python$(VER) +scriptdir = usr/share/python$(VER) +scriptdir = usr/lib/python$(VER) + +rst2html = rst2html + +ifeq (,$(findstring nodoc,$(DEB_BUILD_OPTIONS))) +with_doc = yes +else +with_doc = no +endif + +ifneq ($(with_doc),yes) + NOPKGS = -Npython3-doc +endif + +build-arch: build +build-indep: build + +build: stamp-build +stamp-build: + touch stamp-build + +stamp-doc-policy: + : # compact text version + $(MAKE) -C policy singlehtml SPHINXOPTS='-D html_theme_options.nosidebar=true' + ( \ + echo 'The HTML version of the Debian Python Policy can be found in the python3-dev package'; \ + html2text -utf8 -rcfile /usr/share/doc/html2text/examples/pretty.style \ + policy/_build/singlehtml/index.html; \ + ) > policy/_build/python-policy.txt + rm -rf policy/_build/singlehtml + + : # dh_sphinxdoc cannot handle singlehtml, so build both and then discard html + $(MAKE) -C policy html singlehtml + touch stamp-doc-policy + +ifeq ($(with_doc),yes) +stamp-doc: stamp-doc-policy +else +stamp-doc: +endif + touch stamp-doc + +control-file: + sed -e "s/@UPSTRVER@/$(UPSTRVER)/g" \ + -e "s/@STDLIBVER@/$(STDLIBVER)/g" \ + -e "s/@NVER@/$(NVER)/g" \ + -e "s/@VER@/$(VER)/g" \ + -e "s/@bd_i586@/$(bd_i586)/g" \ + debian/control.tmp +ifeq ($(distribution),Ubuntu) + ifneq (,$(findstring ubuntu, $(PKGVERSION))) + m='Ubuntu Developers '; \ + sed -i "/^Maintainer:/s/\(.*\)/Maintainer: $$m\nXSBC-Original-\1/" \ + debian/control.tmp + endif +endif + [ -e debian/control ] \ + && cmp -s debian/control debian/control.tmp \ + && rm -f debian/control.tmp && exit 0; \ + mv debian/control.tmp debian/control + +faqs = index general programming library extending windows gui installed +get-faq: + rm -rf faq + mkdir faq + cd faq && \ + wget -nv $(foreach p,$(faqs),http://python.org/doc/faq/$(p).ht) + sed 's,\<\([a-zA-Z0-9]*\.html\)\>,faq/\1,' faq/index.ht \ + | awk '/^Translations$$/ {exit} {print}' > faq/FAQ.ht + ( \ + echo ''; \ + echo 'This is a local copy of the online FAQ located at'; \ + echo 'http://python.org/doc/faq.'; \ + echo "The copy was fetched and generated in `date '+%B %Y'`."; \ + ) >> faq/FAQ.ht + rm -f faq/index.ht + +clean: control-file + dh_testdir + dh_testroot + rm -f stamp-* + rm -f patch-stamp* + + rm -rf policy/_build + rm -f faq/*.h2 faq/*.html + + set -e;\ + for f in debian/*.in; do \ + f2=`echo $$f | sed "s,PVER,python$(VER),g;s/VER/$(VER)/g;s,\.in$$,,"`; \ + if [ $$f2 != debian/control ]; then \ + rm -f $$f2; \ + fi; \ + done + rm -f debian/*.py[co] + make clean + dh_clean + +stamp-control: + : # We have to prepare the various control files + + set -e;\ + for f in debian/*.in; do \ + f2=`echo $$f | sed "s,PVER,python$(VER),g;s/VER/$(VER)/g;s,\.in$$,,"`; \ + if [ $$f2 != debian/control ]; then \ + sed -e "s/@PVER@/python$(VER)/g;s/@VER@/$(VER)/g" \ + -e "s/@PRIORITY@/$(PRIORITY)/g" \ + -e "s,@SCRIPTDIR@,/$(scriptdir),g" \ + <$$f >$$f2; \ + fi; \ + done + +install: build stamp-dh_python stamp-install +stamp-install: stamp-build control-file stamp-control + dh_testdir + dh_testroot + dh_installdirs + dh_install +ifeq (0,1) + dh_installdirs usr/share/doc/python/faq + + set -e; \ + cd faq && \ + for p in *.ht; do \ + p=`basename $$p .ht`; \ + echo $(rst2html) $$p.ht $$p.html; \ + awk 'NR > 2' $$p.ht > $$p.ht2; \ + $(rst2html) $$p.ht2 $$p.html; \ + mv $$p.html ../debian/python/usr/share/doc/python/faq/; \ + rm -f $$p.ht2; \ + done + mv debian/python/usr/share/doc/python/faq/FAQ.html \ + debian/python/usr/share/doc/python/ +endif + touch stamp-install + +stamp-dh_python: + dh_testdir + dh_testroot + dh_installdirs + #make check_versions + DESTDIR=debian/python3 PREFIX=/usr make install-dev + DESTDIR=debian/python3-minimal PREFIX=/usr make install-runtime +ifeq ($(with_doc),yes) + DESTDIR=debian/python3-minimal PREFIX=/usr make manpages +endif + # disabled by default, run manually if you want to update it + # (requires apt-file and network connection) + #make dist_fallback + touch $@ + +# Build architecture-independent files here. +binary-indep: build install stamp-doc + dh_testdir -i + dh_testroot -i + dh_installman -i + +ifeq ($(with_doc),yes) + mkdir -p debian/python3-doc/usr/share/doc/python3 + ln -sf ../python$(VER)-doc/html \ + debian/python3-doc/usr/share/doc/python3/html + mkdir -p debian/python3-doc/usr/share/doc/python3-doc + ln -sf ../python$(VER)-doc/html \ + debian/python3-doc/usr/share/doc/python3-doc/html +endif + + : # provide the idle and idle.1 defaults + mkdir -p debian/idle/usr/bin + install -m 755 debian/idle.py debian/idle/usr/bin/idle + + mkdir -p debian/idle/usr/share/man/man1 + install -m 644 debian/idle.1 debian/idle/usr/share/man/man1/idle.1 + + mkdir -p debian/idle/usr/share/pixmaps + ln -sf python3.xpm debian/idle/usr/share/pixmaps/idle.xpm + + mkdir -p debian/idle/usr/share/applications + cp -p debian/idle.desktop debian/idle/usr/share/applications/ + + : # provide the 2to3-3 a and 2to3-3.1 defaults + mkdir -p debian/2to3/usr/bin + install -m 755 debian/2to3.py debian/2to3/usr/bin/2to3 + + mkdir -p debian/2to3/usr/share/man/man1 + install -m 644 debian/2to3.1 debian/2to3/usr/share/man/man1/2to3.1 + +# dh_installdebconf -i $(NOPKGS) + dh_lintian -i + dh_installdocs -i $(NOPKGS) --all debian/README.Debian + dh_installchangelogs -i $(NOPKGS) + + for p in examples idle; do \ + case $$p in idle*) : ;; *) p=python3-$$p; esac; \ + rm -rf debian/$$p/usr/share/doc/$$p; \ + ln -sf python3 debian/$$p/usr/share/doc/$$p; \ + done + + dh_compress -i $(NOPKGS) + dh_fixperms -i $(NOPKGS) + dh_installdeb -i $(NOPKGS) + dh_gencontrol -i $(NOPKGS) + dh_md5sums -i $(NOPKGS) + dh_builddeb -i $(NOPKGS) + +# Build architecture-dependent files here. +binary-arch: build install stamp-doc + dh_testdir -a + dh_testroot -a + dh_installman -a + + : # provide the python and python.1 defaults + mkdir -p debian/python3-minimal/usr/bin + ln -sf python$(VER) debian/python3-minimal/usr/bin/python3 + mkdir -p debian/python3-minimal/usr/share/man/man1 + ln -sf python$(VER).1.gz \ + debian/python3-minimal/usr/share/man/man1/python3.1.gz + + : # + mkdir -p debian/python3-minimal/usr/share/python3 + cp -p debian/debian_defaults \ + debian/python3-minimal/usr/share/python3/ + + install -m 755 debian/py3versions.py \ + debian/python3-minimal/usr/share/python3/ + install -m 644 debian/py3versions.1 \ + debian/python3-minimal/usr/share/man/man1/ + dh_link -ppython3-minimal /usr/share/python3/py3versions.py /usr/bin/py3versions + +# mkdir debian/python-minimal/usr/share/python-central +# cp -p debian/python.pycentral debian/python-minimal/usr/share/python-central/ + + mkdir -p debian/python3/usr/bin + ln -sf pydoc$(VER) debian/python3/usr/bin/pydoc3 + ln -sf pygettext$(VER) debian/python3/usr/bin/pygettext3 + ln -sf pdb$(VER) debian/python3/usr/bin/pdb3 + + mkdir -p debian/python3/usr/share/python3 + install -m 644 debian/python.mk \ + debian/python3/usr/share/python3/ + + mkdir -p debian/python3/usr/share/man/man1 + ln -sf pydoc$(VER).1.gz \ + debian/python3/usr/share/man/man1/pydoc3.1.gz + ln -sf pygettext$(VER).1.gz \ + debian/python3/usr/share/man/man1/pygettext3.1.gz + ln -sf pdb$(VER).1.gz \ + debian/python3/usr/share/man/man1/pdb3.1.gz + +ifeq ($(with_doc),yes) + mkdir -p debian/python3/usr/share/doc/python3 + cp -p policy/_build/python-policy.txt \ + debian/python3/usr/share/doc/python3/ + + mkdir -p debian/python3-dev/usr/share/doc/python3 + : # dh_sphinxdoc cannot handle singlehtml, so build both and then discard html + cp -a policy/_build/html/* \ + debian/python3-dev/usr/share/doc/python3/ + dh_sphinxdoc -v -p python3-dev + rm -rf debian/python3-dev/usr/share/doc/python3/_sources + rm -f debian/python3-dev/usr/share/doc/python3/*.html + rm -f debian/python3-dev/usr/share/doc/python3/objects.inv + + cp -p policy/_build/singlehtml/index.html \ + debian/python3-dev/usr/share/doc/python3/python-policy.html + ln -sf python-policy.html \ + debian/python3-dev/usr/share/doc/python3/index.html +endif + + mkdir -p debian/python3/usr/share/pixmaps + ln -sf python$(VER).xpm debian/python3/usr/share/pixmaps/python3.xpm + + : # add symlinks to policy text file + mkdir -p debian/python3/usr/share/doc/python$(VER) + ln -sf ../python3/python-policy.txt.gz \ + debian/python3/usr/share/doc/python$(VER)/python-policy.txt.gz + +ifeq (0,1) + mkdir -p debian/python3/usr/share/apps/konsole + cp -p debian/python.desktop debian/python3/usr/share/apps/konsole/ +endif + + : # provide the python3-config default + mkdir -p debian/python3-dev/usr/bin + ln -sf python$(VER)-config debian/python3-dev/usr/bin/python3-config + mkdir -p debian/python3-dev/usr/share/man/man1 + ln -sf python$(VER)-config.1.gz \ + debian/python3-dev/usr/share/man/man1/python3-config.1.gz + + : # provide pkgconfig defaults + mkdir -p debian/libpython3-dev/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig + ln -sf python-$(VER).pc \ + debian/libpython3-dev/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/python3.pc + + mkdir -p debian/libpython3-dbg/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig + ln -sf python-$(VER)-dbg.pc \ + debian/libpython3-dbg/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/python3-dbg.pc + ln -sf python-$(VER)d.pc \ + debian/libpython3-dbg/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/python3d.pc + + ln -sf python-$(VER)-embed.pc \ + debian/libpython3-dev/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/python3-embed.pc + + ln -sf python-$(VER)d-embed.pc \ + debian/libpython3-dbg/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/python3d-embed.pc + ln -sf python-$(VER)d-embed.pc \ + debian/libpython3-dbg/usr/lib/$(DEB_HOST_MULTIARCH)/pkgconfig/python3-dbg-embed.pc + + : # provide the python-dbg and python-dbg.1 defaults + mkdir -p debian/python3-dbg/usr/bin + ln -sf python$(VER)d debian/python3-dbg/usr/bin/python3d + ln -sf python$(VER)d-config debian/python3-dbg/usr/bin/python3d-config + ln -sf python$(VER)-dbg debian/python3-dbg/usr/bin/python3-dbg + ln -sf python$(VER)-dbg-config debian/python3-dbg/usr/bin/python3-dbg-config + mkdir -p debian/python3-dbg/usr/share/man/man1 + ln -sf python$(VER)d.1.gz \ + debian/python3-dbg/usr/share/man/man1/python3d.1.gz + ln -sf python$(VER)d-config.1.gz \ + debian/python3-dbg/usr/share/man/man1/python3d-config.1.gz + ln -sf python$(VER)-dbg.1.gz \ + debian/python3-dbg/usr/share/man/man1/python3-dbg.1.gz + ln -sf python$(VER)-dbg-config.1.gz \ + debian/python3-dbg/usr/share/man/man1/python3-dbg-config.1.gz + mkdir -p debian/python3-dbg/usr/share/doc/python3 + ln -sf ../python$(VER)/SpecialBuilds.txt.gz \ + debian/python3-dbg/usr/share/doc/python3/SpecialBuilds.txt.gz + ln -sf ../python$(VER)/README.debug \ + debian/python3-dbg/usr/share/doc/python3/README.debug + + mkdir -p debian/python3/usr/lib/valgrind + cp -p debian/valgrind-python.supp \ + debian/python3/usr/lib/valgrind/python3.supp + + : # provide the DEB_HOST_GNU_TYPE/DEB_HOST_MULTIRACH python-config defaults + mkdir -p debian/libpython3-dev/usr/bin + ln -sf $(DEB_HOST_MULTIARCH)-python$(VER)-config \ + debian/libpython3-dev/usr/bin/$(DEB_HOST_MULTIARCH)-python3-config + mkdir -p debian/libpython3-dev/usr/share/man/man1 + ln -sf $(DEB_HOST_MULTIARCH)-python$(VER)-config.1.gz \ + debian/libpython3-dev/usr/share/man/man1/$(DEB_HOST_MULTIARCH)-python3-config.1.gz +ifneq ($(DEB_HOST_MULTIARCH),$(DEB_HOST_GNU_TYPE)) + ln -sf $(DEB_HOST_GNU_TYPE)-python$(VER)-config \ + debian/libpython3-dev/usr/bin/$(DEB_HOST_GNU_TYPE)-python3-config + ln -sf $(DEB_HOST_GNU_TYPE)-python$(VER)-config.1.gz \ + debian/libpython3-dev/usr/share/man/man1/$(DEB_HOST_GNU_TYPE)-python3-config.1.gz +endif + + mkdir -p debian/libpython3-dbg/usr/bin + ln -sf $(DEB_HOST_MULTIARCH)-python$(VER)d-config \ + debian/libpython3-dbg/usr/bin/$(DEB_HOST_MULTIARCH)-python3d-config + ln -sf $(DEB_HOST_MULTIARCH)-python$(VER)-dbg-config \ + debian/libpython3-dbg/usr/bin/$(DEB_HOST_MULTIARCH)-python3-dbg-config + mkdir -p debian/libpython3-dbg/usr/share/man/man1 + ln -sf $(DEB_HOST_MULTIARCH)-python$(VER)d-config.1.gz \ + debian/libpython3-dbg/usr/share/man/man1/$(DEB_HOST_MULTIARCH)-python3d-config.1.gz + ln -sf $(DEB_HOST_MULTIARCH)-python$(VER)-dbg-config.1.gz \ + debian/libpython3-dbg/usr/share/man/man1/$(DEB_HOST_MULTIARCH)-python3-dbg-config.1.gz +ifneq ($(DEB_HOST_MULTIARCH),$(DEB_HOST_GNU_TYPE)) + ln -sf $(DEB_HOST_GNU_TYPE)-python$(VER)d-config \ + debian/libpython3-dbg/usr/bin/$(DEB_HOST_GNU_TYPE)-python3d-config + ln -sf $(DEB_HOST_GNU_TYPE)-python$(VER)-dbg-config \ + debian/libpython3-dbg/usr/bin/$(DEB_HOST_GNU_TYPE)-python3-dbg-config + ln -sf $(DEB_HOST_GNU_TYPE)-python$(VER)d-config.1.gz \ + debian/libpython3-dbg/usr/share/man/man1/$(DEB_HOST_GNU_TYPE)-python3d-config.1.gz + ln -sf $(DEB_HOST_GNU_TYPE)-python$(VER)-dbg-config.1.gz \ + debian/libpython3-dbg/usr/share/man/man1/$(DEB_HOST_GNU_TYPE)-python3-dbg-config.1.gz +endif + + : # python3-nopie + mkdir -p debian/python3-nopie/usr/bin + ln -sf python$(VER)-pie debian/python3-nopie/usr/bin/python3-pie + + dh_lintian -a + dh_installdocs -a $(NOPKGS) --all debian/README.Debian + dh_installchangelogs -a $(NOPKGS) + + for p in all all-dev all-dbg dbg dev nopie venv full; do \ + case $$p in idle*) : ;; *) p=python3-$$p; esac; \ + rm -rf debian/$$p/usr/share/doc/$$p; \ + ln -sf python3 debian/$$p/usr/share/doc/$$p; \ + done + rm -rf debian/libpython3-all-dev/usr/share/doc/libpython3-all-dev + ln -sf libpython3-dev debian/libpython3-all-dev/usr/share/doc/libpython3-all-dev + rm -rf debian/libpython3-all-dbg/usr/share/doc/libpython3-all-dbg + ln -sf libpython3-dbg debian/libpython3-all-dbg/usr/share/doc/libpython3-all-dbg + + dh_compress -a $(NOPKGS) + dh_fixperms -a $(NOPKGS) + dh_installdeb -a $(NOPKGS) + dh_gencontrol -a $(NOPKGS) + dh_md5sums -a $(NOPKGS) + dh_builddeb -a $(NOPKGS) + +binary: binary-indep binary-arch + +.PHONY: control-file configure build clean binary-indep binary-arch binary install + +# Local Variables: +# mode: makefile +# end: diff --git a/debian/source.lintian-overrides b/debian/source.lintian-overrides new file mode 100644 index 000000000000000..dc83957ef67b888 --- /dev/null +++ b/debian/source.lintian-overrides @@ -0,0 +1,7 @@ +# this source package provides these packages so it cannot depend on them +dbg-package-missing-depends python3-all-dbg +dbg-package-missing-depends python3-dbg +dbg-package-missing-depends libpython3-all-dbg +dbg-package-missing-depends libpython3-dbg + +native-package-with-dash-version diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 000000000000000..d3827e75a5cadb9 --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +1.0 diff --git a/debian/valgrind-python.supp b/debian/valgrind-python.supp new file mode 100644 index 000000000000000..043e11d69f8681a --- /dev/null +++ b/debian/valgrind-python.supp @@ -0,0 +1,511 @@ +# +# This is a valgrind suppression file that should be used when using valgrind. +# +# --------------------------------------------------------------------------- +# Debian note: +# The file Misc/valgrind-python.supp is placed in an modified form into the +# directory /usr/lib/valgrind as python.supp. There's no need to to add it +# with the --suppressions option. +# The unmodified file is found in /usr/share/doc/python3.11/ +# +# The python3.6-dbg build has been compiled with -DPy_USING_MEMORY_DEBUGGER +# so you can safely comment out the suppressions for PyObject_Free and +# PyObject_Realloc. +# --------------------------------------------------------------------------- + +# Here's an example of running valgrind: +# +# cd python/dist/src +# valgrind --tool=memcheck --suppressions=Misc/valgrind-python.supp \ +# ./python -E ./Lib/test/regrtest.py -u gui,network +# +# You must edit Objects/obmalloc.c and uncomment Py_USING_MEMORY_DEBUGGER +# to use the preferred suppressions with address_in_range. +# +# If you do not want to recompile Python, you can uncomment +# suppressions for _PyObject_Free and _PyObject_Realloc. +# +# See Misc/README.valgrind for more information. + +# all tool names: Addrcheck,Memcheck,cachegrind,helgrind,massif +{ + ADDRESS_IN_RANGE/Invalid read of size 4 + Memcheck:Addr4 + fun:address_in_range +} + +{ + ADDRESS_IN_RANGE/Invalid read of size 4 + Memcheck:Value4 + fun:address_in_range +} + +{ + ADDRESS_IN_RANGE/Invalid read of size 8 (x86_64 aka amd64) + Memcheck:Value8 + fun:address_in_range +} + +{ + ADDRESS_IN_RANGE/Conditional jump or move depends on uninitialised value + Memcheck:Cond + fun:address_in_range +} + +# +# Leaks (including possible leaks) +# Hmmm, I wonder if this masks some real leaks. I think it does. +# Will need to fix that. +# + +{ + Suppress leaking the GIL. Happens once per process, see comment in ceval.c. + Memcheck:Leak + fun:malloc + fun:PyThread_allocate_lock + fun:PyEval_InitThreads +} + +{ + Suppress leaking the GIL after a fork. + Memcheck:Leak + fun:malloc + fun:PyThread_allocate_lock + fun:PyEval_ReInitThreads +} + +{ + Suppress leaking the autoTLSkey. This looks like it shouldn't leak though. + Memcheck:Leak + fun:malloc + fun:PyThread_create_key + fun:_PyGILState_Init + fun:Py_InitializeEx + fun:Py_Main +} + +{ + Hmmm, is this a real leak or like the GIL? + Memcheck:Leak + fun:malloc + fun:PyThread_ReInitTLS +} + +{ + Handle PyMalloc confusing valgrind (possibly leaked) + Memcheck:Leak + fun:realloc + fun:_PyObject_GC_Resize + fun:COMMENT_THIS_LINE_TO_DISABLE_LEAK_WARNING +} + +{ + Handle PyMalloc confusing valgrind (possibly leaked) + Memcheck:Leak + fun:malloc + fun:_PyObject_GC_New + fun:COMMENT_THIS_LINE_TO_DISABLE_LEAK_WARNING +} + +{ + Handle PyMalloc confusing valgrind (possibly leaked) + Memcheck:Leak + fun:malloc + fun:_PyObject_GC_NewVar + fun:COMMENT_THIS_LINE_TO_DISABLE_LEAK_WARNING +} + +# +# Non-python specific leaks +# + +{ + Handle pthread issue (possibly leaked) + Memcheck:Leak + fun:calloc + fun:allocate_dtv + fun:_dl_allocate_tls_storage + fun:_dl_allocate_tls +} + +{ + Handle pthread issue (possibly leaked) + Memcheck:Leak + fun:memalign + fun:_dl_allocate_tls_storage + fun:_dl_allocate_tls +} + +###{ +### ADDRESS_IN_RANGE/Invalid read of size 4 +### Memcheck:Addr4 +### fun:_PyObject_Free +###} +### +###{ +### ADDRESS_IN_RANGE/Invalid read of size 4 +### Memcheck:Value4 +### fun:_PyObject_Free +###} +### +###{ +### ADDRESS_IN_RANGE/Use of uninitialised value of size 8 +### Memcheck:Addr8 +### fun:_PyObject_Free +###} +### +###{ +### ADDRESS_IN_RANGE/Use of uninitialised value of size 8 +### Memcheck:Value8 +### fun:_PyObject_Free +###} +### +###{ +### ADDRESS_IN_RANGE/Conditional jump or move depends on uninitialised value +### Memcheck:Cond +### fun:_PyObject_Free +###} + +###{ +### ADDRESS_IN_RANGE/Invalid read of size 4 +### Memcheck:Addr4 +### fun:_PyObject_Realloc +###} +### +###{ +### ADDRESS_IN_RANGE/Invalid read of size 4 +### Memcheck:Value4 +### fun:_PyObject_Realloc +###} +### +###{ +### ADDRESS_IN_RANGE/Use of uninitialised value of size 8 +### Memcheck:Addr8 +### fun:_PyObject_Realloc +###} +### +###{ +### ADDRESS_IN_RANGE/Use of uninitialised value of size 8 +### Memcheck:Value8 +### fun:_PyObject_Realloc +###} +### +###{ +### ADDRESS_IN_RANGE/Conditional jump or move depends on uninitialised value +### Memcheck:Cond +### fun:_PyObject_Realloc +###} + +### +### All the suppressions below are for errors that occur within libraries +### that Python uses. The problems to not appear to be related to Python's +### use of the libraries. +### + +{ + Generic ubuntu ld problems + Memcheck:Addr8 + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so + obj:/lib/ld-2.4.so +} + +{ + Generic gentoo ld problems + Memcheck:Cond + obj:/lib/ld-2.3.4.so + obj:/lib/ld-2.3.4.so + obj:/lib/ld-2.3.4.so + obj:/lib/ld-2.3.4.so +} + +{ + DBM problems, see test_dbm + Memcheck:Param + write(buf) + fun:write + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + fun:dbm_close +} + +{ + DBM problems, see test_dbm + Memcheck:Value8 + fun:memmove + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + fun:dbm_store + fun:dbm_ass_sub +} + +{ + DBM problems, see test_dbm + Memcheck:Cond + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + fun:dbm_store + fun:dbm_ass_sub +} + +{ + DBM problems, see test_dbm + Memcheck:Cond + fun:memmove + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + obj:/usr/lib/libdb1.so.2 + fun:dbm_store + fun:dbm_ass_sub +} + +{ + GDBM problems, see test_gdbm + Memcheck:Param + write(buf) + fun:write + fun:gdbm_open + +} + +{ + Uninitialised byte(s) false alarm, see bpo-35561 + Memcheck:Param + epoll_ctl(event) + fun:epoll_ctl + fun:pyepoll_internal_ctl +} + +{ + ZLIB problems, see test_gzip + Memcheck:Cond + obj:/lib/libz.so.1.2.3 + obj:/lib/libz.so.1.2.3 + fun:deflate +} + +{ + Avoid problems w/readline doing a putenv and leaking on exit + Memcheck:Leak + fun:malloc + fun:xmalloc + fun:sh_set_lines_and_columns + fun:_rl_get_screen_size + fun:_rl_init_terminal_io + obj:/lib/libreadline.so.4.3 + fun:rl_initialize +} + +# Valgrind emits "Conditional jump or move depends on uninitialised value(s)" +# false alarms on GCC builtin strcmp() function. The GCC code is correct. +# +# Valgrind bug: https://bugs.kde.org/show_bug.cgi?id=264936 +{ + bpo-38118: Valgrind emits false alarm on GCC builtin strcmp() + Memcheck:Cond + fun:PyUnicode_Decode +} + + +### +### These occur from somewhere within the SSL, when running +### test_socket_sll. They are too general to leave on by default. +### +###{ +### somewhere in SSL stuff +### Memcheck:Cond +### fun:memset +###} +###{ +### somewhere in SSL stuff +### Memcheck:Value4 +### fun:memset +###} +### +###{ +### somewhere in SSL stuff +### Memcheck:Cond +### fun:MD5_Update +###} +### +###{ +### somewhere in SSL stuff +### Memcheck:Value4 +### fun:MD5_Update +###} + +# Fedora's package "openssl-1.0.1-0.1.beta2.fc17.x86_64" on x86_64 +# See http://bugs.python.org/issue14171 +{ + openssl 1.0.1 prng 1 + Memcheck:Cond + fun:bcmp + fun:fips_get_entropy + fun:FIPS_drbg_instantiate + fun:RAND_init_fips + fun:OPENSSL_init_library + fun:SSL_library_init + fun:init_hashlib +} + +{ + openssl 1.0.1 prng 2 + Memcheck:Cond + fun:fips_get_entropy + fun:FIPS_drbg_instantiate + fun:RAND_init_fips + fun:OPENSSL_init_library + fun:SSL_library_init + fun:init_hashlib +} + +{ + openssl 1.0.1 prng 3 + Memcheck:Value8 + fun:_x86_64_AES_encrypt_compact + fun:AES_encrypt +} + +# +# All of these problems come from using test_socket_ssl +# +{ + from test_socket_ssl + Memcheck:Cond + fun:BN_bin2bn +} + +{ + from test_socket_ssl + Memcheck:Cond + fun:BN_num_bits_word +} + +{ + from test_socket_ssl + Memcheck:Value4 + fun:BN_num_bits_word +} + +{ + from test_socket_ssl + Memcheck:Cond + fun:BN_mod_exp_mont_word +} + +{ + from test_socket_ssl + Memcheck:Cond + fun:BN_mod_exp_mont +} + +{ + from test_socket_ssl + Memcheck:Param + write(buf) + fun:write + obj:/usr/lib/libcrypto.so.0.9.7 +} + +{ + from test_socket_ssl + Memcheck:Cond + fun:RSA_verify +} + +{ + from test_socket_ssl + Memcheck:Value4 + fun:RSA_verify +} + +{ + from test_socket_ssl + Memcheck:Value4 + fun:DES_set_key_unchecked +} + +{ + from test_socket_ssl + Memcheck:Value4 + fun:DES_encrypt2 +} + +{ + from test_socket_ssl + Memcheck:Cond + obj:/usr/lib/libssl.so.0.9.7 +} + +{ + from test_socket_ssl + Memcheck:Value4 + obj:/usr/lib/libssl.so.0.9.7 +} + +{ + from test_socket_ssl + Memcheck:Cond + fun:BUF_MEM_grow_clean +} + +{ + from test_socket_ssl + Memcheck:Cond + fun:memcpy + fun:ssl3_read_bytes +} + +{ + from test_socket_ssl + Memcheck:Cond + fun:SHA1_Update +} + +{ + from test_socket_ssl + Memcheck:Value4 + fun:SHA1_Update +} + +{ + test_buffer_non_debug + Memcheck:Addr4 + fun:PyUnicodeUCS2_FSConverter +} + +{ + test_buffer_non_debug + Memcheck:Addr4 + fun:PyUnicode_FSConverter +} + +{ + wcscmp_false_positive + Memcheck:Addr8 + fun:wcscmp + fun:_PyOS_GetOpt + fun:Py_Main + fun:main +} + +# Additional suppressions for the unified decimal tests: +{ + test_decimal + Memcheck:Addr4 + fun:PyUnicodeUCS2_FSConverter +} + +{ + test_decimal2 + Memcheck:Addr4 + fun:PyUnicode_FSConverter +} + diff --git a/debian/watch b/debian/watch new file mode 100644 index 000000000000000..21b00a8f22ddcb5 --- /dev/null +++ b/debian/watch @@ -0,0 +1,2 @@ +version=4 +https://www.python.org/downloads/ .*/Python@ANY_VERSION@@ARCHIVE_EXT@ diff --git a/pyconfig.h.in b/pyconfig.h.in index 924d86627b0e9ba..b5a1b0beba6f7c7 100644 --- a/pyconfig.h.in +++ b/pyconfig.h.in @@ -260,6 +260,10 @@ don't. */ #undef HAVE_DECL_RTLD_NOW +/* Define to 1 if you have the declaration of `SSL_ECH_STATUS_GREASE_ECH', and + to 0 if you don't. */ +#undef HAVE_DECL_SSL_ECH_STATUS_GREASE_ECH + /* Define to 1 if you have the declaration of `tzname', and to 0 if you don't. */ #undef HAVE_DECL_TZNAME @@ -898,6 +902,9 @@ /* Define to 1 if you have the `openpty' function. */ #undef HAVE_OPENPTY +/* Define to 1 if you have the header file. */ +#undef HAVE_OPENSSL_ECH_H + /* Define if you have the 'panel' library */ #undef HAVE_PANEL @@ -1617,6 +1624,12 @@ /* Define if mvwdelch in curses.h is an expression. */ #undef MVWDELCH_IS_EXPRESSION +/* Define if OpenSSL has ECH support */ +#undef OPENSSL_ECH + +/* Define if OpenSSL does not have ECH support */ +#undef OPENSSL_NO_ECH + /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT