remove -lgcrypt from netbsd Makefile
[xombrero.git] / Makefile
blobe552b18865cfb2e63ed39fbf0afa0b75d9bbf2e7
1 PREFIX?=/usr/local
2 BINDIR=${PREFIX}/bin
4 PROG=xombrero
5 MAN=xombrero.1
7 DEBUG= -g
9 SRCS= cookie.c inspector.c marco.c about.c whitelist.c settings.c inputfocus.c
10 SRCS+= history.c completion.c tldlist.c externaleditor.c unix.c xombrero.c
11 CFLAGS+= -O2 -Wall -Wno-format-extra-args -Wunused
12 CFLAGS+= -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wno-sign-compare -Wno-deprecated-declarations ${DEBUG}
13 CFLAGS+= -DGTK_DISABLE_SINGLE_INCLUDES -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED -DGSEAL_ENABLE
14 CFLAGS+= -I. -I${.CURDIR}
15 LDADD= -lutil
16 GTK_VERSION ?= gtk3
17 .if ${GTK_VERSION} == "gtk2"
18 LIBS+= gtk+-2.0
19 LIBS+= webkit-1.0
20 .else
21 LIBS+= gtk+-3.0
22 LIBS+= webkitgtk-3.0
23 .endif
24 LIBS+= libsoup-2.4
25 LIBS+= gnutls
26 GTK_CFLAGS!= pkg-config --cflags $(LIBS)
27 GTK_LDFLAGS!= pkg-config --libs $(LIBS)
28 CFLAGS+= $(GTK_CFLAGS)
29 LDFLAGS+= $(GTK_LDFLAGS)
30 BUILDVERSION != sh "${.CURDIR}/buildver.sh"
31 .if !${BUILDVERSION} == ""
32 CPPFLAGS+= -DXOMBRERO_BUILDSTR=\"$(BUILDVERSION)\"
33 .endif
35 MANDIR= ${PREFIX}/man/man
37 CLEANFILES += ${.CURDIR}/javascript.h javascript.h tooltip.h xombrero.cat1 xombrero.core
39 JSFILES += hinting.js
40 JSFILES += input-focus.js
41 JSFILES += autoscroll.js
43 .for _js in ${JSFILES}
44 JSCURDIR += ${.CURDIR}/${_js}
45 .endfor
47 javascript.h: ${JSFILES} js-merge-helper.pl
48 perl ${.CURDIR}/js-merge-helper.pl \
49 ${JSCURDIR} > javascript.h
51 tooltip.h: ${MAN} ascii2txt.pl txt2tooltip.pl
52 mandoc -Tascii ${.CURDIR}/${MAN} | \
53 perl ${.CURDIR}/ascii2txt.pl | \
54 perl ${.CURDIR}/txt2tooltip.pl > tooltip.h
56 beforeinstall:
57 install -m 755 -d ${PREFIX}/bin
58 install -m 755 -d ${PREFIX}/man/man1/
59 install -m 755 -d ${PREFIX}/share/xombrero
60 install -m 755 -d ${PREFIX}/share/applications
61 install -m 644 $(.CURDIR)/xombrero.css ${PREFIX}/share/xombrero
62 install -m 644 $(.CURDIR)/xombrero.desktop ${PREFIX}/share/applications
63 install -m 644 ${.CURDIR}/xombreroicon.png ${PREFIX}/share/xombrero
64 install -m 644 ${.CURDIR}/xombreroicon16.png ${PREFIX}/share/xombrero
65 install -m 644 ${.CURDIR}/xombreroicon32.png ${PREFIX}/share/xombrero
66 install -m 644 ${.CURDIR}/xombreroicon48.png ${PREFIX}/share/xombrero
67 install -m 644 ${.CURDIR}/xombreroicon64.png ${PREFIX}/share/xombrero
68 install -m 644 ${.CURDIR}/xombreroicon128.png ${PREFIX}/share/xombrero
69 install -m 644 ${.CURDIR}/tld-rules ${PREFIX}/share/xombrero
70 install -m 644 ${.CURDIR}/style.css ${PREFIX}/share/xombrero
71 install -m 644 ${.CURDIR}/hsts-preload ${PREFIX}/share/xombrero
72 install -m 644 ${.CURDIR}/user-agent-headers ${PREFIX}/share/xombrero
73 install -m 644 ${.CURDIR}/http-accept-headers ${PREFIX}/share/xombrero
74 install -m 644 ${.CURDIR}/torenabled.ico ${PREFIX}/share/xombrero
75 install -m 644 ${.CURDIR}/tordisabled.ico ${PREFIX}/share/xombrero
77 ${PROG} ${OBJS} beforedepend: javascript.h tooltip.h
79 .include <bsd.prog.mk>