diff -Nur breezy-brz-3.2.2.orig/breezy/bzr/_chk_map_pyx.pyx breezy-brz-3.2.2/breezy/bzr/_chk_map_pyx.pyx
--- breezy-brz-3.2.2.orig/breezy/bzr/_chk_map_pyx.pyx	2022-03-20 02:51:38.000000000 +0100
+++ breezy-brz-3.2.2/breezy/bzr/_chk_map_pyx.pyx	2025-05-11 09:57:40.526320800 +0200
@@ -40,8 +40,8 @@
 from cpython.dict cimport (
     PyDict_SetItem,
     )
-from cpython.int cimport (
-    PyInt_AsUnsignedLongMask,
+from cpython.long cimport (
+    PyLong_AsUnsignedLongMask,
     )
 from cpython.object cimport (
     PyObject,
@@ -102,7 +102,7 @@
         if i > 0:
             c_out[0] = c'\x00'
             c_out = c_out + 1
-        crc_val = PyInt_AsUnsignedLongMask(crc32(key[i])) & 0xFFFFFFFFUL
+        crc_val = PyLong_AsUnsignedLongMask(crc32(key[i])) & 0xFFFFFFFFUL
         # Hex(val) order
         sprintf(c_out, '%08lX', crc_val)
         c_out = c_out + 8
@@ -127,7 +127,7 @@
         if i > 0:
             c_out[0] = c'\x00'
             c_out = c_out + 1
-        crc_val = PyInt_AsUnsignedLongMask(crc32(key[i]))
+        crc_val = PyLong_AsUnsignedLongMask(crc32(key[i]))
         # MSB order
         c_out[0] = (crc_val >> 24) & 0xFF
         c_out[1] = (crc_val >> 16) & 0xFF
diff -Nur breezy-brz-3.2.2.orig/breezy/bzr/_dirstate_helpers_pyx.pyx breezy-brz-3.2.2/breezy/bzr/_dirstate_helpers_pyx.pyx
--- breezy-brz-3.2.2.orig/breezy/bzr/_dirstate_helpers_pyx.pyx	2022-03-20 02:51:38.000000000 +0100
+++ breezy-brz-3.2.2/breezy/bzr/_dirstate_helpers_pyx.pyx	2025-05-11 09:57:33.137587800 +0200
@@ -98,7 +98,7 @@
     object PyTuple_GetItem_void_object "PyTuple_GET_ITEM" (void* tpl, int index)
     object PyTuple_GET_ITEM(object tpl, Py_ssize_t index)
 
-    unsigned long PyInt_AsUnsignedLongMask(object number) except? -1
+    unsigned long PyLong_AsUnsignedLongMask(object number) except? -1
 
     char *PyBytes_AsString(object p)
     char *PyBytes_AsString_obj "PyBytes_AsString" (PyObject *string)
@@ -800,7 +800,7 @@
 cdef unsigned long _time_to_unsigned(object t):  # cannot_raise
     if PyFloat_Check(t):
         t = t.__int__()
-    return PyInt_AsUnsignedLongMask(t)
+    return PyLong_AsUnsignedLongMask(t)
 
 
 cdef _pack_stat(stat_value):
@@ -812,13 +812,13 @@
     cdef char result[6*4] # 6 long ints
     cdef int *aliased
     aliased = <int *>result
-    aliased[0] = htonl(PyInt_AsUnsignedLongMask(stat_value.st_size))
+    aliased[0] = htonl(PyLong_AsUnsignedLongMask(stat_value.st_size))
     # mtime and ctime will often be floats but get converted to PyInt within
     aliased[1] = htonl(_time_to_unsigned(stat_value.st_mtime))
     aliased[2] = htonl(_time_to_unsigned(stat_value.st_ctime))
-    aliased[3] = htonl(PyInt_AsUnsignedLongMask(stat_value.st_dev))
-    aliased[4] = htonl(PyInt_AsUnsignedLongMask(stat_value.st_ino))
-    aliased[5] = htonl(PyInt_AsUnsignedLongMask(stat_value.st_mode))
+    aliased[3] = htonl(PyLong_AsUnsignedLongMask(stat_value.st_dev))
+    aliased[4] = htonl(PyLong_AsUnsignedLongMask(stat_value.st_ino))
+    aliased[5] = htonl(PyLong_AsUnsignedLongMask(stat_value.st_mode))
     packed = PyBytes_FromStringAndSize(result, 6*4)
     return _encode(packed)[:-1]
 
