commit | 40731afa5f0e4e0e9bc36bd9c37e24b9bdaa3413 | [log] [tgz] |
---|---|---|
author | Timur Iskhakov <iskhakovt@google.com> | Thu Aug 24 14:18:35 2017 -0700 |
committer | Timur Iskhakov <iskhakovt@google.com> | Tue Aug 29 17:16:57 2017 -0700 |
tree | e7d05aaf700f9c5bdd7499f75c73f8772f04bddf | |
parent | 9e7ff3698b2162131d3a253faac2b677bd92e371 [diff] |
Add acyclic check pass to hidl-gen Adds recursive tree pass that checks that directed graph of definitions and references is acyclic. It prints nice error message, which shows the whole found cycle. To be really tested, it requires lookups to be moved outside of parsing. Test: hidl_test Bug: 31827278 Change-Id: I9e96fa8206cfb84a56298991c526f71befae1478
croot make hidl-gen
hidl-gen -o output-path -L language (-r interface-root) fqname output-path: directory to store the output files. language: output file for given language. e.g.c++, vts.. fqname: fully qualified name of the input files. For singe file input, follow the format: package@version::fileName For directory input, follow the format: package@version interface-root(optional): prefix and root path for fqname. If not set, use the default prefix: android.hardware and default root path defined in $TOP. examples: croot hidl-gen -o output -L c++ -r android.hardware:hardware/interfaces -r android.hidl:system/libhidl/transport android.hardware.nfc@1.0::INfc.hal hidl-gen -o output -L vts -r android.hardware:hardware/interfaces -r android.hidl:system/libhidl/transport android.hardware.nfc@1.0 hidl-gen -o test -L c++ -r android.hardware:hardware/interfaces -r android.hidl:system/libhidl/transport android.hardware.nfc@1.0 hidl-gen -L hash -r android.hardware:hardware/interfaces -r android.hidl:system/libhidl/transport android.hardware.nfc@1.0