summaryrefslogtreecommitdiffstats
path: root/config.mk
blob: b7f4032ee816b956dcac105ebf9a857ac132e821 (plain) (blame)
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
VERSION = `git describe --tags --abbrev=0`

PKG_CONFIG = pkg-config

# paths
PREFIX = /usr/local
MANDIR = $(PREFIX)/share/man

GIT =
GITLIB =
# comment to disable git support
GIT = -DGIT
GITLIB = libgit2

ERR =
# uncomment to enable errors
# ERR = -DERR

EXPLAIN =
# comment to disable explinations
EXPLAIN = -DEXPLAIN

# add compilation details to VERSION variable
ifneq ($(GIT),)
	VERSION := $(VERSION)"\\nlibgit2 "`$(PKG_CONFIG) --modversion $(GITLIB)`
endif
ifeq ($(ERR),)
	VERSION := $(VERSION)"\\nerrors disabled"
else
	VERSION := $(VERSION)"\\nerrors enabled"
endif
ifeq ($(EXPLAIN),)
	VERSION := $(VERSION)"\\nexplinations disabled"
else
	VERSION := $(VERSION)"\\nexplinations enabled"
endif

CC = cc