Install bpf-sdk if none exists (#58)
This commit is contained in:
parent
af8b4b17e6
commit
921f88f582
19
do.sh
19
do.sh
|
@ -106,8 +106,8 @@ perform_action() {
|
||||||
>>"${dump}-mangled.txt"
|
>>"${dump}-mangled.txt"
|
||||||
sed \
|
sed \
|
||||||
s/://g \
|
s/://g \
|
||||||
< "${dump}-mangled.txt" \
|
<"${dump}-mangled.txt" |
|
||||||
| rustfilt \
|
rustfilt \
|
||||||
> "${dump}.txt"
|
> "${dump}.txt"
|
||||||
else
|
else
|
||||||
echo "Warning: No dump created, cannot find: $so"
|
echo "Warning: No dump created, cannot find: $so"
|
||||||
|
@ -127,21 +127,24 @@ perform_action() {
|
||||||
}
|
}
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
if [[ "$#" -ne 2 ]]; then
|
|
||||||
if [[ $1 == "update" ]]; then
|
if [[ $1 == "update" ]]; then
|
||||||
perform_action "$1"
|
perform_action "$1"
|
||||||
else
|
else
|
||||||
# Build all projects
|
if [[ ! -d "$sdkDir" ]]; then
|
||||||
|
./do.sh update
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$#" -ne 2 ]]; then
|
||||||
|
# Perform operation on all projects
|
||||||
for project in */; do
|
for project in */; do
|
||||||
if [[ -f "$project"Cargo.toml ]]; then
|
if [[ -f "$project"Cargo.toml ]]; then
|
||||||
perform_action "$1" "$PWD/$project" "$project"
|
perform_action "$1" "$PWD/$project" "$project"
|
||||||
else
|
else
|
||||||
continue;
|
continue
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
fi
|
|
||||||
else
|
else
|
||||||
# Build requested project
|
# Perform operation on requested project
|
||||||
perform_action "$1" "$PWD/$2" "$2"
|
perform_action "$1" "$PWD/$2" "$2"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue