From: Amos Jeffries Date: Fri, 12 Dec 2025 03:49:15 +0000 (+0000) Subject: Remove SQUID_CHECK_KRB5_SOLARIS_BROKEN_KRB5_H macro (#2314) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fheads%2Fauto;p=thirdparty%2Fsquid.git Remove SQUID_CHECK_KRB5_SOLARIS_BROKEN_KRB5_H macro (#2314) The issue this portability hack works around was resolved in Solaris 10 update "U11" and likely Solaris 11.3 releases. --- diff --git a/acinclude/krb5.m4 b/acinclude/krb5.m4 index e0286fa391..d43a0e613a 100644 --- a/acinclude/krb5.m4 +++ b/acinclude/krb5.m4 @@ -37,14 +37,6 @@ AC_DEFUN([SQUID_CHECK_SOLARIS_KRB5],[ AS_IF([test "x$missing_required" = "xyes"],[LIBMIT_KRB5_LIBS=""],[ LIBS="$LIBMIT_KRB5_LIBS $LIBS" AC_DEFINE(USE_SOLARIS_KRB5,1,[Solaris Kerberos support is available]) - SQUID_CHECK_KRB5_SOLARIS_BROKEN_KRB5_H - AS_IF([test "x$squid_cv_broken_krb5_h" = "xyes"],[ - AC_DEFINE(HAVE_BROKEN_SOLARIS_KRB5_H, 1, [Define to 1 if Solaris krb5.h is broken for C++]) - AC_MSG_WARN([You have a broken Solaris system include.]) - AC_MSG_WARN([Please see http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6837512]) - AC_MSG_WARN([If you need Kerberos support you will have to patch]) - AC_MSG_WARN([your system. See contrib/solaris/solaris-krb5-include.patch]) - ]) AC_CHECK_HEADERS(gssapi.h gssapi/gssapi.h gssapi/gssapi_krb5.h) AC_CHECK_HEADERS(gssapi/gssapi_ext.h gssapi/gssapi_generic.h) AC_CHECK_HEADERS(krb5.h com_err.h et/com_err.h) @@ -53,27 +45,6 @@ AC_DEFUN([SQUID_CHECK_SOLARIS_KRB5],[ ]) ]) -dnl checks for a broken solaris header file, and sets squid_cv_broken_krb5_h -dnl to yes if that's the case -AC_DEFUN([SQUID_CHECK_KRB5_SOLARIS_BROKEN_KRB5_H], [ - AC_CACHE_CHECK([for broken Solaris krb5.h],squid_cv_broken_krb5_h, [ - SQUID_STATE_SAVE(squid_krb5_solaris_test) - CPPFLAGS="-I${srcdir:-.} $CPPFLAGS" - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ -#include -int i; -]])], [ squid_cv_broken_krb5_h=no ], [ - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ -#define HAVE_BROKEN_SOLARIS_KRB5_H 1 -#include "compat/krb5.h" -int i; -]])], [ squid_cv_broken_krb5_h=yes ], [ squid_cv_broken_krb5_h=no ]) - ]) - SQUID_STATE_ROLLBACK(squid_krb5_solaris_test) - ]) -]) dnl SQUID_CHECK_KRB5_SOLARIS_BROKEN_KRB5_H - - AC_DEFUN([SQUID_CHECK_KRB5_HEIMDAL_BROKEN_KRB5_H], [ AC_CACHE_CHECK([for broken Heimdal krb5.h],squid_cv_broken_heimdal_krb5_h, [ SQUID_STATE_SAVE(squid_krb5_heimdal_test) diff --git a/compat/krb5.h b/compat/krb5.h index fd8940d80e..28e5d4239a 100644 --- a/compat/krb5.h +++ b/compat/krb5.h @@ -18,10 +18,6 @@ * * - Heimdal may lack the extern "C" syntax for building in C++ * - * - Solaris incorrectly implements its own the extern "C" replacement - * macros and as a result krb5.h contains a trailing '}'. - * see http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6837512 - * * This file exists to fix those issues the best we can and to * ensure the logic is identical in Squid code, Squid helpers, * and autoconf tests. See acinclude/krb5.h for the latter. @@ -35,12 +31,6 @@ extern "C" { # include } -# elif HAVE_BROKEN_SOLARIS_KRB5_H && defined(__cplusplus) -# define KRB5INT_BEGIN_DECLS extern "C" { -# define KRB5INT_END_DECLS -extern "C" { -# include - /* broken Solaris krb5.h contains the closing } */ # else # include # endif diff --git a/contrib/Makefile.am b/contrib/Makefile.am index f6a3ec014b..7221fdcf46 100644 --- a/contrib/Makefile.am +++ b/contrib/Makefile.am @@ -17,8 +17,7 @@ EXTRA_DIST = \ squid.options \ config.site \ user-agents.pl \ - url-normalizer.pl \ - solaris/solaris-krb5-include.patch + url-normalizer.pl all: diff --git a/contrib/solaris/solaris-krb5-include.patch b/contrib/solaris/solaris-krb5-include.patch deleted file mode 100644 index c84b09a301..0000000000 --- a/contrib/solaris/solaris-krb5-include.patch +++ /dev/null @@ -1,27 +0,0 @@ -/* - * Copyright (C) 1996-2025 The Squid Software Foundation and contributors - * - * Squid software is distributed under GPLv2+ license and includes - * contributions from numerous individuals and organizations. - * Please see the COPYING and CONTRIBUTORS files for details. - */ - ---- /usr/include/kerberosv5/krb5.h.orig Mon Aug 23 04:09:23 2010 -+++ /usr/include/kerberosv5/krb5.h Mon Aug 23 04:10:53 2010 -@@ -171,6 +171,7 @@ - #define KRB5INT_END_DECLS - #endif - #endif -+KRB5INT_BEGIN_DECLS - - #if TARGET_OS_MAC - # pragma options align=mac68k -@@ -3246,8 +3247,4 @@ - /* for compatibility with older versions... */ - #define asn1_err_base ERROR_TABLE_BASE_asn1 - --#ifdef __cplusplus --} --#endif -- - #endif /* _KRB5_H */