X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=extras%2Fgen-babeltrace-h.py;fp=extras%2Fgen-babeltrace-h.py;h=75d328febbf85af36c92f0fc63b26ce9303834fc;hp=7c64a676e2220d5366ad63ab2d11cb6a34cdb89c;hb=d24d56638469189904fb6ddbb3c725817b3e9417;hpb=15caa1ca4fac30bd196602bd136e48fda3892de2 diff --git a/extras/gen-babeltrace-h.py b/extras/gen-babeltrace-h.py index 7c64a676..75d328fe 100644 --- a/extras/gen-babeltrace-h.py +++ b/extras/gen-babeltrace-h.py @@ -45,14 +45,22 @@ def _c_includes_from_sections(sections): src = '' for section in sections: + # CTF writer is not part of the Babeltrace library if 'ctf' in section.title.lower(): continue src += '/* {} */\n'.format(section.title) + lines = [] for filename in sorted(section.filenames): - src += '#include <{}>\n'.format(filename) + # not part of the API + if 'func-status' in filename: + continue + lines.append('#include <{}>\n'.format(filename)) + + lines.sort() + src += ''.join(lines) src += '\n' return src[:-1] @@ -92,5 +100,6 @@ def _main(): print(_c_includes_from_sections(sections)) print('#endif /* BABELTRACE_BABELTRACE_H */') + if __name__ == '__main__': _main()