Created
May 9, 2024 20:30
-
-
Save xmarnic/ac05d066c76de45fc252d6ec4a515093 to your computer and use it in GitHub Desktop.
An attempt at fixing the VBox Guest additions addons error for Ubuntu Server 24.04 LTS
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
#!/usr/bin/bash | |
declare -a args | |
for var; do | |
if [ $var = '/tmp/vbox.0/VBoxGuest-common.c' ]; | |
then | |
sed -i -e 's/strlcpy/strscpy/g' $var | |
fi | |
if [ $var = '/tmp/vbox.0/VBoxGuest-linux.c' ]; | |
then | |
sed -i -e 's/strlcpy/strscpy/g' $var | |
fi | |
if [ $var = '/tmp/vbox.0/vfsmod.c' ]; | |
then | |
sed -i -e 's/strlcpy/strscpy/g' $var | |
fi | |
args[${#args[@]}]="$var" | |
done | |
/usr/bin/gcc-13x "${args[@]}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment