tkurbad-overlay/sci-electronics/kicad/files/kicad-5.1.2-swig-4.0.0.patch

15 lines
706 B
Diff
Raw Normal View History

2019-07-15 12:27:43 +02:00
diff --git a/scripting/build_tools/fix_swig_imports.py b/scripting/build_tools/fix_swig_imports.py
index 160d7e2d9..4f97df079 100644
--- a/scripting/build_tools/fix_swig_imports.py
+++ b/scripting/build_tools/fix_swig_imports.py
@@ -40,6 +40,9 @@ if (len(lines)<4000):
txt = b""
for l in lines:
+ if l.startswith(b"if _swig_python_version_info < (2, 7, 0):"): # ok with swig version >= 4.0.0
+ l = l.replace(b"_swig_python_version_info < (2, 7, 0)", b"False")
+ doneOk = True
if l.startswith(b"if _swig_python_version_info >= (2, 7, 0):"): # ok with swig version >= 3.0.10
l = l.replace(b"_swig_python_version_info >= (2, 7, 0)", b"False")
doneOk = True