-
Notifications
You must be signed in to change notification settings - Fork 1
/
configure.ac
33 lines (24 loc) · 1.01 KB
/
configure.ac
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
AC_PREREQ(2.60)
AC_INIT([libkcoidc], m4_esyscmd([scripts/git-version-gen .version]), [[email protected]])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_FILES([libkcoidc.pc])
AC_PROG_CC
if ! which "${CC}" >/dev/null ; then
AC_MSG_ERROR([Please install a C compiler before trying to build libkcoidc])
fi
AC_PROG_CXX
AC_PATH_PROG([GO],[go])
if ! which "${GO}" >/dev/null ; then
AC_MSG_ERROR([Please install Go (https://golang.org) before trying to build libkcoidc])
fi
GO_VERSION_MIN=1.13
GO_VERSION=$(${GO} version | sed 's/^go version go//' | sed 's/ .*//')
AX_COMPARE_VERSION([$GO_VERSION], [ge], [$GO_VERSION_MIN],
AC_MSG_NOTICE([Go ${GO_VERSION} found]),
AC_MSG_ERROR([Please install Go ${GO_VERSION_MIN} or newer before trying to build libkcoidc (found Go ${GO_VERSION}).]))
AC_PATH_PROG([GOFMT],[gofmt])
AC_PATH_PROG([GOLINT],[golangci-lint])
AC_PATH_PROG([GO2XUNIT],[go2xunit])
AC_PATH_PROGS([PYTHON],[python3 python python2],[python])
AC_PATH_PROG([GITCHGLOG],[git-chglog],[git-chglog])
AC_OUTPUT(Makefile)