-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
47 lines (32 loc) · 912 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
BINARY := ./build/TesseractTranslator
OBJS := ConfigView.o \
TesseractTranslator.o \
TesseractLanguages.o \
TesseractApp.o \
shared/TranslatorSettings.o \
shared/TranslatorWindow.o \
shared/BaseTranslator.o \
shared/StreamBuffer.o
OBJDIR := build
RSRCS := ./res/TesseractTranslator.rsrc
OBJS := $(addprefix $(OBJDIR)/,$(OBJS))
CC := g++
LD := $(CC)
LIBS := -lbe -ltranslation -lroot -lstdc++ -ltesseract -lnetwork
CFLAGS := -O3 -I./ -I./src/shared
LDFLAGS :=
.PHONY : clean build install
default : build
build : $(BINARY)
$(BINARY) : $(OBJDIR) $(OBJS) $(RSRCS)
$(LD) $(CFLAGS) $(OBJS) -o $(BINARY) $(LDFLAGS) $(LIBS)
xres -o $(BINARY) $(RSRCS)
mimeset -f $(BINARY)
clean:
rm -rf $(OBJDIR)
build/%.o : src/%.cpp
@mkdir -p $(OBJDIR)/shared
$(CC) $(CFLAGS) -c $< -o $@
install:
mkdir -p /boot/home/config/add-ons/Translators
cp $(BINARY) /boot/home/config/add-ons/Translators