python3Packages.sigrok: fix build with swig 4.4

This commit is contained in:
Harinn
2026-05-23 19:48:25 +07:00
parent 2bb5ecd583
commit 452f7ac753
@@ -25,6 +25,14 @@ toPythonModule (
./python-install.patch
];
postPatch = ''
${orig.postPatch or ""}
# %init block lands in SWIG_mod_exec (returns int) under swig >= 4.4.
substituteInPlace bindings/python/sigrok/core/classes.i \
--replace-fail 'return nullptr;' 'return -1;'
'';
nativeBuildInputs =
orig.nativeBuildInputs or [ ]
++ [