From owner-svn-ports-all@freebsd.org Sat Oct 29 10:39:40 2016 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6A82EC26569; Sat, 29 Oct 2016 10:39:40 +0000 (UTC) (envelope-from andrej.zverev@gmail.com) Received: from mail-lf0-x232.google.com (mail-lf0-x232.google.com [IPv6:2a00:1450:4010:c07::232]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id CD6D8F2C; Sat, 29 Oct 2016 10:39:39 +0000 (UTC) (envelope-from andrej.zverev@gmail.com) Received: by mail-lf0-x232.google.com with SMTP id b81so73185524lfe.1; Sat, 29 Oct 2016 03:39:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=VqR+7VvTYy442ZKVE9Hn/Wx4GlOzgPcMar2SquoBudM=; b=opAnj9gP/pafHCYWZHVXhEv67TIkNwVAnqN8NrcTYTfCFNIbtY+eEIdVgGJxKrU50Y YY1UghPhormwBgVwsndiNovj4qRARg/MJ2yLt2WkcEo6eLk+y2dTV+x0A5TK74jSFKbe 6actzUOp9UMQTh0dZ/7msA8fsT9KGzU0k/eu1gZtobGJ39Ju8VnfxTd5IePr5JtesDAO zNcn2tAwjbc/FxW/PJi0NfcS/uDqSKuqK/sSITkSSt9+MUP7UbB5bzrxJcZ0QGq+uK7D NcNX7RzxN0+g+L+jOT2ZRqT/ox9otqxKaC4nG8ZlmKUyPcp3Q18fec356rDIiGG9DbUj QB1Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=VqR+7VvTYy442ZKVE9Hn/Wx4GlOzgPcMar2SquoBudM=; b=WNeWgGb+V/3nJ9ufhCmDD01/50//An+X5W282+b1YsULd7TlwUhb5SWL3qmmx8mhsc 1P1mSup0qXjxGE9rpMu9Mb3yZGUlgblOgs+G1CWJMNN8iLF9eyMaelkVtcdoZcLFlgm8 4QlCYdHVaYTN9BHyyKlL+HVMfQBRmqVHUBjUc8Y8P4ZS62l1k2gbhEUKEYCcWvGk3kS6 6B5ZVfXq/ZZESi/Xw92IYTp5iAH9xohEfmLmm8/3p90Pg8X+9Boeg+FMIe2/EFYGXYMc FR81lPtuwckvw9rAr6Cyu9gQq8zP//C24Xh7DJyqyXSDHTEXhfW/Q/bFIC3uks8DQ60g TaHA== X-Gm-Message-State: ABUngvfPD0DZMuYF3qhtj/Z01oBvw0VsU8w5N7+Xbp2LdGGvwLAzpKzsied3COANOBrS4Mptsg7k3M5U/isNpQ== X-Received: by 10.25.35.6 with SMTP id j6mr11314874lfj.137.1477737577589; Sat, 29 Oct 2016 03:39:37 -0700 (PDT) MIME-Version: 1.0 Received: by 10.25.125.138 with HTTP; Sat, 29 Oct 2016 03:39:36 -0700 (PDT) In-Reply-To: <201610291010.u9TAAXAW028570@repo.freebsd.org> References: <201610291010.u9TAAXAW028570@repo.freebsd.org> From: Andrej Zverev Date: Sat, 29 Oct 2016 13:39:36 +0300 Message-ID: Subject: Re: svn commit: r424899 - in head/Mk: . Scripts To: Mathieu Arnold Cc: "ports-committers@freebsd.org" , "svn-ports-all@freebsd.org" , "svn-ports-head@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 29 Oct 2016 10:39:40 -0000 Nice! Thank you. On Sat, Oct 29, 2016 at 1:10 PM, Mathieu Arnold wrote: > Author: mat > Date: Sat Oct 29 10:10:33 2016 > New Revision: 424899 > URL: https://svnweb.freebsd.org/changeset/ports/424899 > > Log: > Add a Perl CORE QA check. > > This will use Module::CoreList to tell you if a dependency you added can > be removed, or only conditionally added. > > Approved by: bapt > Sponsored by: Absolight > Differential Revision: https://reviews.freebsd.org/D7832 > > Modified: > head/Mk/Scripts/qa.sh (contents, props changed) > head/Mk/bsd.port.mk (contents, props changed) > > Modified: head/Mk/Scripts/qa.sh > ============================================================ > ================== > --- head/Mk/Scripts/qa.sh Sat Oct 29 09:30:14 2016 (r424898) > +++ head/Mk/Scripts/qa.sh Sat Oct 29 10:10:33 2016 (r424899) > @@ -12,6 +12,10 @@ fi > LF=$(printf '\nX') > LF=${LF%X} > > +notice() { > + echo "Notice: $@" >&2 > +} > + > warn() { > echo "Warning: $@" >&2 > } > @@ -703,9 +707,53 @@ sonames() { > EOT > } > > +perlcore() { > + local portname version module gotsome > + [ -x "${LOCALBASE}/bin/corelist" ] || return 0 > + for dep in ${UNIFIED_DEPENDS}; do > + portname=$(expr "${dep}" : ".*/p5-\(.*\)") > + if [ -n "${portname}" ]; then > + gotsome=1 > + module=$(echo ${portname}|sed -e 's/-/::/g') > + version=$(expr "${dep}" : ".*>=*\([^:<]*\)") > + > + while read l; do > + case "${l}" in > + *was\ not\ in\ CORE*) > + # This never was with Perl > + # CORE, so nothing to do > here > + ;; > + *and\ removed*) > + # This was in Perl CORE > but has > + # been removed since. > + warn "${dep##*:} was in > Perl CORE. Check with \`corelist ${module} ${version}\` and \`corelist -a > ${module}\` if it should be conditionally added depending on PERL_LEVEL" > + ;; > + *deprecated*in*) > + # This is in Perl CORE but > is > + # deprecated. > + warn "${dep##*:} is in > Perl CORE but deprecated. Check with \`corelist ${module} ${version}\` and > \`corelist -a ${module}\` if the dependency is really needed or if it > should be conditionally added depending on PERL_LEVEL" > + ;; > + *was\ first\ released*) > + # This is in Perl CORE and > is > + # maybe not needed. > + warn "${dep##*:} is > present in Perl CORE. Check with \`corelist ${module} ${version}\` and > \`corelist -a ${module}\` if the dependency is really needed or if it > should be conditionally added depending on PERL_LEVEL" > + ;; > + *) > + err "This line is not > handled: \"${l}\"" > + esac > + done <<-EOT > + $(${LOCALBASE}/bin/corelist "${module}"|tail -1) > + EOT > + fi > + done > + if [ -n "${gotsome}" ] && ! pkg info -e devel/p5-Module-CoreList; > then > + notice "You have some Perl modules as dependencies but you > do not have devel/p5-Module-CoreList installed, the perlcore QA check gets > better results when using it, especially with older Perl versions." > + fi > +} > + > checks="shebang symlinks paths stripped desktopfileutils sharedmimeinfo" > checks="$checks suidfiles libtool libperl prefixvar baselibs terminfo" > -checks="$checks proxydeps sonames" > +checks="$checks proxydeps sonames perlcore" > > ret=0 > cd ${STAGEDIR} > > Modified: head/Mk/bsd.port.mk > ============================================================ > ================== > --- head/Mk/bsd.port.mk Sat Oct 29 09:30:14 2016 (r424898) > +++ head/Mk/bsd.port.mk Sat Oct 29 10:10:33 2016 (r424899) > @@ -1492,6 +1492,7 @@ QA_ENV+= STAGEDIR=${STAGEDIR} \ > LDCONFIG_DIR="${LDCONFIG_DIR}" \ > PKGORIGIN=${PKGORIGIN} \ > LIB_RUN_DEPENDS='${_LIB_RUN_ > DEPENDS:C,[^:]*:([^:]*):?.*,\1,}' \ > + UNIFIED_DEPENDS=${_UNIFIED_ > DEPENDS:C,([^:]*:[^:]*):?.*,\1,:O:u:Q} \ > PKGBASE=${PKGBASE} > .if !empty(USES:Mssl) > QA_ENV+= USESSSL=yes > >