apply case sensitivity setting to history as well
[vimprobable2.git] / Makefile
blob12b29ed2008cab0f854b2cbd62071a07335ccee3
1 TARGET = vimprobable2
3 # Objectfiles, needed for $(TARGET)
4 OBJ = main.o utilities.o callbacks.o
5 # Manpages
6 MAN = vimprobable2.1 vimprobablerc.1
7 # Used libraries to get needed CFLAGS and LDFLAGS form pkg-config
8 LIBS = gtk+-2.0 webkit-1.0 libsoup-2.4
9 # Files to removo by clean target
10 CLEAN = $(TARGET) $(OBJ) $(DEPS) javascript.h
11 # Files to install by install target or remove by uninstall target
12 INSTALL = $(BINDIR)/$(TARGET) $(addprefix $(MANDIR)/man1/,$(MAN))
14 CFLAGS += `pkg-config --cflags $(LIBS)`
15 LDFLAGS += `pkg-config --libs $(LIBS)`
17 PREFIX ?= /usr/local
18 BINDIR ?= $(PREFIX)/bin
19 MANDIR ?= $(PREFIX)/share/man
20 # Mode bits for normal not executable files
21 FMOD ?= 0644
22 # Mode bits for directories
23 DMOD ?= 0755
24 # Mode bits for executables
25 EXECMOD ?= 0755
26 # Destination directory to install files
27 DESTDIR ?= /
29 # auto garerated dependancies for object files
30 DEPS = $(OBJ:%.o=%.d)
32 all: $(TARGET)
34 -include $(DEPS)
36 main.o: javascript.h
37 javascript.h: input-focus.js hinting.js
38 perl ./js-merge-helper.pl
40 $(TARGET): $(OBJ)
41 $(CC) $^ $(LDFLAGS) -o $@
43 .PHONY: clean install uninstall
44 clean:
45 -rm -f $(CLEAN)
46 install: $(addprefix $(DESTDIR)/,$(INSTALL))
47 uninstall:
48 rm -f $(INSTALL)
50 # pattern rule to inslall executabels
51 $(DESTDIR)/$(BINDIR)/%: ./%
52 -[ -e '$(@D)' ] || mkdir -p '$(@D)' && chmod $(DMOD) '$(@D)'
53 cp -f '$<' '$@'
54 -strip -s '$@'
55 chmod $(EXECMOD) '$@'
57 # pattern rule to install manpages
58 $(DESTDIR)/$(MANDIR)/man1/%: ./%
59 -[ -e '$(@D)' ] || mkdir -p '$(@D)' && chmod $(DMOD) '$(@D)'
60 cp -f '$<' '$@'
61 chmod $(FMOD) '$@'
63 %.o: %.c
64 $(CC) -MMD -c $(CFLAGS) $< -o $@