python3-m2crypto: Use qq format when time_t is 64bit on 32bit system

Fixes:
   # python3 -munittest -v test_ssl.MiscSSLClientTestCase.test_server_simple_timeouts
test_server_simple_timeouts (test_ssl.MiscSSLClientTestCase.test_server_simple_timeouts) ... ERROR

======================================================================
ERROR: test_server_simple_timeouts (test_ssl.MiscSSLClientTestCase.test_server_simple_timeouts)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/opt/python3-m2crypto/tests/test_ssl.py", line 474, in test_server_simple_timeouts
    s.set_socket_read_timeout(SSL.timeout())
    ~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^
  File "/usr/lib/python3.13/site-packages/M2Crypto/SSL/Connection.py", line 680, in set_socket_read_timeout
    self.socket.setsockopt(
    ~~~~~~~~~~~~~~~~~~~~~~^
        socket.SOL_SOCKET, socket.SO_RCVTIMEO, timeo.pack()
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    )
    ^
OSError: [Errno 22] Invalid argument

Signed-off-by: Mingli Yu <mingli.yu@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
This commit is contained in:
Mingli Yu
2025-07-01 17:16:38 +08:00
committed by Khem Raj
parent 9b7e0506ce
commit 5cce697ae1
2 changed files with 81 additions and 0 deletions

View File

@@ -8,6 +8,7 @@ SRC_URI[sha256sum] = "d0fc81a8828edbf4308432b3040bf06bb26bad95abb9e7d4690b611855
SRC_URI += " \
file://0001-setup.py-Make-the-cmd-available.patch \
file://0001-timeout.py-use-qq-format-when-time_t-is-64bit-on-32b.patch \
"
inherit pypi siteinfo python_setuptools_build_meta