pyobjc-framework-libxpc 11.1__tar.gz → 12.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Lib/pyobjc_framework_libxpc.egg-info/PKG-INFO +6 -5
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Lib/pyobjc_framework_libxpc.egg-info/SOURCES.txt +4 -6
- pyobjc_framework_libxpc-12.1/Lib/pyobjc_framework_libxpc.egg-info/pyobjc-build-info.txt +3 -0
- pyobjc_framework_libxpc-12.1/Lib/pyobjc_framework_libxpc.egg-info/requires.txt +2 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Lib/xpc/_metadata.py +66 -5
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Modules/_xpc.m +24 -25
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Modules/pyobjc-api.h +6 -3
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Modules/pyobjc-compat.h +51 -96
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PKG-INFO +6 -5
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/test_connection.py +4 -0
- pyobjc_framework_libxpc-12.1/PyObjCTest/test_listener.py +18 -0
- pyobjc_framework_libxpc-12.1/PyObjCTest/test_peer_requirement.py +48 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/test_session.py +4 -0
- pyobjc_framework_libxpc-11.1/metadata/raw/arm64-15.0.fwinfo → pyobjc_framework_libxpc-12.1/metadata/raw/arm64-26.0.fwinfo +156 -3
- pyobjc_framework_libxpc-11.1/metadata/raw/x86_64-15.0.fwinfo → pyobjc_framework_libxpc-12.1/metadata/raw/x86_64-26.0.fwinfo +156 -3
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/metadata/xpc.fwinfo +39 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/pyobjc_setup.py +5 -4
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/setup.py +1 -1
- pyobjc_framework_libxpc-11.1/Lib/pyobjc_framework_libxpc.egg-info/pyobjc-build-info.txt +0 -3
- pyobjc_framework_libxpc-11.1/Lib/pyobjc_framework_libxpc.egg-info/requires.txt +0 -2
- pyobjc_framework_libxpc-11.1/metadata/raw/arm64-13.1.fwinfo +0 -2327
- pyobjc_framework_libxpc-11.1/metadata/raw/arm64-14.5.fwinfo +0 -2605
- pyobjc_framework_libxpc-11.1/metadata/raw/x86_64-13.1.fwinfo +0 -2327
- pyobjc_framework_libxpc-11.1/metadata/raw/x86_64-14.5.fwinfo +0 -2605
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Lib/pyobjc_framework_libxpc.egg-info/dependency_links.txt +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Lib/pyobjc_framework_libxpc.egg-info/not-zip-safe +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Lib/pyobjc_framework_libxpc.egg-info/top_level.txt +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/Lib/xpc/__init__.py +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/License.txt +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/MANIFEST.in +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/__init__.py +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/test_activity.py +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/test_debug.py +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/test_endpoint.py +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/test_rich_error.py +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/PyObjCTest/test_xpc.py +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/metadata/metadata.ini +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/pyproject.toml +0 -0
- {pyobjc_framework_libxpc-11.1 → pyobjc_framework_libxpc-12.1}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pyobjc-framework-libxpc
|
|
3
|
-
Version:
|
|
3
|
+
Version: 12.1
|
|
4
4
|
Summary: Wrappers for xpc on macOS
|
|
5
5
|
Home-page: https://github.com/ronaldoussoren/pyobjc
|
|
6
6
|
Author: Ronald Oussoren
|
|
@@ -17,20 +17,21 @@ Classifier: Operating System :: MacOS :: MacOS X
|
|
|
17
17
|
Classifier: Programming Language :: Python
|
|
18
18
|
Classifier: Programming Language :: Python :: 3
|
|
19
19
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
20
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
21
20
|
Classifier: Programming Language :: Python :: 3.10
|
|
22
21
|
Classifier: Programming Language :: Python :: 3.11
|
|
23
22
|
Classifier: Programming Language :: Python :: 3.12
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.13
|
|
25
24
|
Classifier: Programming Language :: Python :: 3.14
|
|
25
|
+
Classifier: Programming Language :: Python :: 3.15
|
|
26
26
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
27
|
+
Classifier: Programming Language :: Python :: Free Threading :: 3 - Stable
|
|
27
28
|
Classifier: Programming Language :: Objective C
|
|
28
29
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
29
30
|
Classifier: Topic :: Software Development :: User Interfaces
|
|
30
|
-
Requires-Python: >=3.
|
|
31
|
+
Requires-Python: >=3.10
|
|
31
32
|
Description-Content-Type: text/x-rst; charset=UTF-8
|
|
32
|
-
Requires-Dist: pyobjc-core>=
|
|
33
|
-
Requires-Dist: pyobjc-framework-Cocoa>=
|
|
33
|
+
Requires-Dist: pyobjc-core>=12.1
|
|
34
|
+
Requires-Dist: pyobjc-framework-Cocoa>=12.1
|
|
34
35
|
Dynamic: author
|
|
35
36
|
Dynamic: author-email
|
|
36
37
|
Dynamic: classifier
|
|
@@ -20,14 +20,12 @@ PyObjCTest/test_activity.py
|
|
|
20
20
|
PyObjCTest/test_connection.py
|
|
21
21
|
PyObjCTest/test_debug.py
|
|
22
22
|
PyObjCTest/test_endpoint.py
|
|
23
|
+
PyObjCTest/test_listener.py
|
|
24
|
+
PyObjCTest/test_peer_requirement.py
|
|
23
25
|
PyObjCTest/test_rich_error.py
|
|
24
26
|
PyObjCTest/test_session.py
|
|
25
27
|
PyObjCTest/test_xpc.py
|
|
26
28
|
metadata/metadata.ini
|
|
27
29
|
metadata/xpc.fwinfo
|
|
28
|
-
metadata/raw/arm64-
|
|
29
|
-
metadata/raw/
|
|
30
|
-
metadata/raw/arm64-15.0.fwinfo
|
|
31
|
-
metadata/raw/x86_64-13.1.fwinfo
|
|
32
|
-
metadata/raw/x86_64-14.5.fwinfo
|
|
33
|
-
metadata/raw/x86_64-15.0.fwinfo
|
|
30
|
+
metadata/raw/arm64-26.0.fwinfo
|
|
31
|
+
metadata/raw/x86_64-26.0.fwinfo
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# This file is generated by objective.metadata
|
|
2
2
|
#
|
|
3
|
-
# Last update:
|
|
3
|
+
# Last update: Sun Aug 3 10:00:24 2025
|
|
4
4
|
#
|
|
5
5
|
# flake8: noqa
|
|
6
6
|
|
|
@@ -89,6 +89,17 @@ functions = {
|
|
|
89
89
|
"",
|
|
90
90
|
{"arguments": {1: {"c_array_delimited_by_null": True, "type_modifier": "n"}}},
|
|
91
91
|
),
|
|
92
|
+
"xpc_peer_requirement_create_entitlement_exists": (
|
|
93
|
+
b"@^t^@",
|
|
94
|
+
"",
|
|
95
|
+
{
|
|
96
|
+
"retval": {"already_retained": True},
|
|
97
|
+
"arguments": {
|
|
98
|
+
0: {"c_array_delimited_by_null": True, "type_modifier": "n"},
|
|
99
|
+
1: {"type_modifier": "o"},
|
|
100
|
+
},
|
|
101
|
+
},
|
|
102
|
+
),
|
|
92
103
|
"xpc_array_get_double": (b"d@Q",),
|
|
93
104
|
"xpc_array_get_bool": (b"B@Q",),
|
|
94
105
|
"xpc_dictionary_set_uuid": (
|
|
@@ -132,6 +143,25 @@ functions = {
|
|
|
132
143
|
"xpc_array_dup_fd": (b"i@Q",),
|
|
133
144
|
"xpc_activity_set_criteria": (b"v@@",),
|
|
134
145
|
"xpc_shmem_create": (b"@^vQ", "", {"retval": {"already_retained": True}}),
|
|
146
|
+
"xpc_peer_requirement_create_platform_identity": (
|
|
147
|
+
b"@^t^@",
|
|
148
|
+
"",
|
|
149
|
+
{
|
|
150
|
+
"retval": {"already_retained": True},
|
|
151
|
+
"arguments": {
|
|
152
|
+
0: {"c_array_delimited_by_null": True, "type_modifier": "n"},
|
|
153
|
+
1: {"type_modifier": "o"},
|
|
154
|
+
},
|
|
155
|
+
},
|
|
156
|
+
),
|
|
157
|
+
"xpc_peer_requirement_create_lwcr": (
|
|
158
|
+
b"@@^@",
|
|
159
|
+
"",
|
|
160
|
+
{
|
|
161
|
+
"retval": {"already_retained": True},
|
|
162
|
+
"arguments": {1: {"type_modifier": "o"}},
|
|
163
|
+
},
|
|
164
|
+
),
|
|
135
165
|
"xpc_connection_get_egid": (b"I@",),
|
|
136
166
|
"xpc_array_get_value": (b"@@Q",),
|
|
137
167
|
"xpc_activity_get_state": (b"q@",),
|
|
@@ -149,6 +179,17 @@ functions = {
|
|
|
149
179
|
"arguments": {1: {"c_array_delimited_by_null": True, "type_modifier": "n"}},
|
|
150
180
|
},
|
|
151
181
|
),
|
|
182
|
+
"xpc_peer_requirement_create_entitlement_matches_value": (
|
|
183
|
+
b"@^t@^@",
|
|
184
|
+
"",
|
|
185
|
+
{
|
|
186
|
+
"retval": {"already_retained": True},
|
|
187
|
+
"arguments": {
|
|
188
|
+
0: {"c_array_delimited_by_null": True, "type_modifier": "n"},
|
|
189
|
+
2: {"type_modifier": "o"},
|
|
190
|
+
},
|
|
191
|
+
},
|
|
192
|
+
),
|
|
152
193
|
"xpc_array_set_data": (
|
|
153
194
|
b"v@Q^vQ",
|
|
154
195
|
"",
|
|
@@ -156,11 +197,17 @@ functions = {
|
|
|
156
197
|
),
|
|
157
198
|
"xpc_array_set_date": (b"v@Qq",),
|
|
158
199
|
"xpc_session_set_target_queue": (b"v@@",),
|
|
200
|
+
"xpc_get_type": (b"^{_xpc_type_s=}@",),
|
|
159
201
|
"xpc_dictionary_get_uint64": (
|
|
160
202
|
b"Q@^t",
|
|
161
203
|
"",
|
|
162
204
|
{"arguments": {1: {"c_array_delimited_by_null": True, "type_modifier": "n"}}},
|
|
163
205
|
),
|
|
206
|
+
"xpc_peer_requirement_match_received_message": (
|
|
207
|
+
b"B@@^@",
|
|
208
|
+
"",
|
|
209
|
+
{"arguments": {2: {"type_modifier": "o"}}},
|
|
210
|
+
),
|
|
164
211
|
"xpc_debugger_api_misuse_info": (
|
|
165
212
|
b"^t",
|
|
166
213
|
"",
|
|
@@ -360,6 +407,7 @@ functions = {
|
|
|
360
407
|
},
|
|
361
408
|
),
|
|
362
409
|
"xpc_session_send_message": (b"@@@", "", {"retval": {"already_retained": True}}),
|
|
410
|
+
"xpc_listener_set_peer_requirement": (b"v@@",),
|
|
363
411
|
"xpc_array_create_empty": (b"@", "", {"retval": {"already_retained": True}}),
|
|
364
412
|
"xpc_activity_unregister": (
|
|
365
413
|
b"v^t",
|
|
@@ -382,6 +430,7 @@ functions = {
|
|
|
382
430
|
{"retval": {"c_array_of_variable_length": True}},
|
|
383
431
|
),
|
|
384
432
|
"xpc_int64_create": (b"@q", "", {"retval": {"already_retained": True}}),
|
|
433
|
+
"xpc_session_set_peer_requirement": (b"v@@",),
|
|
385
434
|
"xpc_array_get_array": (b"@@Q",),
|
|
386
435
|
"xpc_connection_create_from_endpoint": (
|
|
387
436
|
b"@@",
|
|
@@ -389,6 +438,17 @@ functions = {
|
|
|
389
438
|
{"retval": {"already_retained": True}},
|
|
390
439
|
),
|
|
391
440
|
"xpc_array_get_uuid": (b"^v@Q", "", {"retval": {"c_array_of_fixed_length": 16}}),
|
|
441
|
+
"xpc_peer_requirement_create_team_identity": (
|
|
442
|
+
b"@^t^@",
|
|
443
|
+
"",
|
|
444
|
+
{
|
|
445
|
+
"retval": {"already_retained": True},
|
|
446
|
+
"arguments": {
|
|
447
|
+
0: {"c_array_delimited_by_null": True, "type_modifier": "n"},
|
|
448
|
+
1: {"type_modifier": "o"},
|
|
449
|
+
},
|
|
450
|
+
},
|
|
451
|
+
),
|
|
392
452
|
"xpc_connection_activate": (b"v@",),
|
|
393
453
|
"xpc_activity_copy_criteria": (b"@@", "", {"retval": {"already_retained": True}}),
|
|
394
454
|
"xpc_session_create_mach_service": (
|
|
@@ -451,7 +511,7 @@ functions = {
|
|
|
451
511
|
},
|
|
452
512
|
),
|
|
453
513
|
"xpc_connection_set_peer_lightweight_code_requirement": (b"i@@",),
|
|
454
|
-
"
|
|
514
|
+
"xpc_connection_set_peer_requirement": (b"v@@",),
|
|
455
515
|
"xpc_hash": (b"Q@",),
|
|
456
516
|
"xpc_dictionary_set_int64": (
|
|
457
517
|
b"v@^tq",
|
|
@@ -702,11 +762,12 @@ functions = {
|
|
|
702
762
|
"xpc_date_get_value": (b"q@",),
|
|
703
763
|
}
|
|
704
764
|
aliases = {
|
|
705
|
-
"
|
|
706
|
-
"XPC_TESTEXPORT": "XPC_NOEXPORT",
|
|
765
|
+
"XPC_TESTNORETURN": "XPC_NORETURN",
|
|
707
766
|
"XPC_RETURNS_RETAINED": "OS_OBJECT_RETURNS_RETAINED",
|
|
708
|
-
"
|
|
767
|
+
"XPC_TESTEXPORT": "XPC_NOEXPORT",
|
|
709
768
|
"XPC_NONNULL_ARRAY": "_Nonnull",
|
|
769
|
+
"XPC_ERROR_KEY_DESCRIPTION": "_xpc_error_key_description",
|
|
770
|
+
"XPC_EVENT_KEY_NAME": "_xpc_event_key_name",
|
|
710
771
|
}
|
|
711
772
|
expressions = {}
|
|
712
773
|
|
|
@@ -177,8 +177,8 @@ static struct int64_constants {
|
|
|
177
177
|
|
|
178
178
|
#pragma clang diagnostic pop
|
|
179
179
|
|
|
180
|
-
|
|
181
|
-
|
|
180
|
+
static int
|
|
181
|
+
mod_exec_module(PyObject* module)
|
|
182
182
|
{
|
|
183
183
|
if (PyObjC_ImportAPI(module) == -1)
|
|
184
184
|
return -1;
|
|
@@ -233,16 +233,19 @@ static int mod_exec_module(PyObject* module)
|
|
|
233
233
|
xpc_object_t d;
|
|
234
234
|
|
|
235
235
|
d = XPC_ERROR_CONNECTION_INTERRUPTED;
|
|
236
|
-
if (add_constant(module, "XPC_ERROR_CONNECTION_INTERRUPTED", @encode(xpc_object_t),
|
|
236
|
+
if (add_constant(module, "XPC_ERROR_CONNECTION_INTERRUPTED", @encode(xpc_object_t),
|
|
237
|
+
&d)
|
|
237
238
|
!= 0)
|
|
238
239
|
goto error;
|
|
239
240
|
|
|
240
241
|
d = XPC_ERROR_CONNECTION_INVALID;
|
|
241
|
-
if (add_constant(module, "XPC_ERROR_CONNECTION_INVALID", @encode(xpc_object_t), &d)
|
|
242
|
+
if (add_constant(module, "XPC_ERROR_CONNECTION_INVALID", @encode(xpc_object_t), &d)
|
|
243
|
+
!= 0)
|
|
242
244
|
goto error;
|
|
243
245
|
|
|
244
246
|
d = XPC_ERROR_TERMINATION_IMMINENT;
|
|
245
|
-
if (add_constant(module, "XPC_ERROR_TERMINATION_IMMINENT", @encode(xpc_object_t), &d)
|
|
247
|
+
if (add_constant(module, "XPC_ERROR_TERMINATION_IMMINENT", @encode(xpc_object_t), &d)
|
|
248
|
+
!= 0)
|
|
246
249
|
goto error;
|
|
247
250
|
|
|
248
251
|
#if PyObjC_BUILD_RELEASE >= 1200
|
|
@@ -337,45 +340,41 @@ error:
|
|
|
337
340
|
}
|
|
338
341
|
|
|
339
342
|
static struct PyModuleDef_Slot mod_slots[] = {
|
|
340
|
-
{
|
|
341
|
-
.slot = Py_mod_exec,
|
|
342
|
-
.value = (void*)mod_exec_module
|
|
343
|
-
},
|
|
343
|
+
{.slot = Py_mod_exec, .value = (void*)mod_exec_module},
|
|
344
344
|
#if PY_VERSION_HEX >= 0x030c0000
|
|
345
345
|
{
|
|
346
346
|
/* Subinterpreters are not yet supported because of PyObjC_API */
|
|
347
|
-
.slot
|
|
347
|
+
.slot = Py_mod_multiple_interpreters,
|
|
348
348
|
.value = Py_MOD_MULTIPLE_INTERPRETERS_NOT_SUPPORTED,
|
|
349
349
|
},
|
|
350
350
|
#endif
|
|
351
351
|
#if PY_VERSION_HEX >= 0x030d0000
|
|
352
352
|
{
|
|
353
353
|
/* The code in this extension should be safe to use without the GIL */
|
|
354
|
-
.slot
|
|
354
|
+
.slot = Py_mod_gil,
|
|
355
355
|
.value = Py_MOD_GIL_NOT_USED,
|
|
356
356
|
},
|
|
357
357
|
#endif
|
|
358
|
-
{
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
}
|
|
362
|
-
};
|
|
358
|
+
{/* Sentinel */
|
|
359
|
+
.slot = 0,
|
|
360
|
+
.value = 0}};
|
|
363
361
|
|
|
364
362
|
static struct PyModuleDef mod_module = {
|
|
365
|
-
.m_base
|
|
366
|
-
.m_name
|
|
367
|
-
.m_doc
|
|
368
|
-
.m_size
|
|
369
|
-
.m_methods
|
|
370
|
-
.m_slots
|
|
363
|
+
.m_base = PyModuleDef_HEAD_INIT,
|
|
364
|
+
.m_name = "_xpc",
|
|
365
|
+
.m_doc = NULL,
|
|
366
|
+
.m_size = 0,
|
|
367
|
+
.m_methods = mod_methods,
|
|
368
|
+
.m_slots = mod_slots,
|
|
371
369
|
.m_traverse = NULL,
|
|
372
|
-
.m_clear
|
|
373
|
-
.m_free
|
|
370
|
+
.m_clear = NULL,
|
|
371
|
+
.m_free = NULL,
|
|
374
372
|
};
|
|
375
373
|
|
|
376
374
|
PyObject* PyInit__xpc(void);
|
|
377
375
|
|
|
378
|
-
PyObject* __attribute__((__visibility__("default")))
|
|
376
|
+
PyObject* __attribute__((__visibility__("default")))
|
|
377
|
+
PyInit__xpc(void)
|
|
379
378
|
{
|
|
380
379
|
return PyModuleDef_Init(&mod_module);
|
|
381
380
|
}
|
|
@@ -53,8 +53,9 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
53
53
|
/*
|
|
54
54
|
* Only add items to the end of this list!
|
|
55
55
|
*/
|
|
56
|
+
|
|
56
57
|
typedef int(RegisterMethodMappingFunctionType)(
|
|
57
|
-
Class, SEL,
|
|
58
|
+
Class _Nullable, SEL,
|
|
58
59
|
PyObject* _Nullable (*_Nonnull)(PyObject* _Nonnull, PyObject* _Nonnull,
|
|
59
60
|
PyObject* _Nonnull const* _Nonnull, size_t),
|
|
60
61
|
IMP _Nullable (*_Nonnull)(PyObject* _Nonnull, PyObject* _Nonnull));
|
|
@@ -83,7 +84,8 @@ struct pyobjc_api {
|
|
|
83
84
|
PyObject* _Nullable (*_Nonnull unsupported_method_caller)(
|
|
84
85
|
PyObject* _Nonnull, PyObject* _Nonnull, PyObject* _Nonnull const* _Nonnull,
|
|
85
86
|
size_t);
|
|
86
|
-
void (*_Nonnull err_python_to_objc_gil)(PyGILState_STATE* _Nonnull state)
|
|
87
|
+
void (*_Nonnull err_python_to_objc_gil)(PyGILState_STATE* _Nonnull state)
|
|
88
|
+
__attribute__((__noreturn__));
|
|
87
89
|
int (*_Nonnull simplify_sig)(const char* signature, char* buf, size_t buflen);
|
|
88
90
|
void (*_Nonnull free_c_array)(int, Py_buffer*);
|
|
89
91
|
int (*_Nonnull py_to_c_array)(BOOL, BOOL, const char* _Nonnull, PyObject* _Nonnull,
|
|
@@ -113,7 +115,8 @@ struct pyobjc_api {
|
|
|
113
115
|
int (*_Nonnull checknokwnames)(PyObject* _Nonnull callable,
|
|
114
116
|
PyObject* _Nullable kwnames);
|
|
115
117
|
|
|
116
|
-
PyObject* _Nullable (*_Nonnull createopaquepointertype)(const char*, const char*,
|
|
118
|
+
PyObject* _Nullable (*_Nonnull createopaquepointertype)(const char*, const char*,
|
|
119
|
+
const char*);
|
|
117
120
|
};
|
|
118
121
|
|
|
119
122
|
#ifndef PYOBJC_BUILD
|
|
@@ -22,12 +22,14 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
22
22
|
* Start of compiler definitions
|
|
23
23
|
*
|
|
24
24
|
*/
|
|
25
|
+
#if 0
|
|
25
26
|
#ifndef __has_feature
|
|
26
27
|
#define __has_feature(x) 0
|
|
27
28
|
#endif
|
|
28
29
|
#ifndef __has_extension
|
|
29
30
|
#define __has_extension(x) __has_feature(x)
|
|
30
31
|
#endif
|
|
32
|
+
#endif
|
|
31
33
|
|
|
32
34
|
#if __has_extension(c_static_assert)
|
|
33
35
|
#define STATIC_ASSERT(test, message) _Static_assert(test, message)
|
|
@@ -59,42 +61,8 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
59
61
|
* XXX: Are these needed?
|
|
60
62
|
*/
|
|
61
63
|
|
|
62
|
-
#ifdef __GNUC__
|
|
63
64
|
#define unlikely(x) __builtin_expect(!!(x), 0)
|
|
64
65
|
#define likely(x) __builtin_expect(!!(x), 1)
|
|
65
|
-
#else
|
|
66
|
-
#define likely(x) x
|
|
67
|
-
#define likely(x) x
|
|
68
|
-
#endif
|
|
69
|
-
|
|
70
|
-
/* On some versions of GCC <limits.h> defines LONG_LONG_MAX but not LLONG_MAX, compensate.
|
|
71
|
-
*/
|
|
72
|
-
#ifndef LLONG_MIN
|
|
73
|
-
#ifdef LONG_LONG_MIN
|
|
74
|
-
#define LLONG_MIN LONG_LONG_MIN
|
|
75
|
-
#define LLONG_MAX LONG_LONG_MAX
|
|
76
|
-
#define ULLONG_MAX ULONG_LONG_MAX
|
|
77
|
-
#endif
|
|
78
|
-
#endif
|
|
79
|
-
|
|
80
|
-
/*
|
|
81
|
-
*
|
|
82
|
-
* End of compiler support helpers
|
|
83
|
-
*
|
|
84
|
-
* XXX: These two are no longer needed, all supported platforms
|
|
85
|
-
* are 64-bit
|
|
86
|
-
*/
|
|
87
|
-
|
|
88
|
-
#if __LP64__
|
|
89
|
-
#define Py_ARG_NSInteger "l"
|
|
90
|
-
#define Py_ARG_NSUInteger "k"
|
|
91
|
-
#else
|
|
92
|
-
#define Py_ARG_NSInteger "i"
|
|
93
|
-
#define Py_ARG_NSUInteger "I"
|
|
94
|
-
#endif
|
|
95
|
-
|
|
96
|
-
#define PyObjC__STR(x) #x
|
|
97
|
-
#define PyObjC_STR(x) PyObjC__STR(x)
|
|
98
66
|
|
|
99
67
|
/*
|
|
100
68
|
*
|
|
@@ -123,34 +91,6 @@ NS_ASSUME_NONNULL_BEGIN
|
|
|
123
91
|
} while (0)
|
|
124
92
|
#endif
|
|
125
93
|
|
|
126
|
-
#if PY_VERSION_HEX < 0x03090000
|
|
127
|
-
|
|
128
|
-
/* For use on Python 3.8 and earlier. PyObjC doesn't use the
|
|
129
|
-
* "flag" bit internally.
|
|
130
|
-
*/
|
|
131
|
-
|
|
132
|
-
#ifndef PY_VECTORCALL_ARGUMENTS_OFFSET
|
|
133
|
-
#define PY_VECTORCALL_ARGUMENTS_OFFSET ((size_t)1 << (8 * sizeof(size_t) - 1))
|
|
134
|
-
#endif
|
|
135
|
-
|
|
136
|
-
#define PyVectorcall_NARGS(nargsf) ((nargsf) & ~PY_VECTORCALL_ARGUMENTS_OFFSET)
|
|
137
|
-
|
|
138
|
-
#ifdef OBJC_VERSION
|
|
139
|
-
/* Don't use PyObject prefixed symbols in our binaries */
|
|
140
|
-
#define PyObject_Vectorcall PyObjC_Vectorcall
|
|
141
|
-
#define PyObject_VectorcallMethod PyObjC_VectorcallMethod
|
|
142
|
-
|
|
143
|
-
extern PyObject* _Nullable PyObject_Vectorcall(PyObject* callable,
|
|
144
|
-
PyObject* _Nonnull const* _Nonnull args,
|
|
145
|
-
size_t nargsf,
|
|
146
|
-
PyObject* _Nullable kwnames);
|
|
147
|
-
extern PyObject* _Nullable PyObject_VectorcallMethod(
|
|
148
|
-
PyObject* name, PyObject* _Nonnull const* _Nonnull args, size_t nargsf,
|
|
149
|
-
PyObject* _Nullable kwnames);
|
|
150
|
-
#endif
|
|
151
|
-
|
|
152
|
-
#endif /* Python < 3.9 */
|
|
153
|
-
|
|
154
94
|
/* Use CLINIC_SEP between the prototype and
|
|
155
95
|
* description in doc strings, to get clean
|
|
156
96
|
* docstrings.
|
|
@@ -159,20 +99,6 @@ extern PyObject* _Nullable PyObject_VectorcallMethod(
|
|
|
159
99
|
|
|
160
100
|
extern int PyObjC_Cmp(PyObject* o1, PyObject* o2, int* result);
|
|
161
101
|
|
|
162
|
-
/*
|
|
163
|
-
* A micro optimization: when using Python 3.3 or later it
|
|
164
|
-
* is possible to access a 'char*' with an ASCII representation
|
|
165
|
-
* of a unicode object without first converting it to a bytes
|
|
166
|
-
* string (if the string can be encoded as ASCII in the first
|
|
167
|
-
* place.
|
|
168
|
-
*
|
|
169
|
-
* This slightly reduces the object allocation rate during
|
|
170
|
-
* attribute access.
|
|
171
|
-
*
|
|
172
|
-
* XXX: Use PyUnicode_AsUTF8 instead.
|
|
173
|
-
*/
|
|
174
|
-
extern const char* _Nullable PyObjC_Unicode_Fast_Bytes(PyObject* object);
|
|
175
|
-
|
|
176
102
|
#ifdef __clang__
|
|
177
103
|
|
|
178
104
|
#ifndef Py_LIMITED_API
|
|
@@ -198,7 +124,10 @@ _PyObjCTuple_SetItem(PyObject* tuple, Py_ssize_t idx, PyObject* _Nullable value)
|
|
|
198
124
|
static inline PyObject*
|
|
199
125
|
_PyObjCTuple_GetItem(PyObject* tuple, Py_ssize_t idx)
|
|
200
126
|
{
|
|
201
|
-
|
|
127
|
+
/* The protocol for tuples is that they are full initialized
|
|
128
|
+
* before handing them over to other code.
|
|
129
|
+
*/
|
|
130
|
+
return (PyObject* _Nonnull)PyTuple_GET_ITEM(tuple, idx); // LCOV_BR_EXCL_LINE
|
|
202
131
|
}
|
|
203
132
|
#undef PyTuple_GET_ITEM
|
|
204
133
|
#define PyTuple_GET_ITEM(a, b) _PyObjCTuple_GetItem(a, b)
|
|
@@ -242,13 +171,15 @@ _PyObjCTuple_GetItem(PyObject* tuple, Py_ssize_t idx)
|
|
|
242
171
|
|
|
243
172
|
#if PY_VERSION_HEX < 0x030a0000
|
|
244
173
|
|
|
245
|
-
static inline PyObject*
|
|
174
|
+
static inline PyObject*
|
|
175
|
+
Py_NewRef(PyObject* o)
|
|
246
176
|
{
|
|
247
177
|
Py_INCREF(o);
|
|
248
178
|
return o;
|
|
249
179
|
}
|
|
250
180
|
|
|
251
|
-
static inline PyObject*
|
|
181
|
+
static inline PyObject*
|
|
182
|
+
Py_XNewRef(PyObject* o)
|
|
252
183
|
{
|
|
253
184
|
Py_XINCREF(o);
|
|
254
185
|
return o;
|
|
@@ -257,11 +188,16 @@ static inline PyObject* Py_XNewRef(PyObject* o)
|
|
|
257
188
|
#endif /* PY_VERSION_HEX < 0x030a0000 */
|
|
258
189
|
|
|
259
190
|
#if PY_VERSION_HEX < 0x030d0000
|
|
260
|
-
#define Py_BEGIN_CRITICAL_SECTION(value)
|
|
191
|
+
#define Py_BEGIN_CRITICAL_SECTION(value) \
|
|
192
|
+
{ \
|
|
193
|
+
(void)(value);
|
|
261
194
|
#define Py_END_CRITICAL_SECTION() }
|
|
262
195
|
#define Py_EXIT_CRITICAL_SECTION() ((void)0)
|
|
263
196
|
|
|
264
|
-
#define Py_BEGIN_CRITICAL_SECTION2(value1, value2)
|
|
197
|
+
#define Py_BEGIN_CRITICAL_SECTION2(value1, value2) \
|
|
198
|
+
{ \
|
|
199
|
+
(void)(value1); \
|
|
200
|
+
(void)(value2);
|
|
265
201
|
#define Py_END_CRITICAL_SECTION2() }
|
|
266
202
|
#define Py_EXIT_CRITICAL_SECTION2() ((void)0)
|
|
267
203
|
|
|
@@ -282,7 +218,8 @@ static inline PyObject* Py_XNewRef(PyObject* o)
|
|
|
282
218
|
#endif
|
|
283
219
|
|
|
284
220
|
#if PY_VERSION_HEX < 0x030d0000
|
|
285
|
-
static inline int
|
|
221
|
+
static inline int
|
|
222
|
+
PyDict_GetItemRef(PyObject* p, PyObject* key, PyObject* _Nonnull* _Nullable result)
|
|
286
223
|
{
|
|
287
224
|
*result = PyDict_GetItemWithError(p, key);
|
|
288
225
|
if (*result == NULL) {
|
|
@@ -303,10 +240,28 @@ static inline PyObject* _Nullable PyList_GetItemRef(PyObject* l, Py_ssize_t i)
|
|
|
303
240
|
Py_XINCREF(result);
|
|
304
241
|
return result;
|
|
305
242
|
}
|
|
243
|
+
|
|
244
|
+
static inline int
|
|
245
|
+
PyDict_SetDefaultRef(PyObject* p, PyObject* key, PyObject* default_value,
|
|
246
|
+
PyObject* _Nonnull* _Nullable result)
|
|
247
|
+
{
|
|
248
|
+
*result = PyDict_SetDefault(p, key, default_value);
|
|
249
|
+
if (*result == NULL) {
|
|
250
|
+
return -1;
|
|
251
|
+
}
|
|
252
|
+
Py_INCREF(*result);
|
|
253
|
+
|
|
254
|
+
/* This does not follow the spec, should return 1 when the key was already
|
|
255
|
+
* in the dict. That part of the API is not used in PyObjC though.
|
|
256
|
+
*/
|
|
257
|
+
return 0;
|
|
258
|
+
}
|
|
259
|
+
|
|
306
260
|
#endif
|
|
307
261
|
|
|
308
262
|
#if PY_VERSION_HEX < 0x030c0000
|
|
309
|
-
static inline PyObject*
|
|
263
|
+
static inline PyObject*
|
|
264
|
+
PyType_GetDict(PyTypeObject* type)
|
|
310
265
|
{
|
|
311
266
|
PyObject* result = type->tp_dict;
|
|
312
267
|
Py_INCREF(result);
|
|
@@ -319,12 +274,13 @@ static inline PyObject* PyType_GetDict(PyTypeObject* type)
|
|
|
319
274
|
* These are available in 3.14 and above, the definitions below
|
|
320
275
|
* mirror the private implementation in 3.13.
|
|
321
276
|
*/
|
|
322
|
-
static inline int
|
|
277
|
+
static inline int
|
|
278
|
+
PyUnstable_Object_IsUniquelyReferenced(PyObject* ob)
|
|
323
279
|
{
|
|
324
280
|
#ifdef Py_GIL_DISABLED
|
|
325
|
-
return (_Py_IsOwnedByCurrentThread(ob)
|
|
326
|
-
_Py_atomic_load_uint32_relaxed(&ob->ob_ref_local) == 1
|
|
327
|
-
_Py_atomic_load_ssize_relaxed(&ob->ob_ref_shared) == 0);
|
|
281
|
+
return (_Py_IsOwnedByCurrentThread(ob)
|
|
282
|
+
&& _Py_atomic_load_uint32_relaxed(&ob->ob_ref_local) == 1
|
|
283
|
+
&& _Py_atomic_load_ssize_relaxed(&ob->ob_ref_shared) == 0);
|
|
328
284
|
#else
|
|
329
285
|
return Py_REFCNT(ob) == 1;
|
|
330
286
|
#endif
|
|
@@ -340,8 +296,8 @@ PyUnstable_EnableTryIncRef(PyObject* op __attribute__((__unused__)))
|
|
|
340
296
|
// Nothing to do if it's in WEAKREFS, QUEUED, or MERGED states.
|
|
341
297
|
return;
|
|
342
298
|
}
|
|
343
|
-
if (_Py_atomic_compare_exchange_ssize(
|
|
344
|
-
|
|
299
|
+
if (_Py_atomic_compare_exchange_ssize(&op->ob_ref_shared, &shared,
|
|
300
|
+
shared | _Py_REF_MAYBE_WEAKREF)) {
|
|
345
301
|
return;
|
|
346
302
|
}
|
|
347
303
|
}
|
|
@@ -350,7 +306,8 @@ PyUnstable_EnableTryIncRef(PyObject* op __attribute__((__unused__)))
|
|
|
350
306
|
|
|
351
307
|
#ifdef Py_GIL_DISABLED
|
|
352
308
|
static inline int
|
|
353
|
-
_Py_TryIncrefFast(PyObject
|
|
309
|
+
_Py_TryIncrefFast(PyObject* op)
|
|
310
|
+
{
|
|
354
311
|
uint32_t local = _Py_atomic_load_uint32_relaxed(&op->ob_ref_local);
|
|
355
312
|
local += 1;
|
|
356
313
|
if (local == 0) {
|
|
@@ -369,7 +326,7 @@ _Py_TryIncrefFast(PyObject *op) {
|
|
|
369
326
|
}
|
|
370
327
|
|
|
371
328
|
static inline int
|
|
372
|
-
_Py_TryIncRefShared(PyObject
|
|
329
|
+
_Py_TryIncRefShared(PyObject* op)
|
|
373
330
|
{
|
|
374
331
|
Py_ssize_t shared = _Py_atomic_load_ssize_relaxed(&op->ob_ref_shared);
|
|
375
332
|
for (;;) {
|
|
@@ -379,10 +336,8 @@ _Py_TryIncRefShared(PyObject *op)
|
|
|
379
336
|
return 0;
|
|
380
337
|
}
|
|
381
338
|
|
|
382
|
-
if (_Py_atomic_compare_exchange_ssize(
|
|
383
|
-
|
|
384
|
-
&shared,
|
|
385
|
-
shared + (1 << _Py_REF_SHARED_SHIFT))) {
|
|
339
|
+
if (_Py_atomic_compare_exchange_ssize(&op->ob_ref_shared, &shared,
|
|
340
|
+
shared + (1 << _Py_REF_SHARED_SHIFT))) {
|
|
386
341
|
#ifdef Py_REF_DEBUG
|
|
387
342
|
_Py_IncRefTotal(_PyThreadState_GET());
|
|
388
343
|
#endif
|
|
@@ -394,7 +349,7 @@ _Py_TryIncRefShared(PyObject *op)
|
|
|
394
349
|
#endif
|
|
395
350
|
|
|
396
351
|
static inline int
|
|
397
|
-
PyUnstable_TryIncRef(PyObject
|
|
352
|
+
PyUnstable_TryIncRef(PyObject* op __attribute__((__unused__)))
|
|
398
353
|
{
|
|
399
354
|
#ifdef Py_GIL_DISABLED
|
|
400
355
|
return _Py_TryIncrefFast(op) || _Py_TryIncRefShared(op);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pyobjc-framework-libxpc
|
|
3
|
-
Version:
|
|
3
|
+
Version: 12.1
|
|
4
4
|
Summary: Wrappers for xpc on macOS
|
|
5
5
|
Home-page: https://github.com/ronaldoussoren/pyobjc
|
|
6
6
|
Author: Ronald Oussoren
|
|
@@ -17,20 +17,21 @@ Classifier: Operating System :: MacOS :: MacOS X
|
|
|
17
17
|
Classifier: Programming Language :: Python
|
|
18
18
|
Classifier: Programming Language :: Python :: 3
|
|
19
19
|
Classifier: Programming Language :: Python :: 3 :: Only
|
|
20
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
21
20
|
Classifier: Programming Language :: Python :: 3.10
|
|
22
21
|
Classifier: Programming Language :: Python :: 3.11
|
|
23
22
|
Classifier: Programming Language :: Python :: 3.12
|
|
24
23
|
Classifier: Programming Language :: Python :: 3.13
|
|
25
24
|
Classifier: Programming Language :: Python :: 3.14
|
|
25
|
+
Classifier: Programming Language :: Python :: 3.15
|
|
26
26
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
27
|
+
Classifier: Programming Language :: Python :: Free Threading :: 3 - Stable
|
|
27
28
|
Classifier: Programming Language :: Objective C
|
|
28
29
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
29
30
|
Classifier: Topic :: Software Development :: User Interfaces
|
|
30
|
-
Requires-Python: >=3.
|
|
31
|
+
Requires-Python: >=3.10
|
|
31
32
|
Description-Content-Type: text/x-rst; charset=UTF-8
|
|
32
|
-
Requires-Dist: pyobjc-core>=
|
|
33
|
-
Requires-Dist: pyobjc-framework-Cocoa>=
|
|
33
|
+
Requires-Dist: pyobjc-core>=12.1
|
|
34
|
+
Requires-Dist: pyobjc-framework-Cocoa>=12.1
|
|
34
35
|
Dynamic: author
|
|
35
36
|
Dynamic: author-email
|
|
36
37
|
Dynamic: classifier
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
from PyObjCTools.TestSupport import TestCase, min_os_level
|
|
2
|
+
|
|
3
|
+
import xpc
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class TestListener(TestCase):
|
|
7
|
+
@min_os_level("14.4")
|
|
8
|
+
def test_functions(self):
|
|
9
|
+
self.assertArgHasType(
|
|
10
|
+
xpc.xpc_listener_set_peer_code_signing_requirement, 1, b"n^t"
|
|
11
|
+
)
|
|
12
|
+
self.assertArgIsNullTerminated(
|
|
13
|
+
xpc.xpc_listener_set_peer_code_signing_requirement, 1
|
|
14
|
+
)
|
|
15
|
+
|
|
16
|
+
@min_os_level("26.0")
|
|
17
|
+
def test_functions26_0(self):
|
|
18
|
+
xpc.xpc_listener_set_peer_requirement
|