- fix_configuration_error.patch: Fix compilation with -Wreturn-type
- old_nettle_compat.patch: Update to actually use older version OBS-URL: https://build.opensuse.org/package/show/server:proxy/squid?expand=0&rev=196
This commit is contained in:
parent
e1d5654187
commit
51b5f199a0
32
fix_configuration_error.patch
Normal file
32
fix_configuration_error.patch
Normal file
@ -0,0 +1,32 @@
|
||||
Fix warnings that result in build failures with -Wreturn-type errors
|
||||
|
||||
error: no return statement in function returning non-void
|
||||
warning: 'conv' defined but not used
|
||||
|
||||
202 | static struct pam_conv conv = { &password_conversation, 0 };
|
||||
| ^~~~
|
||||
cc1plus: some warnings being treated as errors
|
||||
|
||||
|
||||
Index: squid-4.8/acinclude/pam.m4
|
||||
===================================================================
|
||||
--- squid-4.8.orig/acinclude/pam.m4
|
||||
+++ squid-4.8/acinclude/pam.m4
|
||||
@@ -21,7 +21,7 @@ AC_DEFUN([CHECK_STRUCT_PAM_CONV], [
|
||||
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
|
||||
#include <security/pam_appl.h>
|
||||
static int
|
||||
-password_conversation(int num_msg, const struct pam_message **msg, struct pam_response **resp, void *appdata_ptr) {}
|
||||
+password_conversation(int num_msg, const struct pam_message **msg, struct pam_response **resp, void *appdata_ptr) { return 0; }
|
||||
static struct pam_conv conv = { &password_conversation, 0 };
|
||||
]])], [
|
||||
squid_cv_pam_conv_signature=linux
|
||||
@@ -29,7 +29,7 @@ static struct pam_conv conv = { &passwor
|
||||
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
|
||||
#include <security/pam_appl.h>
|
||||
static int
|
||||
-password_conversation(int num_msg, struct pam_message **msg, struct pam_response **resp, void *appdata_ptr) {}
|
||||
+password_conversation(int num_msg, struct pam_message **msg, struct pam_response **resp, void *appdata_ptr) { return 0; }
|
||||
static struct pam_conv conv = { &password_conversation, 0 };
|
||||
]])], [
|
||||
squid_cv_pam_conv_signature=solaris
|
@ -130,3 +130,21 @@ Index: squid-4.8/tools/cachemgr.cc
|
||||
if (!base64_decode_update(&ctx, &decodedLen, reinterpret_cast<uint8_t*>(buf), strlen(req->pub_auth), req->pub_auth) ||
|
||||
!base64_decode_final(&ctx)) {
|
||||
debug("cmgr: base64 decode failure. Incomplete auth token string.\n");
|
||||
Index: squid-4.8/include/base64.h
|
||||
===================================================================
|
||||
--- squid-4.8.orig/include/base64.h
|
||||
+++ squid-4.8/include/base64.h
|
||||
@@ -9,11 +9,11 @@
|
||||
#ifndef _SQUID_BASE64_H
|
||||
#define _SQUID_BASE64_H
|
||||
|
||||
-#if HAVE_NETTLE_BASE64_H && HAVE_NETTLE34_BASE64
|
||||
+#if HAVE_NETTLE_BASE64_H
|
||||
#include <nettle/base64.h>
|
||||
|
||||
#else /* Base64 functions copied from Nettle 3.4 under GPLv2, with adjustments */
|
||||
-
|
||||
+#error "Mssing libnettle-devel"
|
||||
/* base64.h
|
||||
|
||||
Base-64 encoding and decoding.
|
||||
|
@ -1,3 +1,9 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Aug 6 13:05:58 UTC 2019 - Adam Majer <adam.majer@suse.de>
|
||||
|
||||
- fix_configuration_error.patch: Fix compilation with -Wreturn-type
|
||||
- old_nettle_compat.patch: Update to actually use older version
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Jul 18 14:11:28 UTC 2019 - Adam Majer <adam.majer@suse.de>
|
||||
|
||||
|
@ -40,6 +40,7 @@ Source16: initialize_cache_if_needed.sh
|
||||
Source17: tmpfilesdir.squid.conf
|
||||
Patch1: missing_installs.patch
|
||||
Patch2: old_nettle_compat.patch
|
||||
Patch3: fix_configuration_error.patch
|
||||
BuildRequires: cppunit-devel
|
||||
BuildRequires: db-devel
|
||||
BuildRequires: ed
|
||||
@ -92,6 +93,7 @@ perl -p -i -e 's|%{_prefix}/local/bin/perl|%{_bindir}/perl|' `find -name "*.pl"`
|
||||
%if %{suse_version} < 1500
|
||||
%patch2 -p1
|
||||
%endif
|
||||
%patch3 -p1
|
||||
|
||||
%build
|
||||
%define _lto_cflags %{nil}
|
||||
|
Loading…
Reference in New Issue
Block a user