-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
46 lines (31 loc) · 1.02 KB
/
Copy pathmakefile
File metadata and controls
46 lines (31 loc) · 1.02 KB
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
CFLAGS = -g -Wall -DSUN
# CFLAGS = -g -Wall -DDEC
CC = g++
CCF = $(CC) $(CFLAGS)
H = .
C_DIR = .
INCDIR = -I$(H)
LIBDIRS = -L$(C_DIR)
LIBS = -lclientReplFs
CLIENT_OBJECTS = client.o clientInstance.o network.o
SERVER_OBJECTS = serverInstance.o network.o
all: appl replFsServer
network.o: network.cpp network.h
$(CCF) -c $(INCDIR) network.cpp
appl: appl.o $(C_DIR)/libclientReplFs.a
$(CCF) -o appl appl.o $(LIBDIRS) $(LIBS)
appl.o: appl.c client.h appl.h
$(CCF) -c $(INCDIR) appl.c
$(C_DIR)/libclientReplFs.a: $(CLIENT_OBJECTS)
ar cr libclientReplFs.a $(CLIENT_OBJECTS)
ranlib libclientReplFs.a
client.o: client.c client.h clientInstance.h network.h
$(CCF) -c $(INCDIR) client.c
clientInstance.o: clientInstance.cpp clientInstance.h network.h
$(CCF) -c $(INCDIR) clientInstance.cpp
replFsServer: $(SERVER_OBJECTS)
$(CCF) -o replFsServer $(SERVER_OBJECTS) $(LIBDIRS) $(LIBS)
serverInstance.o: serverInstance.cpp serverInstance.h network.h
$(CCF) -c $(INCDIR) serverInstance.cpp
clean:
rm -f appl replFsServer *.o *.a