pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/www/squid6



Module Name:    pkgsrc
Committed By:   sborrill
Date:           Fri Sep 15 07:40:05 UTC 2023

Modified Files:
        pkgsrc/www/squid6: Makefile distinfo
Added Files:
        pkgsrc/www/squid6/patches: patch-src_auth_ntlm_Scheme.cc
            patch-src_base_RunnersRegistry.h patch-src_main.cc

Log Message:
squid6: fix build and fix ntlm

Workaround linker problem removing ntlm auth
https://github.com/squid-cache/squid/commit/5596a2f4894f80864b660b035d05f5aec74f8312.patch

squid 6 requires GCC 8

Bump PKGREVISION


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 pkgsrc/www/squid6/Makefile \
    pkgsrc/www/squid6/distinfo
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/www/squid6/patches/patch-src_auth_ntlm_Scheme.cc \
    pkgsrc/www/squid6/patches/patch-src_base_RunnersRegistry.h \
    pkgsrc/www/squid6/patches/patch-src_main.cc

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/www/squid6/Makefile
diff -u pkgsrc/www/squid6/Makefile:1.1 pkgsrc/www/squid6/Makefile:1.2
--- pkgsrc/www/squid6/Makefile:1.1      Wed Sep 13 07:36:44 2023
+++ pkgsrc/www/squid6/Makefile  Fri Sep 15 07:40:05 2023
@@ -1,6 +1,7 @@
-# $NetBSD: Makefile,v 1.1 2023/09/13 07:36:44 taca Exp $
+# $NetBSD: Makefile,v 1.2 2023/09/15 07:40:05 sborrill Exp $
 
 DISTNAME=      squid-6.3
+PKGREVISION=   1
 CATEGORIES=    www
 MASTER_SITES=  http://www.squid-cache.org/Versions/v6/
 EXTRACT_SUFX=  .tar.xz
@@ -10,7 +11,12 @@ HOMEPAGE=    http://www.squid-cache.org/
 COMMENT=       Post-Harvest_cached WWW proxy cache and accelerator
 LICENSE=       gnu-gpl-v2
 
-USE_LANGUAGES=         c c++11
+# GCC 7 fails even with c++17
+# src/ipc/TypedMsgHdr.h fails with
+# static_assert(std::is_trivially_copyable<Pod>::value, "getPod() used for a POD")
+USE_LANGUAGES=         c c++17
+GCC_REQD+=             8
+
 USE_TOOLS+=            perl:run gmake
 GNU_CONFIGURE=         yes
 GNU_CONFIGURE_STRICT=  no # has sub-configure in libltdl
Index: pkgsrc/www/squid6/distinfo
diff -u pkgsrc/www/squid6/distinfo:1.1 pkgsrc/www/squid6/distinfo:1.2
--- pkgsrc/www/squid6/distinfo:1.1      Wed Sep 13 07:36:44 2023
+++ pkgsrc/www/squid6/distinfo  Fri Sep 15 07:40:05 2023
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.1 2023/09/13 07:36:44 taca Exp $
+$NetBSD: distinfo,v 1.2 2023/09/15 07:40:05 sborrill Exp $
 
 BLAKE2s (squid-6.3.tar.xz) = d5eb9f8effce2f9901e8e16c56e4b308dd98d231ffadb94713161e60d4d211f3
 SHA512 (squid-6.3.tar.xz) = add8718895ceccc130d31e6cbf9fbdb7fd45a778a617e9f02bf310babe72106e1dc14ac8b3dc81d31e1f4cace66d9d72176dd82f1652d7248a478fa10ffb6b87
@@ -8,6 +8,9 @@ SHA1 (patch-configure) = 66bf56c83876452
 SHA1 (patch-errors_Makefile.in) = e7ba371bb24e40eeb9dd10dc6fe12d208e681d72
 SHA1 (patch-src_Makefile.in) = afc5aefd97c46d1ffab43e97aeaeade3a5a8c648
 SHA1 (patch-src_acl_external_kerberos__ldap__group_support__resolv.cc) = 0ea41d55e32d689a16e012391a9eea67631daf3a
+SHA1 (patch-src_auth_ntlm_Scheme.cc) = 4f966c26bf6293cdfb0cf02970c3b03bbc348dee
+SHA1 (patch-src_base_RunnersRegistry.h) = d4cf35a85e2978155927fb2ea7111fb9429f9dfc
 SHA1 (patch-src_comm_ModKqueue.cc) = d8c5d235f07a48731275101d60fcbf2e22f77b96
 SHA1 (patch-src_esi_VarState.cc) = d9418e59cdc390b2d970195167a99bb7ed392c38
+SHA1 (patch-src_main.cc) = 0655bdd4cac956e5fe83149cf03455e5a39a03a5
 SHA1 (patch-tools_Makefile.in) = d098c0c9dc4af577f74e562d99f07ed98be5ae01

Added files:

Index: pkgsrc/www/squid6/patches/patch-src_auth_ntlm_Scheme.cc
diff -u /dev/null pkgsrc/www/squid6/patches/patch-src_auth_ntlm_Scheme.cc:1.1
--- /dev/null   Fri Sep 15 07:40:05 2023
+++ pkgsrc/www/squid6/patches/patch-src_auth_ntlm_Scheme.cc     Fri Sep 15 07:40:05 2023
@@ -0,0 +1,17 @@
+$NetBSD: patch-src_auth_ntlm_Scheme.cc,v 1.1 2023/09/15 07:40:05 sborrill Exp $
+
+Workaround linker problem removing ntlm auth
+https://github.com/squid-cache/squid/commit/5596a2f4894f80864b660b035d05f5aec74f8312.patch
+
+--- src/auth/ntlm/Scheme.cc.orig       2023-09-03 07:17:45.000000000 +0100
++++ src/auth/ntlm/Scheme.cc    2023-09-04 15:26:25.285516743 +0100
+@@ -23,7 +23,8 @@
+         debugs(29, 2, "Initialized Authentication Scheme '" << type << "'");
+     }
+ };
+-RunnerRegistrationEntry(NtlmAuthRr);
++
++DefineRunnerRegistrator(NtlmAuthRr);
+ 
+ Auth::Scheme::Pointer
+ Auth::Ntlm::Scheme::GetInstance()
Index: pkgsrc/www/squid6/patches/patch-src_base_RunnersRegistry.h
diff -u /dev/null pkgsrc/www/squid6/patches/patch-src_base_RunnersRegistry.h:1.1
--- /dev/null   Fri Sep 15 07:40:05 2023
+++ pkgsrc/www/squid6/patches/patch-src_base_RunnersRegistry.h  Fri Sep 15 07:40:05 2023
@@ -0,0 +1,42 @@
+$NetBSD: patch-src_base_RunnersRegistry.h,v 1.1 2023/09/15 07:40:05 sborrill Exp $
+
+Workaround linker problem removing ntlm auth
+https://github.com/squid-cache/squid/commit/5596a2f4894f80864b660b035d05f5aec74f8312.patch
+
+--- src/base/RunnersRegistry.h.orig    2023-09-03 07:17:45.000000000 +0100
++++ src/base/RunnersRegistry.h 2023-09-04 15:26:25.292793976 +0100
+@@ -121,11 +121,34 @@
+ /// convenience function to "use" an otherwise unreferenced static variable
+ bool UseThisStatic(const void *);
+ 
++// TODO: Remove, together with UseThisStatic(), after migrating to DefineRunnerRegistrator()
+ /// convenience macro: register one RegisteredRunner kid as early as possible
+ #define RunnerRegistrationEntry(Who) \
+     static const bool Who ## _Registered_ = \
+         RegisterRunner(new Who) > 0 && \
+         UseThisStatic(& Who ## _Registered_);
+ 
++/// helps DefineRunnerRegistrator() and CallRunnerRegistrator() to use the same
++/// registration function name
++#define DeclareRunnerRegistrator(Who) \
++    void Register ## Who ## Now()
++
++/// Define registration code for the given RegisteredRunner class. A matching
++/// CallRunnerRegistrator(Who) call should run this code before any possible use
++/// of the being-registered module.
++#define DefineRunnerRegistrator(Who) \
++    DeclareRunnerRegistrator(Who); \
++    void Register ## Who ## Now() { \
++        const auto registered = RegisterRunner(new Who); \
++        assert(registered); \
++    }
++
++/// convenience macro: register one RegisteredRunner kid
++#define CallRunnerRegistrator(Who) \
++    do { \
++        DeclareRunnerRegistrator(Who); \
++        Register ## Who ## Now(); \
++    } while (false)
++
+ #endif /* SQUID_BASE_RUNNERSREGISTRY_H */
+ 
Index: pkgsrc/www/squid6/patches/patch-src_main.cc
diff -u /dev/null pkgsrc/www/squid6/patches/patch-src_main.cc:1.1
--- /dev/null   Fri Sep 15 07:40:05 2023
+++ pkgsrc/www/squid6/patches/patch-src_main.cc Fri Sep 15 07:40:05 2023
@@ -0,0 +1,22 @@
+$NetBSD: patch-src_main.cc,v 1.1 2023/09/15 07:40:05 sborrill Exp $
+
+Workaround linker problem removing ntlm auth
+https://github.com/squid-cache/squid/commit/5596a2f4894f80864b660b035d05f5aec74f8312.patch
+
+--- src/main.cc.orig   2023-09-03 07:17:45.000000000 +0100
++++ src/main.cc        2023-09-04 15:26:25.301609039 +0100
+@@ -1440,6 +1440,14 @@
+ int
+ SquidMain(int argc, char **argv)
+ {
++    // We must register all modules before the first RunRegisteredHere() call.
++    // We do it ASAP/here so that we do not need to move this code when we add
++    // earlier hooks to the RegisteredRunner API. This collection of
++    // registration calls is not a RegisteredRunner "event" in itself.
++#if HAVE_AUTH_MODULE_NTLM
++    CallRunnerRegistrator(NtlmAuthRr);
++#endif
++
+     const CommandLine cmdLine(argc, argv, shortOpStr, squidOptions);
+ 
+     ConfigureCurrentKid(cmdLine);



Home | Main Index | Thread Index | Old Index