gcc compile multi thread code example Example: gcc compile multi thread gcc thread1.c -o thread1 -lpthread