forked from RickyNgo/Terminal-Chat
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
28 lines (22 loc) · 923 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
CXX=g++
CFLAGS=-std=c++11
LDFLAGS=-lncurses
LDFLAGS+=-lboost_system
LDFLAGS+=-lpthread
LDFLAGS+=-lboost_thread
LayoutSrc=layout.cpp
ClientSrc=aux_functions.cpp client.cpp db_helper.cpp unified_main.cpp channel.cpp
MessageSrc=messages.cpp
ServerSrc=participant.cpp channel.cpp connection.cpp daemon.cpp guest.cpp processor.cpp server.cpp session.cpp
LayoutDir=Ncurses/
ClientDir=Client/
MessageDir=Messages/
ServerDir=Server/
LayoutPath=$(addprefix $(LayoutDir),$(LayoutSrc))
ClientPath=$(addprefix $(ClientDir),$(ClientSrc))
MessagePath=$(addprefix $(MessageDir),$(MessageSrc))
ServerPath=$(addprefix $(ServerDir),$(ServerSrc))
enki_client: $(ClientPath) $(MessagePath) $(LayoutPath)
$(CXX) $(CFLAGS) $(ClientPath) $(MessagePath) $(LayoutPath) -o enki_client $(LDFLAGS)
enki_server: $(ServerPath) $(MessagePath)
$(CXX) $(CFLAGS) $(ServerPath) $(MessagePath) -o enki_server $(LDFLAGS)