Skip to content

Instantly share code, notes, and snippets.

@paranlee
Created December 1, 2021 13:28
Show Gist options
  • Select an option

  • Save paranlee/dc8ded2a1f37400b5987755f161f826d to your computer and use it in GitHub Desktop.

Select an option

Save paranlee/dc8ded2a1f37400b5987755f161f826d to your computer and use it in GitHub Desktop.
Build a static executable this way
# Build a static executable this way :
$ gcc -fno-asynchronous-unwind-tables -fno-ident -s -Os -nostdlib \
-static -include nolibc.h -lgcc -o hello hello.c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment