blob: 7f86a416586cae42bd456e525650352d5533bd9e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
AR = ar
CC = gcc
LD = gcc
ARFLAGS = -cru
CFLAGS = -Wall -Wextra -Wundef -Wpointer-arith -Wcast-align \
-Wwrite-strings -Wstrict-prototypes \
-Wnested-externs -Werror -pedantic -std=c99 \
-Wno-format-zero-length -Wformat-security -Wstrict-aliasing=2 \
-Wmissing-format-attribute -Wunused -Wunreachable-code \
-Wformat=2 -Werror-implicit-function-declaration
LDFLAGS = -L./
#-Wmissing-declarations -Wmissing-prototypes
example: librosprite.a example.o
${LD} -g -o $@ example.o ${LDFLAGS} -lrosprite -lSDL
palette2c: librosprite.a palette2c.o
${LD} -g -o $@ palette2c.o ${LDFLAGS} -lrosprite
librosprite.a: librosprite.o
${AR} ${ARFLAGS} librosprite.a librosprite.o
%.o: %.c
${CC} -c -g ${CFLAGS} -o $@ $<
clean:
rm -f $(wildcard *.o) $(wildcard *.a) example palette
|