From fa5eea494c58059b57b2da42bba594ebfbab1c7b Mon Sep 17 00:00:00 2001 From: Stefan Becker Date: Sat, 13 Mar 2010 11:07:44 +0200 Subject: [PATCH] configure: rename USE_KERBEROS to HAVE_KERBEROS So in the future grep'ing for flags don't miss some... --- configure.ac | 5 +---- src/core/Makefile.mingw | 2 +- src/core/http-conn.c | 14 +++++++------- src/core/sip-sec.c | 8 ++++---- src/core/sipe.c | 4 ++-- src/purple/purple-plugin.c | 2 +- 6 files changed, 16 insertions(+), 19 deletions(-) diff --git a/configure.ac b/configure.ac index f571f134..47ac2362 100644 --- a/configure.ac +++ b/configure.ac @@ -6,9 +6,6 @@ m4_define([_SIPE_VERSION], m4_substr(SIPE_VERSION_DATA, [0], m4_decr(m4_len(SIPE_VERSION_DATA)))) -dnl version of this package -m4_define(pidgin_sipe_version, _SIPE_VERSION) - AC_INIT([pidgin-sipe], _SIPE_VERSION) AC_DEFINE(SIPE_VERSION, "_SIPE_VERSION", [Define sipe version.]) @@ -108,7 +105,7 @@ if test "$kerberos" != "no" ; then LIBS="$KRB5_LIBS $LIBS" AC_CHECK_FUNCS([krb5_get_error_message]) LIBS="$savedLIBS" - AC_DEFINE(USE_KERBEROS, 1, [Define if kerberos should be used in sipe.]) + AC_DEFINE(HAVE_KERBEROS, 1, [Define if kerberos should be used in sipe.]) fi dnl check for glib diff --git a/src/core/Makefile.mingw b/src/core/Makefile.mingw index e6430e2f..b05c45d8 100644 --- a/src/core/Makefile.mingw +++ b/src/core/Makefile.mingw @@ -26,7 +26,7 @@ endif DEFINES += -DSIPE_VERSION=\"$(VERSION)\" DEFINES += -DGETTEXT_PACKAGE=\"pidgin-sipe\" -DEFINES += -DUSE_KERBEROS=1 +DEFINES += -DHAVE_KERBEROS=1 ## ## INCLUDE PATHS ## diff --git a/src/core/http-conn.c b/src/core/http-conn.c index 11e09461..a68de680 100644 --- a/src/core/http-conn.c +++ b/src/core/http-conn.c @@ -545,7 +545,7 @@ http_conn_process_input_message(HttpConn *http_conn, else if (msg->response == 401) { char *ptmp; #ifdef _WIN32 -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS char *tmp; #endif #endif @@ -570,7 +570,7 @@ http_conn_process_input_message(HttpConn *http_conn, auth_type = AUTH_TYPE_NTLM; auth_name = "NTLM"; #ifdef _WIN32 -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS tmp = sipmsg_find_auth_header(msg, "Negotiate"); if (tmp && http_conn->auth && http_conn->auth->use_negotiate) { ptmp = tmp; @@ -582,14 +582,14 @@ http_conn_process_input_message(HttpConn *http_conn, if (!ptmp) { purple_debug_info("sipe-http", "http_conn_process_input_message: Only %s supported in the moment, exiting\n", #ifdef _WIN32 -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS "NTLM and Negotiate authentications are" -#else //USE_KERBEROS +#else /* !HAVE_KERBEROS */ "NTLM authentication is" -#endif //USE_KERBEROS -#else //_WIN32 +#endif /* HAVE_KERBEROS */ +#else /* !_WIN32 */ "NTLM authentication is" -#endif //_WIN32 +#endif /* _WIN32 */ ); } diff --git a/src/core/sip-sec.c b/src/core/sip-sec.c index da58637d..8f23f518 100644 --- a/src/core/sip-sec.c +++ b/src/core/sip-sec.c @@ -40,7 +40,7 @@ #define sip_sec_create_context__NTLM sip_sec_create_context__ntlm #define sip_sec_create_context__Negotiate sip_sec_create_context__NONE -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS #include "sip-sec-krb5.h" #define sip_sec_create_context__Kerberos sip_sec_create_context__krb5 #else @@ -48,16 +48,16 @@ #endif #else /* _WIN32 */ -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS #include "sip-sec-sspi.h" #define sip_sec_create_context__NTLM sip_sec_create_context__sspi #define sip_sec_create_context__Negotiate sip_sec_create_context__sspi #define sip_sec_create_context__Kerberos sip_sec_create_context__sspi -#else /* USE_KERBEROS */ +#else /* HAVE_KERBEROS */ #define sip_sec_create_context__NTLM sip_sec_create_context__ntlm #define sip_sec_create_context__Negotiate sip_sec_create_context__NONE #define sip_sec_create_context__Kerberos sip_sec_create_context__NONE -#endif /* USE_KERBEROS */ +#endif /* HAVE_KERBEROS */ #endif /* _WIN32 */ diff --git a/src/core/sipe.c b/src/core/sipe.c index c1742ab5..9570ea1f 100644 --- a/src/core/sipe.c +++ b/src/core/sipe.c @@ -841,7 +841,7 @@ static void sign_outgoing_message (struct sipmsg * msg, struct sipe_account_data } else if (sipe_strequal(method,"SUBSCRIBE") || sipe_strequal(method,"SERVICE") || sipe_strequal(method,"MESSAGE") || sipe_strequal(method,"INVITE") || sipe_strequal(method, "ACK") || sipe_strequal(method, "NOTIFY") || sipe_strequal(method, "BYE") || sipe_strequal(method, "INFO") || sipe_strequal(method, "OPTIONS") || sipe_strequal(method, "REFER")) { sip->registrar.nc = 3; sip->registrar.type = AUTH_TYPE_NTLM; -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS if (purple_account_get_bool(sip->account, "krb5", FALSE)) { sip->registrar.type = AUTH_TYPE_KERBEROS; } @@ -5341,7 +5341,7 @@ static const char* sipe_get_auth_scheme_name(struct sipe_account_data *sip) { const char *res = "NTLM"; -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS if (purple_account_get_bool(sip->account, "krb5", FALSE)) { res = "Kerberos"; } diff --git a/src/purple/purple-plugin.c b/src/purple/purple-plugin.c index f3680943..b07fc80d 100644 --- a/src/purple/purple-plugin.c +++ b/src/purple/purple-plugin.c @@ -105,7 +105,7 @@ static void init_plugin(PurplePlugin *plugin) option = purple_account_option_string_new(_("User Agent"), "useragent", ""); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); -#ifdef USE_KERBEROS +#ifdef HAVE_KERBEROS option = purple_account_option_bool_new(_("Use Kerberos"), "krb5", FALSE); prpl_info.protocol_options = g_list_append(prpl_info.protocol_options, option); -- 2.11.4.GIT