1 |
# Process this file with autoconf to produce a configure script. |
# Process this file with autoconf to produce a configure script. |
2 |
AC_INIT(liblscp, 0.9.2, rncbc@rncbc.org, liblscp) |
AC_INIT(liblscp, 0.9.3, rncbc@rncbc.org, liblscp) |
3 |
|
|
4 |
AC_CONFIG_SRCDIR(src/client.c) |
AC_CONFIG_SRCDIR(src/client.c) |
5 |
AC_CONFIG_HEADERS([src/config.h]) |
AC_CONFIG_HEADERS([src/config.h]) |
23 |
# 6. If any interfaces have been removed since the last public release, then set age |
# 6. If any interfaces have been removed since the last public release, then set age |
24 |
# to 0. |
# to 0. |
25 |
|
|
26 |
SHARED_VERSION_INFO="6:3:0" |
SHARED_VERSION_INFO="6:4:0" |
27 |
|
|
28 |
AC_SUBST(SHARED_VERSION_INFO) |
AC_SUBST(SHARED_VERSION_INFO) |
29 |
|
|
43 |
fi |
fi |
44 |
]) |
]) |
45 |
ac_build_version="$ac_cv_build_version" |
ac_build_version="$ac_cv_build_version" |
46 |
AC_SUBST(ac_build_version) |
AC_DEFINE_UNQUOTED(CONFIG_BUILD_VERSION, ["$ac_build_version"], [Build version string.]) |
47 |
|
|
48 |
|
# Sanitized version string. |
49 |
|
AC_CACHE_VAL([ac_cv_version], [ |
50 |
|
ac_cv_version=$(echo $PACKAGE_VERSION | sed -r 's/^([[0-9|\.]]+).*$/\1/') |
51 |
|
]) |
52 |
|
ac_version="$ac_cv_version" |
53 |
|
AC_DEFINE_UNQUOTED(CONFIG_VERSION, ["$ac_version"], [Version string.]) |
54 |
|
AC_SUBST(ac_version) |
55 |
|
|
56 |
|
# Set default installation prefix. |
57 |
|
AC_PREFIX_DEFAULT(/usr/local) |
58 |
|
if test "x$prefix" = "xNONE"; then |
59 |
|
prefix=$ac_default_prefix |
60 |
|
fi |
61 |
|
if test "x$exec_prefix" = "xNONE"; then |
62 |
|
exec_prefix=$prefix |
63 |
|
fi |
64 |
|
eval ac_prefix=$prefix |
65 |
|
AC_SUBST(ac_prefix) |
66 |
|
|
67 |
|
# Enable debugging argument option. |
68 |
|
AC_ARG_ENABLE(debug, |
69 |
|
AS_HELP_STRING([--enable-debug], [enable debugging (default=no)]), |
70 |
|
[ac_debug="$enableval"]) |
71 |
|
if test "x$ac_debug" = "xyes"; then |
72 |
|
AC_DEFINE(CONFIG_DEBUG, 1, [Define if debugging is enabled.]) |
73 |
|
fi |
74 |
|
|
75 |
# Checks for programs. |
# Checks for programs. |
76 |
AC_PROG_CC |
AC_PROG_CC |
78 |
AC_PROG_LIBTOOL |
AC_PROG_LIBTOOL |
79 |
AM_PROG_LIBTOOL |
AM_PROG_LIBTOOL |
80 |
|
|
81 |
# Checks for header files. |
# Checks for standard header files. |
82 |
AC_HEADER_STDC |
AC_HEADER_STDC |
83 |
AC_CHECK_HEADERS(stdlib.h string.h netdb.h arpa/inet.h netinet/tcp.h netinet/in.h sys/socket.h unistd.h) |
|
84 |
|
AC_CHECK_HEADERS( |
85 |
|
[stdlib.h string.h netdb.h arpa/inet.h netinet/tcp.h netinet/in.h sys/socket.h unistd.h], |
86 |
|
[], [ac_headers_h="no"]) |
87 |
|
if test "x$ac_headers_h" = "xno"; then |
88 |
|
AC_MSG_ERROR([*** Standard headers not found.]) |
89 |
|
fi |
90 |
|
|
91 |
# Checks for typedefs, structures, and compiler characteristics. |
# Checks for typedefs, structures, and compiler characteristics. |
92 |
AC_C_CONST |
AC_C_CONST |
93 |
AC_TYPE_SIZE_T |
AC_TYPE_SIZE_T |
94 |
|
|
95 |
# Checks for library functions. |
# Checks for standard functions. |
96 |
AC_CHECK_FUNCS(strdup strtok_r memset memmove socket connect bind listen setsockopt getsockopt getsockname gethostbyname) |
AC_CHECK_FUNCS( |
97 |
|
[strdup strtok_r memset memmove socket connect bind listen setsockopt getsockopt getsockname gethostbyname], |
98 |
|
[], [ac_funcs_c="no"]) |
99 |
|
if test "x$ac_funcs_c" = "xno"; then |
100 |
|
AC_MSG_ERROR([*** Standard functions not found.]) |
101 |
|
fi |
102 |
|
|
103 |
case $host in |
case $host in |
104 |
*mingw*|*cygwin*) windows=yes ;; |
*mingw*|*cygwin*) windows=yes ;; |