-
Notifications
You must be signed in to change notification settings - Fork 16
/
Makefile
120 lines (84 loc) · 4.38 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
108
109
110
111
112
113
114
115
116
117
118
119
120
#------------------------------------------------------------------------------#
# This makefile was generated by 'cbp2make' tool rev.127 #
#------------------------------------------------------------------------------#
WORKDIR = `pwd`
PROJECT_DIRECTORY = ./
CC = gcc
CXX = g++
AR = ar
LD = g++
WINDRES = windres
CFLAGS = -std=c++11 -Wall `wx-config --cflags` -Winvalid-pch -include wx_pch.h `python-config --includes` `pkg-config --cflags glib-2.0` -DWX_PRECOMP `pkg-config --cflags libxml-2.0` `pkg-config --cflags libusb-1.0` -Iinclude
LIBDIR =
LDFLAGS = `wx-config --libs` -Winvalid-pch -include wx_pch.h `python-config --libs` `pkg-config --libs glib-2.0` `pkg-config --libs libxml-2.0` `pkg-config --libs openobex` `pkg-config --libs libudev` `pkg-config --libs libusb-1.0`
CFLAGS_DEBUG = $(CFLAGS) -O3 -g
RCFLAGS_DEBUG = $(RCFLAGS)
LIBDIR_DEBUG = $(LIBDIR)
LDFLAGS_DEBUG = $(LDFLAGS)
OBJDIR_DEBUG = ./obj/Debug
DEP_DEBUG =
OUT_DEBUG = ./bin/Debug/LibreScribe
CFLAGS_RELEASE = $(CFLAGS) -O3
RCFLAGS_RELEASE = $(RCFLAGS)
LIBDIR_RELEASE = $(LIBDIR)
LDFLAGS_RELEASE = -s $(LDFLAGS)
OBJDIR_RELEASE = ./obj/Release
DEP_RELEASE =
OUT_RELEASE = ./bin/Release/LibreScribe
OBJ_DEBUG = $(OBJDIR_DEBUG)/src/AboutDialog.o $(OBJDIR_DEBUG)/src/DeviceInfo.o $(OBJDIR_DEBUG)/src/GUIFrame.o $(OBJDIR_DEBUG)/src/LibreScribe.o $(OBJDIR_DEBUG)/src/BackgroundMonitor.o $(OBJDIR_DEBUG)/src/Smartpen.o
OBJ_RELEASE = $(OBJDIR_RELEASE)/src/AboutDialog.o $(OBJDIR_RELEASE)/src/DeviceInfo.o $(OBJDIR_RELEASE)/src/GUIFrame.o $(OBJDIR_RELEASE)/src/LibreScribe.o $(OBJDIR_RELEASE)/src/BackgroundMonitor.o $(OBJDIR_RELEASE)/src/Smartpen.o
all: before_build build_debug build_release after_build
clean: clean_debug clean_release
before_build:
after_build:
find ./bin/ -mindepth 1 -maxdepth 1 -type d | xargs -n 1 cp -rfv -L ./res
find ./bin/ -mindepth 1 -maxdepth 1 -type d | xargs -n 1 cp -fv -L ./stf.py ./convert_stfs.sh
before_debug:
mkdir -p ./bin/Debug
mkdir -p $(OBJDIR_DEBUG)/src
after_debug:
build_debug: before_debug out_debug after_debug
debug: before_build build_debug after_build
out_debug: $(OBJ_DEBUG) $(DEP_DEBUG)
$(LD) -o $(OUT_DEBUG) $(OBJ_DEBUG) $(LDFLAGS_DEBUG) $(LIBDIR_DEBUG)
$(OBJDIR_DEBUG)/src/AboutDialog.o: src/AboutDialog.cc
$(CC) -o $(OBJDIR_DEBUG)/src/AboutDialog.o $(CFLAGS_DEBUG) -c src/AboutDialog.cc
$(OBJDIR_DEBUG)/src/DeviceInfo.o: src/DeviceInfo.cc
$(CC) -o $(OBJDIR_DEBUG)/src/DeviceInfo.o $(CFLAGS_DEBUG) -c src/DeviceInfo.cc
$(OBJDIR_DEBUG)/src/GUIFrame.o: src/GUIFrame.cc
$(CC) -o $(OBJDIR_DEBUG)/src/GUIFrame.o $(CFLAGS_DEBUG) -c src/GUIFrame.cc
$(OBJDIR_DEBUG)/src/LibreScribe.o: src/LibreScribe.cc
$(CC) -o $(OBJDIR_DEBUG)/src/LibreScribe.o $(CFLAGS_DEBUG) -c src/LibreScribe.cc
$(OBJDIR_DEBUG)/src/BackgroundMonitor.o: src/BackgroundMonitor.cc
$(CC) -o $(OBJDIR_DEBUG)/src/BackgroundMonitor.o $(CFLAGS_DEBUG) -c src/BackgroundMonitor.cc
$(OBJDIR_DEBUG)/src/Smartpen.o: src/Smartpen.cc
$(CC) -o $(OBJDIR_DEBUG)/src/Smartpen.o $(CFLAGS_DEBUG) -c src/Smartpen.cc
clean_debug:
rm $(OBJ_DEBUG) $(OUT_DEBUG)
rm -r ./bin/Debug
rm -r $(OBJDIR_DEBUG)/src
before_release:
mkdir -p ./bin/Release
mkdir -p $(OBJDIR_RELEASE)/src
after_release:
build_release: before_release out_release after_release
release: before_build build_release after_build
out_release: $(OBJ_RELEASE) $(DEP_RELEASE)
$(LD) -o $(OUT_RELEASE) $(OBJ_RELEASE) $(LDFLAGS_RELEASE) $(LIBDIR_RELEASE)
$(OBJDIR_RELEASE)/src/AboutDialog.o: src/AboutDialog.cc
$(CC) -o $(OBJDIR_RELEASE)/src/AboutDialog.o $(CFLAGS_RELEASE) -c src/AboutDialog.cc
$(OBJDIR_RELEASE)/src/DeviceInfo.o: src/DeviceInfo.cc
$(CC) -o $(OBJDIR_RELEASE)/src/DeviceInfo.o $(CFLAGS_RELEASE) -c src/DeviceInfo.cc
$(OBJDIR_RELEASE)/src/GUIFrame.o: src/GUIFrame.cc
$(CC) -o $(OBJDIR_RELEASE)/src/GUIFrame.o $(CFLAGS_RELEASE) -c src/GUIFrame.cc
$(OBJDIR_RELEASE)/src/LibreScribe.o: src/LibreScribe.cc
$(CC) -o $(OBJDIR_RELEASE)/src/LibreScribe.o $(CFLAGS_RELEASE) -c src/LibreScribe.cc
$(OBJDIR_RELEASE)/src/BackgroundMonitor.o: src/BackgroundMonitor.cc
$(CC) -o $(OBJDIR_RELEASE)/src/BackgroundMonitor.o $(CFLAGS_RELEASE) -c src/BackgroundMonitor.cc
$(OBJDIR_RELEASE)/src/Smartpen.o: src/Smartpen.cc
$(CC) -o $(OBJDIR_RELEASE)/src/Smartpen.o $(CFLAGS_RELEASE) -c src/Smartpen.cc
clean_release:
rm $(OBJ_RELEASE) $(OUT_RELEASE)
rm -r ./bin/Release
rm -r $(OBJDIR_RELEASE)/src
.PHONY: before_build after_build before_debug after_debug clean_debug before_release after_release clean_release