git: e4e52cc16aad - main - audio/aubio: fix build with python 3.12
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 29 Jun 2026 20:19:47 UTC
The branch main has been updated by cmt:
URL: https://cgit.FreeBSD.org/ports/commit/?id=e4e52cc16aad4382d602db04f1f8aca981d28a2e
commit e4e52cc16aad4382d602db04f1f8aca981d28a2e
Author: Christoph Moench-Tegeder <cmt@FreeBSD.org>
AuthorDate: 2026-06-29 20:16:38 +0000
Commit: Christoph Moench-Tegeder <cmt@FreeBSD.org>
CommitDate: 2026-06-29 20:16:38 +0000
audio/aubio: fix build with python 3.12
The old waf build system relies on python module imp, which was removed
in python 3.12. This workaround is lifted directly from current waflib,
and allows aubio to build with recent python versions.
---
audio/aubio/files/patch-waflib_Context.py | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
diff --git a/audio/aubio/files/patch-waflib_Context.py b/audio/aubio/files/patch-waflib_Context.py
new file mode 100644
index 000000000000..39e5a2715564
--- /dev/null
+++ b/audio/aubio/files/patch-waflib_Context.py
@@ -0,0 +1,21 @@
+--- waflib/Context.py.orig 2026-06-27 09:53:00.227806000 +0200
++++ waflib/Context.py 2026-06-27 09:53:18.691344000 +0200
+@@ -2,9 +2,17 @@
+ # encoding: utf-8
+ # WARNING! Do not edit! https://waf.io/book/index.html#_obtaining_the_waf_file
+
+-import os,re,imp,sys
++import os,re,sys
+ from waflib import Utils,Errors,Logs
+ import waflib.Node
++
++if sys.hexversion > 0x3040000:
++ import types
++ class imp(object):
++ new_module = lambda x: types.ModuleType(x)
++else:
++ import imp
++
+ HEXVERSION=0x2000e00
+ WAFVERSION="2.0.14"
+ WAFREVISION="907519cab9c1c8c7e4f7d4e468ed6200b9250d58"