]> Pileus Git - ~andy/sfvlug/blob - c/src/cc.sh
Add C notes.
[~andy/sfvlug] / c / src / cc.sh
1 #!/bin/bash
2
3 # Simplest complie 
4 cc hello.c
5 ./a.out
6
7 # Standard CC compile
8 gcc --std=c99 -Wall -o hello hello.c
9 ./hello
10
11 # Bulding object files
12 gcc -c -o hello.o hello.c
13 gcc -o hello hello.o -lm
14 ./hello
15
16 # Building with make
17 make hello
18 ./hello