Created
April 16, 2024 08:10
-
-
Save Inndy/d68d648262b7f2d2d07f7b657090b9a9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
f="$1" | |
if [ -z "$f" ] | |
then | |
echo "Usage: $0 elf-to-fix" | |
exit 1 | |
fi | |
if [ -n "$f" -a ! -f "$f" ] | |
then | |
f=$(which "$f") | |
fi | |
f=$(realpath "$f") | |
perm=$(stat -c %a "$f") | |
chmod +w "$f" | |
strip --remove-section=.note.ABI-tag "$f" | |
chmod $perm "$f" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment