added --disable-ips configure option which allows to compile the oldstyle --numeric behavior

git-svn-id: http://svn.berlios.de/svnroot/repos/sipsak/trunk@413 75b5f7c7-cfd4-0310-b54c-e118b2c5249a
(cherry picked from commit 36c442296faecf7842c67d42600860cb52c9c6fd)
changes/49/4849/1
nils-ohlmeier 20 years ago committed by Victor Seva
parent 7a454d5895
commit 4b840f5b31

@ -35,6 +35,19 @@ AC_DEFUN([SIPSAK_TIMER],
AC_DEFINE_UNQUOTED(DEFAULT_TIMEOUT, $def_timeout, [Default maximum timeout on waiting for response.])
])
AC_DEFUN([SIPSAK_OLD_FQDN],
[
AC_MSG_CHECKING([oldstyle numeric])
AC_ARG_ENABLE([ips],
AC_HELP_STRING([--disbale-ips], [compile with oldstyle --numeric behavior]),
[
AC_MSG_RESULT([yes])
AC_DEFINE([OLDSTYLE_FQDN], [1], [Oldstyle FQDN behavior])
],
[ AC_MSG_RESULT([not requested])
])
])
AC_DEFUN([CHECK_LIB_CARES],
[
AC_MSG_CHECKING([for ares_version.h])

@ -193,6 +193,9 @@
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Oldstyle FQDN behavior */
#undef OLDSTYLE_FQDN
/* Name of package */
#undef PACKAGE

22
configure vendored

@ -1518,6 +1518,7 @@ Optional Features:
--enable-dependency-tracking do not reject slow dependency extractors
--enable-distcc compile in parallel with distcc
--enable-timeout=SEC SIP timer T1 in SEC milliseconds (default 500)
--disbale-ips compile with oldstyle --numeric behavior
Some influential environment variables:
CC C compiler command
@ -8301,6 +8302,27 @@ _ACEOF
{ echo "$as_me:$LINENO: checking oldstyle numeric" >&5
echo $ECHO_N "checking oldstyle numeric... $ECHO_C" >&6; }
# Check whether --enable-ips was given.
if test "${enable_ips+set}" = set; then
enableval=$enable_ips;
{ echo "$as_me:$LINENO: result: yes" >&5
echo "${ECHO_T}yes" >&6; }
cat >>confdefs.h <<\_ACEOF
#define OLDSTYLE_FQDN 1
_ACEOF
else
{ echo "$as_me:$LINENO: result: not requested" >&5
echo "${ECHO_T}not requested" >&6; }
fi
ac_config_files="$ac_config_files Makefile"
cat >confcache <<\_ACEOF

@ -83,6 +83,7 @@ else
fi
SIPSAK_TIMER
SIPSAK_OLD_FQDN
AC_CONFIG_FILES([Makefile])
AC_OUTPUT

@ -123,7 +123,12 @@ void print_long_help() {
" --outbound-proxy=HOSTNAME request target (outbound proxy)\n"
" --hostname=HOSTNAME overwrites the local hostname in all headers\n"
" --max-forwards=NUMBER the value for the max-forwards header field\n"
" --numeric use FQDN instead of IPs in the Via-Line\n");
#ifdef OLDSTYLE_FQDN
" --numeric use IP instead of FQDN in the Via-Line\n"
#else
" --numeric use FQDN instead of IP in the Via-Line\n"
#endif
);
printf(" --processes=NUMBER Divide the workflow among the number of processes\n"
" --auth-username=STRING username for authentication\n"
);
@ -190,7 +195,11 @@ void print_help() {
printf(
" -H HOSTNAME overwrites the local hostname in all headers\n"
" -m NUMBER the value for the max-forwards header field\n"
" -n use FQDN instead of IPs in the Via-Line\n"
#ifdef OLDSTYLE_FQDN
" -n use IP instead of FQDN in the Via-Line\n"
#else
" -n use FQDN instead of IP in the Via-Line\n"
#endif
" -i deactivate the insertion of a Via-Line\n"
" -a PASSWORD password for authentication\n"
" (if omitted password=\"\")\n"
@ -288,7 +297,12 @@ int main(int argc, char *argv[])
warning_ext=rand_rem=nonce_count=replace_b=invite=message = 0;
sleep_ms=empty_contact=nagios_warn=timing=outbound_proxy=symmetric = 0;
namebeg=nameend=maxforw= -1;
numeric=via_ins=redirects=fix_crlf=processes = 1;
#ifdef OLDSTYLE_FQDN
numeric = 0;
#else
numeric = 1;
#endif
via_ins=redirects=fix_crlf=processes = 1;
username=password=replace_str=hostname=contact_uri=mes_body = NULL;
con_dis=auth_username=from_uri=headers=authhash = NULL;
scheme = user = host = backup = req = rep = rec = NULL;

Loading…
Cancel
Save