-
Notifications
You must be signed in to change notification settings - Fork 46
/
makefile
49 lines (33 loc) · 996 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
CCFLAGS=-g -DMAIN
SOURCE=ints2bytes.c checksum.c
all: ints2bytes checksum
test: checksum create_input
./checksum < 156.bytes
./checksum < 229.bytes
./checksum < 81.bytes
create_input: ints2bytes
./ints2bytes < 156.txt > 156.bytes
./ints2bytes < 229.txt > 229.bytes
./ints2bytes < 81.txt > 81.bytes
display_input:
od -t u1 156.bytes
od -t u1 229.bytes
od -t u1 81.bytes
ints2bytes: ints2bytes.c
checksum: checksum.o
checksum.o: checksum.c
$(CC) -o checksum.o -c $(CCFLAGS) checksum.c
checksum.i: checksum.c
$(CC) -o checksum.i -E checksum.c
checksum.s: checksum.c
$(CC) -o checksum.s -S checksum.c
checksum.x86: tube.s
ln -s cheksum.x86 checksum.s checksum.x86
checksum.mips: checksum.o
echo "Go to the website: http://reliant.colab.duke.edu/c2mips/"
echo "enter the file checksum.c"
touch checksum.mips
clean:
rm -f ints2bytes *.bytes
rm -f checksum checksum.o checksum.i checksum.s checksum.x86
rm -f *~ \#*