mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-27 12:04:27 +01:00
tc: create helper to access toolchain tools
This commit is contained in:
28
runtc
Executable file
28
runtc
Executable file
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env bash
|
||||
set -eu
|
||||
. common
|
||||
set -- ${cli_tc:-} "$@"
|
||||
while getopts a:gh OPT; do
|
||||
case "$OPT" in
|
||||
a)
|
||||
arch="$OPTARG"
|
||||
;;
|
||||
g)
|
||||
gem5=true
|
||||
;;
|
||||
h)
|
||||
printf "Usage: $0 TOOL [TOOL_ARGS]...
|
||||
Call a built ToolChain tool. Example:
|
||||
|
||||
$0 -a arm readelf -h
|
||||
" 2>&1
|
||||
exit 0
|
||||
;;
|
||||
esac
|
||||
done
|
||||
shift "$(($OPTIND - 1))"
|
||||
tool="$1"
|
||||
shift
|
||||
set_common_vars "$arch" "$gem5"
|
||||
"${buildroot_out_dir}/host/bin/"*-buildroot-*"${tool}" "$@"
|
||||
exit "$?"
|
||||
Reference in New Issue
Block a user