Compare commits

..
84 Commits
Author SHA1 Message Date
Ole André Vadla Ravnås 50ad5f65dd subprojects: Prepare for release 2026-11-02 22:10:40 +01:00
Ole André Vadla Ravnås 9a9ccbad64 subprojects: Bump outdated 2026-11-02 22:09:07 +01:00
Ole André Vadla Ravnås 35a37f395a subprojects: Prepare for release 2026-11-01 15:11:47 +01:00
Ole André Vadla Ravnås 135d9a2ac7 subprojects: Bump outdated 2026-11-01 15:10:35 +01:00
Ole André Vadla Ravnås 3b0570d829 subprojects: Bump outdated 2026-10-31 00:48:22 +01:00
Ole André Vadla Ravnås 95ede66f87 subprojects: Bump outdated 2026-10-30 23:13:01 +01:00
Ole André Vadla Ravnås 9c424b152d subprojects: Bump outdated 2026-10-30 21:59:16 +01:00
Ole André Vadla Ravnås 4d4d594f45 submodules: Bump releng 2026-10-30 21:59:16 +01:00
Ole André Vadla Ravnås 556c44df84 examples: Use frida-forks URL for dbus-next 2026-10-30 21:53:04 +01:00
Ole André Vadla Ravnås c686293400 subprojects: Prepare for release 2026-10-30 14:34:01 +01:00
Ole André Vadla Ravnås ee02bd8af2 subprojects: Bump outdated 2026-10-30 14:01:37 +01:00
Ole André Vadla Ravnås 5f224307bb bindgen: Narrow factory marshals for mypy 2026-10-30 13:03:31 +01:00
Ole André Vadla Ravnås 7357b0b5b4 Format with Black 26 2026-10-30 13:03:17 +01:00
Ole André Vadla Ravnås 2f2bb64f36 subprojects: Bump outdated 2026-10-30 07:08:42 +01:00
Ole André Vadla Ravnås 5a0894aaac subprojects: Bump outdated 2026-10-30 07:00:11 +01:00
Ole André Vadla Ravnås 0bcb9da6c5 submodules: Bump releng 2026-10-30 07:00:11 +01:00
Ole André Vadla Ravnås 2316a9f36d subprojects: Bump outdated 2026-10-29 23:02:21 +01:00
Ole André Vadla Ravnås 720d09bbbc subprojects: Bump outdated 2026-10-29 21:53:15 +01:00
Ole André Vadla Ravnås 1269168a06 subprojects: Bump outdated 2026-10-29 21:28:24 +01:00
Ole André Vadla Ravnås b6c8f04757 submodules: Bump releng 2026-10-29 21:28:24 +01:00
Ole André Vadla Ravnås a0213a48e4 subprojects: Bump outdated 2026-10-23 13:51:43 +02:00
Ole André Vadla Ravnås b978ae1cf0 submodules: Bump releng 2026-10-23 13:51:43 +02:00
Ole André Vadla Ravnås 8017678437 subprojects: Bump outdated 2026-10-20 21:57:18 +02:00
Ole André Vadla Ravnås caef01a609 subprojects: Bump outdated 2026-10-20 21:39:25 +02:00
Ole André Vadla Ravnås 688b5d5c4d submodules: Bump releng 2026-10-20 21:39:25 +02:00
Ole André Vadla Ravnås bd8ea3369b subprojects: Bump outdated 2026-10-20 21:33:27 +02:00
Ole André Vadla Ravnås 1ecf3cf2a6 subprojects: Bump outdated 2026-10-20 20:23:49 +02:00
Ole André Vadla Ravnås 58ca39d36d build: Sync wrappers with releng 2026-10-20 20:23:49 +02:00
Ole André Vadla Ravnås 79c0305e66 submodules: Bump releng 2026-10-20 20:23:49 +02:00
Ole André Vadla Ravnås c1464592c8 subprojects: Bump outdated 2026-10-20 14:26:04 +02:00
Ole André Vadla Ravnås 1b21ea127b submodules: Bump releng 2026-10-20 14:26:04 +02:00
Ole André Vadla Ravnås b43e681df3 subprojects: Prepare for release 2026-10-19 10:33:32 +02:00
Ole André Vadla Ravnås 15d2d930dc subprojects: Bump outdated 2026-10-19 10:30:59 +02:00
Ole André Vadla Ravnås 24bdbab9cb submodules: Bump releng 2026-10-19 10:30:59 +02:00
Ole André Vadla Ravnås d0267d9f38 subprojects: Prepare for release 2026-10-18 13:53:42 +02:00
Ole André Vadla Ravnås 922dbfad3e subprojects: Bump outdated 2026-10-18 13:52:22 +02:00
Ole André Vadla Ravnås 03cf741fe0 subprojects: Prepare for release 2026-10-17 12:54:33 +02:00
Ole André Vadla Ravnås fdcea1076a subprojects: Bump outdated 2026-10-17 12:53:48 +02:00
Ole André Vadla Ravnås 1e1bea3512 submodules: Bump releng 2026-10-17 12:53:48 +02:00
Ole André Vadla Ravnås 95cbbd197c subprojects: Prepare for release 2026-10-16 15:37:47 +02:00
Ole André Vadla Ravnås 9bc7087d74 subprojects: Bump outdated 2026-10-16 15:36:33 +02:00
Ole André Vadla Ravnås ffe970e655 subprojects: Bump outdated 2026-10-16 13:54:46 +02:00
Ole André Vadla Ravnås 7ce14f42fa subprojects: Bump outdated 2026-10-16 12:42:52 +02:00
Ole André Vadla Ravnås 14c8d33b37 submodules: Bump releng 2026-10-16 12:42:52 +02:00
Ole André Vadla Ravnås ff0f50f8a6 subprojects: Bump outdated 2026-10-15 18:18:18 +02:00
Ole André Vadla Ravnås 8b526bb25d subprojects: Bump outdated 2026-10-15 15:46:11 +02:00
Ole André Vadla Ravnås 7c422c233d submodules: Bump releng 2026-10-15 15:46:11 +02:00
Ole André Vadla Ravnås bd7e80c209 subprojects: Bump outdated 2026-10-15 15:14:38 +02:00
Ole André Vadla Ravnås f80a06d7ae submodules: Bump releng 2026-10-15 15:14:38 +02:00
Ole André Vadla Ravnås 82febc16ba subprojects: Prepare for release 2026-10-09 18:57:36 +02:00
Ole André Vadla Ravnås 76d3b504fe subprojects: Bump outdated 2026-10-09 18:56:41 +02:00
Ole André Vadla Ravnås 735d34d175 subprojects: Prepare for release 2026-10-09 14:19:26 +02:00
Ole André Vadla Ravnås a6feef0770 subprojects: Bump outdated 2026-10-09 14:16:52 +02:00
Ole André Vadla Ravnås 418c5e3f43 subprojects: Prepare for release 2026-10-08 14:49:02 +02:00
Ole André Vadla Ravnås a1929a4dc5 subprojects: Bump outdated 2026-10-08 14:32:45 +02:00
Ole André Vadla Ravnås aacd1913e0 subprojects: Prepare for release 2026-10-07 14:27:03 +02:00
Ole André Vadla Ravnås ea6c66da96 subprojects: Bump outdated 2026-10-07 14:24:00 +02:00
Ole André Vadla Ravnås 57b6cbae38 submodules: Bump releng 2026-10-07 14:24:00 +02:00
Ole André Vadla Ravnås 1b18f0174d subprojects: Prepare for release 2026-10-05 10:00:33 +02:00
Ole André Vadla Ravnås 7f04d40687 subprojects: Bump outdated 2026-10-05 09:57:11 +02:00
Ole André Vadla Ravnås c69db7eb40 submodules: Bump releng 2026-10-05 09:57:10 +02:00
Ole André Vadla Ravnås ce49a3102a subprojects: Prepare for release 2026-10-04 11:35:34 +02:00
Ole André Vadla Ravnås 288133374a subprojects: Bump outdated 2026-10-04 11:34:54 +02:00
Ole André Vadla Ravnås 56843bb3f8 subprojects: Prepare for release 2026-10-03 07:56:17 +02:00
Ole André Vadla Ravnås d90f991948 subprojects: Bump outdated 2026-10-03 07:55:28 +02:00
Ole André Vadla Ravnås c744c2a12a subprojects: Prepare for release 2026-10-02 20:28:27 +02:00
Ole André Vadla Ravnås 48631baafa subprojects: Bump outdated 2026-10-02 20:27:05 +02:00
Ole André Vadla Ravnås c711f8f040 subprojects: Prepare for release 2026-10-02 01:36:43 +02:00
Ole André Vadla Ravnås 049674da0a subprojects: Bump outdated 2026-10-02 01:32:18 +02:00
Ole André Vadla Ravnås e1c24e8187 bindgen: Marshal null variants as None 2026-10-01 18:24:45 +02:00
Ole André Vadla Ravnås 9947655e6a subprojects: Prepare for release 2026-09-25 13:15:47 +02:00
Ole André Vadla Ravnås e5b15dce63 subprojects: Bump outdated 2026-09-25 13:14:11 +02:00
Ole André Vadla Ravnås e846eb2815 subprojects: Bump outdated 2026-09-25 12:18:59 +02:00
Ole André Vadla Ravnås bc685fd8c1 subprojects: Bump outdated 2026-09-24 21:35:04 +02:00
Ole André Vadla Ravnås bcaa1a099e subprojects: Bump outdated 2026-09-23 00:02:59 +02:00
Ole André Vadla Ravnås 4e782ccbdf submodules: Bump releng 2026-09-23 00:02:58 +02:00
Ole André Vadla Ravnås 9823368745 subprojects: Bump outdated 2026-09-22 23:47:25 +02:00
Ole André Vadla Ravnås c6e5a8d4d9 submodules: Bump releng 2026-09-22 23:47:25 +02:00
Ole André Vadla Ravnås eb15035950 subprojects: Bump outdated 2026-09-22 21:04:23 +02:00
Ole André Vadla Ravnås ec509287e1 subprojects: Bump outdated 2026-09-22 15:57:26 +02:00
Ole André Vadla Ravnås 0c52c00bad submodules: Bump releng 2026-09-22 15:57:26 +02:00
Ole André Vadla Ravnås 8f31efacf2 Format with the current Black
Black has changed how it lays out a call whose argument is a
multiline string, and a `with` statement holding several contexts.
2026-09-17 19:01:25 +02:00
Ole André Vadla Ravnås 01fd680353 bindgen: Fix dropped constructors and out params
A static function that makes the class it sits on was not read at all,
so every named constructor in the API was missing. One that throws was
then missing twice over: skipped for __init__ because it throws, and
skipped as a factory for being the primary, leaving nothing to make
the class with.

An out parameter was dropped along with the value it carried, so a
`gboolean` method that answers through one now binds as Optional, and
any other out parameter is refused rather than bound as a result the
caller cannot read.
2026-09-17 18:54:58 +02:00
Ole André Vadla Ravnås 00e6231b89 subprojects: Bump outdated 2026-09-16 19:28:53 +02:00
10 changed files with 84 additions and 23 deletions

No files matched your search

+2 -2
View File
@@ -1,4 +1,4 @@
PYTHON ?= $(shell which python3 >/dev/null && echo python3 || echo python)
PYTHON ?= $(shell command -v python3 >/dev/null && echo python3 || echo python)
all $(MAKECMDGOALS):
@$(PYTHON) \
@@ -8,7 +8,7 @@ all $(MAKECMDGOALS):
$(MAKECMDGOALS)
git-submodules:
@if [ ! -f releng/meson/meson.py ] || [ ! -f frida-bindgen/frida_bindgen_core/model.py ]; then \
@if [ ! -f releng/meson/meson.py ] || git submodule status 2>/dev/null | grep -q '^-'; then \
git submodule update --init --recursive --depth 1; \
fi
-include git-submodules
Vendored
+2 -2
View File
@@ -1,12 +1,12 @@
#!/bin/sh
[ -z "$PYTHON" ] && PYTHON=$(which python3 >/dev/null && echo python3 || echo python)
[ -z "$PYTHON" ] && PYTHON=$(command -v python3 >/dev/null && echo python3 || echo python)
cd $(dirname $0)
srcroot=$(pwd)
if [ ! -f releng/meson/meson.py ]; then
if [ ! -f releng/meson/meson.py ] || git submodule status 2>/dev/null | grep -q '^-'; then
git submodule update --init --recursive --depth 1 || exit $?
fi
+4 -4
View File
@@ -9,7 +9,7 @@
"version": "1.0.0",
"dependencies": {
"core-js": "^3.6.5",
"dbus-next": "frida/node-dbus-next",
"dbus-next": "frida-forks/node-dbus-next",
"duplexify": "^4.1.1",
"vue": "^2.6.11",
"vue-class-component": "^7.2.3",
@@ -6509,7 +6509,7 @@
},
"node_modules/dbus-next": {
"version": "0.9.2",
"resolved": "git+ssh://[email protected]/frida/node-dbus-next.git#0e12559b2298c140916541f57fdf9f83cf0b7975",
"resolved": "git+ssh://[email protected]/frida-forks/node-dbus-next.git#0e12559b2298c140916541f57fdf9f83cf0b7975",
"license": "MIT",
"dependencies": {
"@nornagon/put": "0.0.8",
@@ -20437,8 +20437,8 @@
"peer": true
},
"dbus-next": {
"version": "git+ssh://[email protected]/frida/node-dbus-next.git#0e12559b2298c140916541f57fdf9f83cf0b7975",
"from": "dbus-next@frida/node-dbus-next",
"version": "git+ssh://[email protected]/frida-forks/node-dbus-next.git#0e12559b2298c140916541f57fdf9f83cf0b7975",
"from": "dbus-next@frida-forks/node-dbus-next",
"requires": {
"@nornagon/put": "0.0.8",
"abstract-socket": "^2.0.0",
+1 -1
View File
@@ -8,7 +8,7 @@
},
"dependencies": {
"core-js": "^3.6.5",
"dbus-next": "frida/node-dbus-next",
"dbus-next": "frida-forks/node-dbus-next",
"duplexify": "^4.1.1",
"vue": "^2.6.11",
"vue-class-component": "^7.2.3",
@@ -910,6 +910,9 @@ propagate_error:
static PyObject *
PyGObject_marshal_variant (GVariant * variant)
{
if (variant == NULL)
PyFrida_RETURN_NONE;
switch (g_variant_classify (variant))
{
case G_VARIANT_CLASS_STRING:
+61 -11
View File
@@ -436,7 +436,7 @@ def generate_aio_async_method(method: Method, model: Model) -> Optional[str]:
if method.return_value is not None:
call = wrap_result(call, method.return_value.type, model)
ret = "None" if method.return_value is None else pyi_type(method.return_value.type, model)
ret = facade_return_type(method, model)
return f""" async def {method.name}({signature}) -> {ret}:
return {call}"""
@@ -460,7 +460,7 @@ def generate_custom_facade_method(
body = textwrap.indent(logic.strip(), " " * 8)
keyword = "async def" if awaitable else "def"
ret = "None" if method.return_value is None else pyi_type(method.return_value.type, model)
ret = facade_return_type(method, model)
return f""" {keyword} {method.name}({signature}) -> {ret}:
{body}
@@ -667,7 +667,7 @@ def generate_py_sync_method(method: Method, model: Model) -> Optional[str]:
if method.return_value is not None:
call = wrap_result(call, method.return_value.type, model)
ret = "None" if method.return_value is None else pyi_type(method.return_value.type, model)
ret = facade_return_type(method, model)
return f""" def {method.name}({facade_signature(method, params)}) -> {ret}:
return {call}"""
@@ -703,7 +703,7 @@ def generate_py_async_method(method: Method, model: Model) -> Optional[str]:
if method.return_value is not None:
call = wrap_result(call, method.return_value.type, model)
ret = "None" if method.return_value is None else pyi_type(method.return_value.type, model)
ret = facade_return_type(method, model)
return f""" def {method.name}({signature}) -> {ret}:
return {call}"""
@@ -793,8 +793,8 @@ def generate_pyi_class(otype: ObjectType, model: Model) -> List[str]:
body = []
primary = primary_constructor(otype)
if primary is not None and not primary.throws:
primary = inline_constructor(otype)
if primary is not None:
params = pyi_parameters(primary.input_parameters, model)
if params is not None:
signature = ", ".join(["self"] + params)
@@ -869,7 +869,13 @@ def pyi_method(method: Method, model: Model) -> Optional[str]:
if params is None:
return None
signature = ", ".join(["self"] + params)
ret = "None" if method.return_value is None else pyi_type(method.return_value.type, model)
out = method.optional_out_parameter
if out is not None:
ret = f"Optional[{pyi_type(out.type, model)}]"
elif method.return_value is None:
ret = "None"
else:
ret = pyi_type(method.return_value.type, model)
return f" def {method.name}({signature}) -> {ret}: ..."
@@ -958,7 +964,9 @@ def generate_extension_c(model: Model) -> str:
code += generate_object_type_constructor(otype)
for ctor in factory_constructors(otype):
code += generate_factory_function(otype, ctor, build_constructor_marshals(ctor))
marshals = build_constructor_marshals(ctor)
assert marshals is not None
code += generate_factory_function(otype, ctor, marshals)
return code
@@ -1371,6 +1379,11 @@ def generate_method(otype: ObjectType, method: Method) -> Optional[Tuple[str, st
marshal = synchronous_method_return_marshal(method)
if marshal is None:
return None
out = method.optional_out_parameter
if out is not None:
marshal = build_return_marshal(out.type, method.object_type.model)
if marshal is None:
return None
params = []
for param in method.input_parameters:
sync_param = build_sync_param(param)
@@ -1714,14 +1727,17 @@ def generate_synchronous_method(otype: ObjectType, method: Method, marshal: str,
indent = " " * (len(otype.c_symbol_prefix) + len(method.name) + 3)
handle = f"({otype.c_type} *) PY_GOBJECT_HANDLE (self)"
returns_strv = method.return_value is not None and method.return_value.type.name == "utf8[]"
out = method.optional_out_parameter
call_arg_list = [handle] + [p.call_arg for p in params]
if returns_strv:
call_arg_list.append("&retval_length")
if out is not None:
call_arg_list.append(f"&{out.name}")
if method.throws:
call_arg_list.append("&error")
call = f"{method.c_identifier} ({', '.join(call_arg_list)})"
if not params and not method.throws and not returns_strv:
if not params and not method.throws and not returns_strv and out is None:
if method.return_value is None:
body = f" {call};\n\n PyFrida_RETURN_NONE;"
else:
@@ -1740,6 +1756,8 @@ static PyObject *
decls.append(" GError * error = NULL;")
if returns_strv:
decls.append(" gint retval_length;")
if out is not None:
decls.append(f" {out_parameter_storage_type(out)} {out.name};")
for p in params:
decls += [f" {line}" for line in p.decl.splitlines()]
@@ -1754,7 +1772,15 @@ static PyObject *
pre = "".join(f"\n {p.pre}\n" for p in params if p.pre)
if method.return_value is None:
if out is not None:
invocation = f" gboolean found = {call};"
success = (
" if (found)\n"
f" result = {marshal.format(value=out.name)};\n"
" else\n"
" {\n Py_IncRef (Py_None);\n result = Py_None;\n }"
)
elif method.return_value is None:
invocation = f" {call};"
success = " Py_IncRef (Py_None);\n result = Py_None;"
elif returns_strv:
@@ -1799,6 +1825,22 @@ static PyObject *
"""
def facade_return_type(method: Method, model: Model) -> str:
out = method.optional_out_parameter
if out is not None:
return f"Optional[{pyi_type(out.type, model)}]"
if method.return_value is None:
return "None"
return pyi_type(method.return_value.type, model)
def out_parameter_storage_type(param: Parameter) -> str:
"""What the caller declares: the out parameter's own type, less the pointer."""
c = param.type.c
assert c.endswith("*"), c
return c[:-1].strip()
def synchronous_method_return_marshal(method: Method) -> Optional[str]:
if method.is_async or method.is_property_accessor:
return None
@@ -2328,8 +2370,16 @@ def primary_constructor(otype: ObjectType) -> Optional[Procedure]:
return next((c for c in otype.constructors if c.name == "new"), otype.constructors[0])
def inline_constructor(otype: ObjectType) -> Optional[Procedure]:
"""The constructor __init__ takes; one that throws is reached as a factory instead."""
ctor = primary_constructor(otype)
if ctor is None or ctor.throws:
return None
return ctor
def factory_constructors(otype: ObjectType) -> List[Procedure]:
primary = primary_constructor(otype)
primary = inline_constructor(otype)
return [
ctor
for ctor in otype.constructors
+8
View File
@@ -17,6 +17,10 @@ class Model(core.Model):
class ObjectType(core.ObjectType):
@cached_property
def methods(self) -> List["Method"]:
return [m for m in super().methods if not m.out_parameters or m.optional_out_parameter is not None]
@cached_property
def py_name(self) -> str:
custom = self.customizations
@@ -277,6 +281,7 @@ def _make_class(
type_struct,
parent,
constructors,
functions,
methods,
properties,
signals,
@@ -291,6 +296,7 @@ def _make_class(
type_struct,
parent,
constructors,
functions,
methods,
properties,
signals,
@@ -307,6 +313,7 @@ def _make_interface(
type_struct,
parent,
constructors,
functions,
methods,
properties,
signals,
@@ -320,6 +327,7 @@ def _make_interface(
type_struct,
parent,
constructors,
functions,
methods,
properties,
signals,
+1 -1
Submodule releng updated: 963fe3826f...564352a3ea.
+1 -1
View File
@@ -1,6 +1,6 @@
[wrap-git]
url = https://github.com/frida/frida-core.git
revision = 17.18.0
revision = 17.25.2
depth = 1
[provide]