source: configure.in @ 60fc8aa

4.0.1-hotfixescachetimestampsdevelopdpdk-ndagetsilivegetfragoffhelplibtrace4ndag_formatpfringrc-4.0.1rc-4.0.2rc-4.0.3rc-4.0.4ringdecrementfixringperformanceringtimestampfixes
Last change on this file since 60fc8aa was 60fc8aa, checked in by Daniel Lawson <dlawson@…>, 17 years ago

poink

  • Property mode set to 100644
File size: 2.6 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2AC_INIT(lib/trace.c)
3AM_INIT_AUTOMAKE(libtrace,[2.0.0],[libtrace@wand.net.nz])
4
5AC_PREREQ(2.5)
6
7AC_CONFIG_SRCDIR(lib/trace.c)
8AM_CONFIG_HEADER(lib/config.h)
9dnl Checks for programs.
10AC_PROG_CC
11AC_PROG_INSTALL
12AC_PROG_LIBTOOL
13
14
15dnl GNU C library
16AC_GNU_SOURCE
17
18dnl Checks for header files.
19AC_HEADER_STDC
20dnl AC_CHECK_HEADERS(errno.h stdlib.h stdio.h assert.h string.h netinet/in.h assert.h errno.h fcntl.h net/ethernet.h netdb.h pcap.h stdio.h stdlib.h string.h sys/stat.h sys/types.h sys/socket.h sys/un.h unistd.h time.h sys/ioctl.h net/bpf.h pcap.h zlib.h pcap-bpf.h)
21AC_CHECK_HEADERS(pcap.h zlib.h pcap-bpf.h net/bpf.h)
22
23dnl Checks for typedefs, structures, and compiler characteristics.
24AC_C_CONST
25AC_C_INLINE
26AC_C_BIGENDIAN
27AC_TYPE_SIZE_T
28AC_HEADER_TIME
29AC_SYS_LARGEFILE
30
31dnl Checks for library functions.
32AC_PROG_GCC_TRADITIONAL
33AC_CHECK_FUNCS(socket strdup)
34
35
36
37dnl configure time options for selecting which libpcap and libz to use
38dnl this is provided to allow for systems whose default libraries don't support
39dnl large files - you can build your own and link using these options
40AC_DEFUN([CHECK_LIBPCAP],
41         [AC_ARG_WITH([pcap],
42                      AC_HELP_STRING([--with-pcap],
43                                     [name of pcap library (default is pcap)]),
44                      [ac_cv_use_pcap=$withval], [ac_cv_use_pcap=pcap])
45AC_CACHE_CHECK([which pcap library to use],
46               [ac_cv_use_pcap], [ac_cv_use_pcap=pcap])])
47
48AC_DEFUN([CHECK_LIBPCAP_PATH],
49         [AC_ARG_WITH([pcap-path],
50                      AC_HELP_STRING([--with-pcap-path],
51                                     [location of pcap library (default is /usr/lib)]),
52                      [ac_cv_use_pcap_path=$withval], [ac_cv_use_pcap_path=/usr/lib])
53AC_CACHE_CHECK([location of pcap library],
54               [ac_cv_use_pcap_path], [ac_cv_use_pcap_path=/usr/lib])])
55
56
57AC_DEFUN([CHECK_LIBZ],
58         [AC_ARG_WITH([zlib],
59                      AC_HELP_STRING([--with-zlib],
60                                     [name of zlib library (default is z)]),
61                      [ac_cv_use_zlib=$withval], [ac_cv_use_zlib=z])
62AC_CACHE_CHECK([which zlib library to use],
63               [ac_cv_use_zlib], [ac_cv_use_zlib=z])])
64
65AC_DEFUN([CHECK_LIBZ_PATH],
66        [AC_ARG_WITH([zlib-path],
67                AC_HELP_STRING([--with-zlib-path],
68                        [location of zlib library (default is /usr/lib)]),
69                [ac_cv_use_zlib_path=$withval], [ac_cv_use_zlib_path=/usr/lib])
70AC_CACHE_CHECK([location of zlib library],
71               [ac_cv_use_zlib_path], [ac_cv_use_zlib_path=/usr/lib])])
72
73CHECK_LIBPCAP
74CHECK_LIBPCAP_PATH
75CHECK_LIBZ
76CHECK_LIBZ_PATH
77
78LIBPCAP=-l$ac_cv_use_pcap
79LIBPCAP_PATH=-L$ac_cv_use_pcap_path
80
81AC_SUBST([LIBPCAP])
82AC_SUBST([LIBPCAP_PATH])
83
84LIBZ=-l$ac_cv_use_zlib
85LIBZ_PATH=-L$ac_cv_use_zlib_path
86AC_SUBST([LIBZ])
87AC_SUBST([LIBZ_PATH])
88
89AC_OUTPUT(Makefile lib/Makefile)
Note: See TracBrowser for help on using the repository browser.