runtc 473 B

1234567891011121314151617181920212223242526272829
  1. #!/usr/bin/env bash
  2. set -eu
  3. . common
  4. set -- ${cli_tc:-} "$@"
  5. while getopts a:gh OPT; do
  6. case "$OPT" in
  7. a)
  8. arch="$OPTARG"
  9. ;;
  10. g)
  11. gem5=true
  12. ;;
  13. h)
  14. printf "Usage: $0 TOOL [TOOL_ARGS]...
  15. Call a built ToolChain tool. Example:
  16. $0 -a arm readelf -h
  17. " 2>&1
  18. exit 0
  19. ;;
  20. esac
  21. done
  22. shift "$(($OPTIND - 1))"
  23. tool="$1"
  24. shift
  25. set_common_vars "$arch" "$gem5"
  26. "${buildroot_out_dir}/host/bin/"*-buildroot-*"${tool}" "$@"
  27. exit "$?"