-
Notifications
You must be signed in to change notification settings - Fork 4
/
configure.ac
executable file
·64 lines (51 loc) · 1.66 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
AC_INIT([dhcp-helper], [2.2-pre], [], [dhcp-helper])
AC_PREREQ([2.59])
AC_CONFIG_HEADERS([src/config.h])
AC_CONFIG_SRCDIR([src/dhcp-helper.c])
AC_CONFIG_FILES([Makefile src/Makefile tests/Makefile])
AC_PROG_CPP
AC_PROG_CC
# Lax strictness, don't define PACKAGE and VERSION in config.h
AM_INIT_AUTOMAKE([1.10 foreign no-define])
# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([sys/socket.h])
AC_CHECK_HEADERS([sys/ioctl.h])
AC_CHECK_HEADERS([sys/select.h])
AC_CHECK_HEADERS([sys/time.h])
AC_CHECK_HEADERS([sys/stat.h])
AC_CHECK_HEADERS([limits.h])
AC_CHECK_HEADERS([net/if.h])
AC_CHECK_HEADERS([unistd.h])
AC_CHECK_HEADERS([fcntl.h])
AC_CHECK_HEADERS([stdio.h])
AC_CHECK_HEADERS([string.h])
AC_CHECK_HEADERS([stdlib.h])
AC_CHECK_HEADERS([time.h])
AC_CHECK_HEADERS([errno.h])
AC_CHECK_HEADERS([pwd.h])
AC_CHECK_HEADERS([grp.h])
AC_CHECK_HEADERS([netdb.h])
AC_CHECK_HEADERS([linux/types.h])
AC_CHECK_HEADERS([linux/capability.h])
AC_CHECK_HEADERS([sys/prctl.h])
AC_CHECK_HEADERS([net/if_arp.h])
AC_CHECK_HEADERS([linux/netlink.h])
# Check for pkg-config first, warn if it's not installed
PKG_PROG_PKG_CONFIG
PKG_CHECK_MODULES([LIBNL], [libnl-3.0 libnl-genl-3.0 libnl-route-3.0])
PKG_CHECK_MODULES([JANSSON], [jansson])
AC_CHECK_HEADER([ev.h],
[AC_CHECK_LIB([ev], [ev_loop_new],
[],
[AC_MSG_ERROR("libev not found")] )],
[AC_MSG_ERROR("ev.h not found")]
)
# Checks for typedefs, structures, and compiler characteristics.
AC_TYPE_SIZE_T
# distribute additional compiler and linker flags among Makefiles
# --> set and change these variables instead of CXXFLAGS or LDFLAGS (for user only)
AC_SUBST([AM_CFLAGS])
AC_SUBST([AM_LDFLAGS])
AC_SUBST([CFLAGS])
AC_OUTPUT