-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
108 lines (77 loc) · 2.15 KB
/
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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
#############################################################################
# Makefile for building: ircbot
# Generated by qmake (2.01a) (Qt 4.7.0) on: Fri May 13 15:33:36 2011
# Project: ircbot.pro
# Template: app
# Command: /usr/bin/qmake -o Makefile ircbot.pro
#############################################################################
####### Compiler, tools and options
CC = gcc
CXX = g++
CFLAGS = -pipe -O2 -Wall -W -D_REENTRANT $(DEFINES) -g
CXXFLAGS = -pipe -O2 -Wall -W -D_REENTRANT $(DEFINES) -g
LINK = g++
LFLAGS = -Wl,-O1 -g
LIBS = $(SUBLIBS) -L/usr/lib -lpthread
AR = ar cqs
RANLIB =
TAR = tar -cf
COMPRESS = gzip -9f
COPY = cp -f
SED = sed
COPY_FILE = $(COPY)
COPY_DIR = $(COPY) -r
STRIP = strip
INSTALL_FILE = install -m 644 -p
INSTALL_DIR = $(COPY_DIR)
INSTALL_PROGRAM = install -m 755 -p
DEL_FILE = rm -f
SYMLINK = ln -f -s
DEL_DIR = rmdir
MOVE = mv -f
CHK_DIR_EXISTS= test -d
MKDIR = mkdir -p
####### Output directory
OBJECTS_DIR = ./
####### Files
SOURCES = $(shell ls *.cpp)
OBJECTS = $(SOURCES:%.cpp=%.o)
DESTDIR =
TARGET = ircbot
first: all
####### Implicit rules
.SUFFIXES: .o .c .cpp .cc .cxx .C
.cpp.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.cc.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.cxx.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.C.o:
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
.c.o:
$(CC) -c $(CFLAGS) $(INCPATH) -o "$@" "$<"
####### Build rules
all: $(TARGET)
$(TARGET): $(OBJECTS)
$(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)
clean:
-$(DEL_FILE) $(OBJECTS)
-$(DEL_FILE) *~ core *.core
####### Sub-libraries
distclean: clean
-$(DEL_FILE) $(TARGET)
-$(DEL_FILE) Makefile
check: first
####### Compile
%.o: %.c %.h
$(CXX) -c $(CXXFLAGS) -o $@ $<
ircbot.o: ircbot.cpp ircbot.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o ircbot.o ircbot.cpp
main.o: main.cpp main.h \
ircbot.h
$(CXX) -c $(CXXFLAGS) $(INCPATH) -o main.o main.cpp
####### Install
install: FORCE
uninstall: FORCE
FORCE: