From: Vlastimil Babka <caster@gentoo.org>
To: gentoo-java@lists.gentoo.org
Subject: Re: [gentoo-java] QA checks in the eclass
Date: Sat, 03 Mar 2007 22:15:54 +0100 [thread overview]
Message-ID: <45E9E58A.9020108@gentoo.org> (raw)
In-Reply-To: <45E9DC52.7050408@gentoo.org>
Petteri Räty wrote:
> Added some QA checks and changed java-pkg_announce-qa-violation to use
> ewarn to make it show better. Any objections? Will commit sometimes next
> week if there aren't any.
>
> Regards,
> Petteri
>
> Index: java-utils-2.eclass
> ===================================================================
> RCS file: /var/cvsroot/gentoo-x86/eclass/java-utils-2.eclass,v
> retrieving revision 1.63
> diff -u -r1.63 java-utils-2.eclass
> --- java-utils-2.eclass 3 Mar 2007 20:37:35 -0000 1.63
> +++ java-utils-2.eclass 3 Mar 2007 20:44:45 -0000
> @@ -205,6 +205,10 @@
>
> java-pkg_check-phase install
>
> + if ! hasq source ${IUSE}; then
> + java-pkg_announce-qa-violation "${FUNCNAME} called without source in IUSE"
s/source/examples?
> + fi
> +
> local dest=/usr/share/doc/${PF}/examples
> if [[ ${#} = 1 && -d ${1} ]]; then
> INSDESTTREE="${dest}" doins -r ${1}/* || die "Installing examples failed"
> @@ -550,6 +554,10 @@
>
> java-pkg_check-phase install
>
> + if ! hasq doc ${IUSE}; then
> + java-pkg_announce-qa-violation "${FUNCNAME} called without doc in IUSE"
> + fi
> +
> [[ -z "${dir}" ]] && die "Must specify a directory!"
> [[ ! -d "${dir}" ]] && die "${dir} does not exist, or isn't a directory!"
>
> @@ -586,8 +594,9 @@
> debug-print-function ${FUNCNAME} $*
>
> [ ${#} -lt 1 ] && die "At least one argument needed"
> +
> if ! hasq source ${IUSE}; then
> - echo "Java QA Notice: ${FUNCNAME} called without source in IUSE"
> + java-pkg_announce-qa-violation "${FUNCNAME} called without source in IUSE"
> fi
>
> java-pkg_check-phase install
> @@ -2323,7 +2332,7 @@
>
> java-pkg_announce-qa-violation() {
> if is-java-strict; then
> - echo "Java QA Notice: $@" >&2
> + ewarn "Java QA Notice: $@"
> increment-qa-violations
> fi
> }
Also, when it checks foo is in IUSE, why not check "use foo" as well?
Heck, why don't even change the functions so they only perform their
stuff when "use foo" holds (this way you get a free QA check for IUSE
right in useq()), and get rid of the "use foo && java-pkg_dofoo" idiom?
:) If we agree we *ALWAYS* want to install this javadocs/source/ always
based on flags (maybe there could be some nocheck variants if needed).
Or what's the reasoning behind these checks? If you do a "use doc &&
java_pkg-dojavadoc" without doc in IUSE, you will already get warned by
usev(). If you omit the "use doc", then how does it matter that doc is
or isn't in IUSE?
--
Vlastimil Babka (Caster)
Gentoo/Java
--
gentoo-java@gentoo.org mailing list
next prev parent reply other threads:[~2007-03-03 21:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-03 20:36 [gentoo-java] QA checks in the eclass Petteri Räty
2007-03-03 21:15 ` Vlastimil Babka [this message]
2007-03-03 21:18 ` Petteri Räty
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=45E9E58A.9020108@gentoo.org \
--to=caster@gentoo.org \
--cc=gentoo-java@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox