3 # This script generate the rsbac_x_y_z.py Python module which contains
4 # all the types defined in RSBAC include file.
6 # You need at least GCC-XML 0.7 CVS and codegenerator from the ctypes
12 HEADERS=/path/to/rsbac-admin-1.3.0rc1/main/headers
14 "${HEADERS}/rsbac/types.h"
15 "${HEADERS}/rsbac/syscalls.h"
16 "${HEADERS}/rsbac/request_groups.h"
18 TARGET="./rsbac_1_3_0_rc1.py"
21 GCCXML=/path/to/gccxml
22 export PATH="${GCCXML}:${PATH}"
25 CODEGEN=/path/to/codegen
26 export PYTHONPATH="$CODEGEN"
27 H2XML="${CODEGEN}/scripts/h2xml.py"
28 XML2PY="${CODEGEN}/scripts/xml2py.py"
31 python "$H2XML" "${SOURCES[@]}" -I "$HEADERS" -c -o "$TMP"
33 # Automatically generated by $0 on `date`
36 python "$XML2PY" "$TMP"|grep -v '^Could not init' >> "$TARGET"