mirror of
https://gitlab.freedesktop.org/xorg/lib/libxcb-errors.git
synced 2026-01-06 22:30:17 +01:00
extensions.py: move globbing into python script
This will be helpful for Meson, which doesn't do globing in it's DSL
This commit is contained in:
parent
c4c32acbae
commit
7893efb241
2 changed files with 4 additions and 4 deletions
|
|
@ -37,5 +37,5 @@ tests_test_LDADD = libxcb-errors.la $(XCB_LIBS)
|
|||
CLEANFILES = src/extensions.c
|
||||
|
||||
src/extensions.c: src/extensions.py
|
||||
$(AM_V_GEN)$(PYTHON) $(srcdir)/src/extensions.py $@.tmp ${XCBPROTO_XCBINCLUDEDIR}/*.xml && \
|
||||
$(AM_V_GEN)$(PYTHON) $(srcdir)/src/extensions.py $@.tmp ${XCBPROTO_XCBINCLUDEDIR} && \
|
||||
mv $@.tmp $@
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
#!/usr/bin/env python
|
||||
import argparse
|
||||
import sys
|
||||
import glob
|
||||
from xml.etree.cElementTree import parse
|
||||
|
||||
class Module(object):
|
||||
|
|
@ -114,11 +114,11 @@ def main():
|
|||
# Parse the xml file
|
||||
parser = argparse.ArgumentParser()
|
||||
parser.add_argument('output')
|
||||
parser.add_argument('inputs', nargs='+')
|
||||
parser.add_argument('xml_dir')
|
||||
args = parser.parse_args()
|
||||
|
||||
modules = []
|
||||
for input_file in args.inputs:
|
||||
for input_file in glob.glob(args.xml_dir + '/*.xml'):
|
||||
parseFile(input_file, modules)
|
||||
|
||||
assert xproto != None
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue