From 7d13944f65824a9238aff4c18cfcdcbfc1ba619a Mon Sep 17 00:00:00 2001 From: Roy Li Date: Sun, 6 Sep 2015 17:22:52 +0800 Subject: squid: upgrade to 3.5.7 1. Remove the squid-change-ksh-referen*.patch which is not needed, since 3.5.7 did not use ksh by default. 2. Update the checksum of COPYING,since the date in it has been changed. 3. Define BUILDCXXFLAGS, otherwise the target gcc options -std=c++11 will add into it, and lead to building failure since host gcc maybe not support "-std=c++11" 4. Assume to support GNU atomic operations by default, the running check on cross-compile setup does not work 5. enable basic auth by checking the DISTRO_FEATURE, and the default dependency on db, opensasl and openldap nis have been set, so enable them by default. Signed-off-by: Roy Li Signed-off-by: Martin Jansa Signed-off-by: Joe MacDonald --- ...ge-ksh-reference-in-krb-ldap-helper-to-sh.patch | 39 ------------ .../recipes-daemons/squid/squid_3.4.7.bb | 67 -------------------- .../recipes-daemons/squid/squid_3.5.7.bb | 73 ++++++++++++++++++++++ 3 files changed, 73 insertions(+), 106 deletions(-) delete mode 100644 meta-networking/recipes-daemons/squid/files/squid-change-ksh-reference-in-krb-ldap-helper-to-sh.patch delete mode 100644 meta-networking/recipes-daemons/squid/squid_3.4.7.bb create mode 100644 meta-networking/recipes-daemons/squid/squid_3.5.7.bb diff --git a/meta-networking/recipes-daemons/squid/files/squid-change-ksh-reference-in-krb-ldap-helper-to-sh.patch b/meta-networking/recipes-daemons/squid/files/squid-change-ksh-reference-in-krb-ldap-helper-to-sh.patch deleted file mode 100644 index 8e03860b3c..0000000000 --- a/meta-networking/recipes-daemons/squid/files/squid-change-ksh-reference-in-krb-ldap-helper-to-sh.patch +++ /dev/null @@ -1,39 +0,0 @@ -squid: change ksh reference in krb ldap helper to sh - -Very simple cert_tool script with no ksh specifics. -Change it to use sh so a package dependency doesn't -get created to ksh. - -Upstream-Status: Pending - -Signed-off-by: Jim Somerville -Signed-off-by: Chong Lu ---- - helpers/external_acl/kerberos_ldap_group/cert_tool | 6 +++--- - 1 file changed, 3 insertions(+), 3 deletions(-) - -diff --git a/helpers/external_acl/kerberos_ldap_group/cert_tool b/helpers/external_acl/kerberos_ldap_group/cert_tool -index 9f14959..8c4ea11 100644 ---- a/helpers/external_acl/kerberos_ldap_group/cert_tool -+++ b/helpers/external_acl/kerberos_ldap_group/cert_tool -@@ -1,4 +1,4 @@ --#!/bin/ksh -+#!/bin/sh - # - # ----------------------------------------------------------------------------- - # -@@ -64,9 +64,9 @@ QUIT - # Create database for Sun ldap and pem file for Openldap - # - rm ${server}_[0-9]*.pem 2>/dev/null --let i=0 -+i=0 - ls ${server}_[0-9]*.cert | while read file; do -- let i=i+1 -+ i=`expr $i + 1` - cat $file >> ${server}_$i.pem - CA=`openssl x509 -noout -text -in ${server}_$i.pem | grep -i "CA:.*true"` - if [ -n "$CA" ]; then --- -1.9.1 - diff --git a/meta-networking/recipes-daemons/squid/squid_3.4.7.bb b/meta-networking/recipes-daemons/squid/squid_3.4.7.bb deleted file mode 100644 index 7b00dfcef3..0000000000 --- a/meta-networking/recipes-daemons/squid/squid_3.4.7.bb +++ /dev/null @@ -1,67 +0,0 @@ -SUMMARY = "A fully-featured http proxy and web-cache daemon for Linux" -DESCRIPTION = "A fully-featured http proxy and web-cache daemon for Linux. \ -Squid offers a rich access control, authorization and logging environment to \ -develop web proxy and content serving applications. \ -Squid offers a rich set of traffic optimization options, most of which are \ -enabled by default for simpler installation and high performance. \ -" -HOMEPAGE = "http://www.squid-cache.org" -SECTION = "web" -LICENSE = "GPLv2+" - -MAJ_VER = "${@oe.utils.trim_version("${PV}", 1)}" -MIN_VER = "${@oe.utils.trim_version("${PV}", 2)}" - -SRC_URI = "http://www.squid-cache.org/Versions/v${MAJ_VER}/${MIN_VER}/${BPN}-${PV}.tar.bz2 \ - file://Set-up-for-cross-compilation.patch \ - file://Skip-AC_RUN_IFELSE-tests.patch \ - file://Fix-flawed-dynamic-ldb-link-test-in-configure.patch \ - file://squid-change-ksh-reference-in-krb-ldap-helper-to-sh.patch \ - file://squid-use-serial-tests-config-needed-by-ptest.patch \ - file://run-ptest \ - file://volatiles.03_squid \ -" - -LIC_FILES_CHKSUM = "file://COPYING;md5=c492e2d6d32ec5c1aad0e0609a141ce9 \ - file://COPYRIGHT;md5=2900f50789c498be8e9f1eb23b55cbe9 \ - " -SRC_URI[md5sum] = "9951034b10f7ee0f45a95cfae61c57c2" -SRC_URI[sha256sum] = "7b423f3d3495a317503ca559ea535f80445fd7c4e3c3e268cb7a8c97c61af2b6" - -DEPENDS = "libtool krb5 openldap db cyrus-sasl" - -inherit autotools useradd ptest - -USERADD_PACKAGES = "${PN}" -USERADD_PARAM_${PN} = "--system --no-create-home --home-dir /var/run/squid --shell /bin/false --user-group squid" - -PACKAGECONFIG ??= "" -PACKAGECONFIG[libnetfilter-conntrack] = "--with-netfilter-conntrack=${includedir}, --without-netfilter-conntrack, libnetfilter-conntrack" -EXTRA_OECONF += "--with-default-user=squid" - -TESTDIR = "test-suite" -do_compile_ptest() { - oe_runmake -C ${TESTDIR} buildtest-TESTS -} - -do_install_ptest() { - cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH} - cp -rf ${S}/${TESTDIR} ${D}${PTEST_PATH} - - # do NOT need to rebuild Makefile itself - sed -i 's/^Makefile:.*$/Makefile:/' ${D}${PTEST_PATH}/${TESTDIR}/Makefile -} - -do_install_append() { - install -d ${D}${sysconfdir}/default/volatiles - install -m 0644 ${WORKDIR}/volatiles.03_squid ${D}${sysconfdir}/default/volatiles/volatiles.03_squid - rmdir "${D}${localstatedir}/run/${BPN}" - rmdir --ignore-fail-on-non-empty "${D}${localstatedir}/run" -} - -FILES_${PN} += "${libdir} ${datadir}/errors ${datadir}/icons" -FILES_${PN}-dbg += "/usr/src/debug" -FILES_${PN}-doc += "${datadir}/*.txt" - -RDEPENDS_${PN} += "perl" -RDEPENDS_${PN}-ptest += "make" diff --git a/meta-networking/recipes-daemons/squid/squid_3.5.7.bb b/meta-networking/recipes-daemons/squid/squid_3.5.7.bb new file mode 100644 index 0000000000..5d058dc265 --- /dev/null +++ b/meta-networking/recipes-daemons/squid/squid_3.5.7.bb @@ -0,0 +1,73 @@ +SUMMARY = "A fully-featured http proxy and web-cache daemon for Linux" +DESCRIPTION = "A fully-featured http proxy and web-cache daemon for Linux. \ +Squid offers a rich access control, authorization and logging environment to \ +develop web proxy and content serving applications. \ +Squid offers a rich set of traffic optimization options, most of which are \ +enabled by default for simpler installation and high performance. \ +" +HOMEPAGE = "http://www.squid-cache.org" +SECTION = "web" +LICENSE = "GPLv2+" + +MAJ_VER = "${@oe.utils.trim_version("${PV}", 1)}" +MIN_VER = "${@oe.utils.trim_version("${PV}", 2)}" + +SRC_URI = "http://www.squid-cache.org/Versions/v${MAJ_VER}/${MIN_VER}/${BPN}-${PV}.tar.bz2 \ + file://Set-up-for-cross-compilation.patch \ + file://Skip-AC_RUN_IFELSE-tests.patch \ + file://Fix-flawed-dynamic-ldb-link-test-in-configure.patch \ + file://squid-use-serial-tests-config-needed-by-ptest.patch \ + file://run-ptest \ + file://volatiles.03_squid \ +" + +LIC_FILES_CHKSUM = "file://COPYING;md5=c492e2d6d32ec5c1aad0e0609a141ce9 \ + file://errors/COPYRIGHT;md5=0fed8f1462f6fdbc62bb431bcb618f46 \ + " +SRC_URI[md5sum] = "06e43abc67aedcc3903a2780de20a3ed" +SRC_URI[sha256sum] = "b7dcec8c5cb7f5687aff4256a7522f670c310a350cc9e9c0f29f3fd9cf88d017" + +DEPENDS = "libtool krb5 openldap db cyrus-sasl" + +inherit autotools useradd ptest + +USERADD_PACKAGES = "${PN}" +USERADD_PARAM_${PN} = "--system --no-create-home --home-dir /var/run/squid --shell /bin/false --user-group squid" + +PACKAGECONFIG ??= "" +PACKAGECONFIG[libnetfilter-conntrack] = "--with-netfilter-conntrack=${includedir}, --without-netfilter-conntrack, libnetfilter-conntrack" + +BASIC_AUTH = "DB SASL LDAP NIS" +DEPENDS += "${@base_contains('DISTRO_FEATURES', 'pam', 'libpam', '', d)}" +BASIC_AUTH += "${@base_contains('DISTRO_FEATURES', 'pam', 'PAM', '', d)}" + +EXTRA_OECONF += "--with-default-user=squid --enable-auth-basic='${BASIC_AUTH}'" +export BUILDCXXFLAGS="${BUILD_CXXFLAGS}" +CACHED_CONFIGUREVARS += "squid_cv_gnu_atomics=yes" + +TESTDIR = "test-suite" +do_compile_ptest() { + oe_runmake -C ${TESTDIR} buildtest-TESTS +} + +do_install_ptest() { + cp -rf ${B}/${TESTDIR} ${D}${PTEST_PATH} + cp -rf ${S}/${TESTDIR} ${D}${PTEST_PATH} + + # do NOT need to rebuild Makefile itself + sed -i 's/^Makefile:.*$/Makefile:/' ${D}${PTEST_PATH}/${TESTDIR}/Makefile +} + +do_install_append() { + install -d ${D}${sysconfdir}/default/volatiles + install -m 0644 ${WORKDIR}/volatiles.03_squid ${D}${sysconfdir}/default/volatiles/volatiles.03_squid + rmdir "${D}${localstatedir}/run/${BPN}" + rmdir --ignore-fail-on-non-empty "${D}${localstatedir}/run" +} + +FILES_${PN} += "${libdir} ${datadir}/errors ${datadir}/icons" +FILES_${PN}-dbg += "/usr/src/debug" +FILES_${PN}-doc += "${datadir}/*.txt" + +RDEPENDS_${PN} += "perl" +RDEPENDS_${PN}-ptest += "make" -- cgit 1.2.3-korg