https://bugs.gentoo.org/934482 https://github.com/wxWidgets/Phoenix/commit/6a049ccc0ad96f25c3f7d8540b218ffe8921d8c5 From 6a049ccc0ad96f25c3f7d8540b218ffe8921d8c5 Mon Sep 17 00:00:00 2001 From: Scott Talbert Date: Tue, 5 Dec 2023 23:42:21 -0500 Subject: [PATCH] Support building with Doxygen 1.9.7 Doxygen 1.9.7 made some changes whereby some method definitions are now defined in separate XML files, with a "refid" that links to them. In order to support this, we need to follow these "refids" to pick up the method definition from the separate group XML files. --- a/etgtools/extractors.py +++ b/etgtools/extractors.py @@ -62,6 +62,8 @@ def extract(self, element): # class. Should be overridden in derived classes to get what each one # needs in addition to the base. self.name = element.find(self.nameTag).text + if self.name is None: + self.name = '' if '::' in self.name: loc = self.name.rfind('::') self.name = self.name[loc+2:] @@ -1574,12 +1576,21 @@ def addElement(self, element): extractingMsg(kind, element) for node in element.findall('sectiondef/memberdef'): self.addElement(node) + for node in element.findall('sectiondef/member'): + node = self.resolveRefid(node) + self.addElement(node) else: raise ExtractorError('Unknown module item kind: %s' % kind) return item + def resolveRefid(self, node): + from etgtools import XMLSRC + refid = node.get('refid') + fname = os.path.join(XMLSRC, refid.rsplit('_', 1)[0]) + '.xml' + root = et.parse(fname).getroot() + return root.find(".//memberdef[@id='{}']".format(refid)) def addCppFunction(self, type, name, argsString, body, doc=None, **kw):