diff options
author | Alex Auvolat <alex@adnab.me> | 2022-08-29 20:56:02 +0200 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2022-08-29 20:56:02 +0200 |
commit | e8a52192d043e56476bd5dc04fd6985b57f5cbe4 (patch) | |
tree | edf56bc5f4bcd2bdb04ad6a7902c99f7608b0bb2 /script/not-dynamic.sh | |
parent | 8394f32d16b846c5d1d66dd7505e4963062a7aec (diff) | |
download | garage-e8a52192d043e56476bd5dc04fd6985b57f5cbe4.tar.gz garage-e8a52192d043e56476bd5dc04fd6985b57f5cbe4.zip |
Add missing not-dynamic scriptv0.7.3-beta2v0.7.3dev0.7.3
Diffstat (limited to 'script/not-dynamic.sh')
-rwxr-xr-x | script/not-dynamic.sh | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/script/not-dynamic.sh b/script/not-dynamic.sh new file mode 100755 index 00000000..b9a13070 --- /dev/null +++ b/script/not-dynamic.sh @@ -0,0 +1,14 @@ +#!/usr/bin/env bash + +set -e + +if [ "$#" -ne 1 ]; then + echo "[fail] usage: $0 binary" + exit 2 +fi + +if file $1 | grep 'dynamically linked' 2>&1; then + echo "[fail] $1 is dynamic" + exit 1 +fi +echo "[ok] $1 is probably static" |