-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
35 lines (23 loc) · 945 Bytes
/
Makefile
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
28
29
30
31
32
33
CFLAGS = -Wall -O2 -std=gnu99
CC = gcc
all: lpc2k_pgm
OBJS = lpc2k_pgm.o gui.o settings.o download.o uuencode.o ihex.o serial.o chipinfo.o boot_2xxx.o boot_23xx.o
lpc2k_pgm: $(OBJS)
$(CC) -o lpc2k_pgm $(OBJS) `pkg-config --libs gtk+-2.0`
strip lpc2k_pgm
chipinfo.o: boot_2xxx.h boot_23xx.h
static: $(OBJS) mkstaticlist
$(CC) -o lpc2k_pgm $(OBJS) `./mkstaticlist`
strip lpc2k_pgm
cksum_test: cksum_test.c uuencode.o cksum_test.o
$(CC) $(CFLAGS) -o cksum_test cksum_test.o uuencode.o
boot_2xxx.c boot_2xxx.h: boot_2xxx.armasm mkbootc
arm-elf-as -o boot_2xxx.armobj boot_2xxx.armasm
arm-elf-objdump -d boot_2xxx.armobj | ./mkbootc boot_2xxx
boot_23xx.c boot_23xx.h: boot_23xx.armasm mkbootc
arm-elf-as -o boot_23xx.armobj boot_23xx.armasm
arm-elf-objdump -d boot_23xx.armobj | ./mkbootc boot_23xx
clean:
rm -f lpc2k_pgm cksum_test *.o core core.* *.armobj
gui.o: gui.c
$(CC) $(CFLAGS) `pkg-config --cflags gtk+-2.0` -c gui.c