public inbox for gentoo-java@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-java] QA checks in the eclass
@ 2007-03-03 20:36 Petteri Räty
  2007-03-03 21:15 ` Vlastimil Babka
  0 siblings, 1 reply; 3+ messages in thread
From: Petteri Räty @ 2007-03-03 20:36 UTC (permalink / raw
  To: gentoo-java


[-- Attachment #1.1: Type: text/plain, Size: 194 bytes --]

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

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: java-qa-checks.patch --]
[-- Type: text/x-patch; name="java-qa-checks.patch", Size: 1522 bytes --]

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"
+	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
 }

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 252 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2007-03-03 21:29 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-03-03 20:36 [gentoo-java] QA checks in the eclass Petteri Räty
2007-03-03 21:15 ` Vlastimil Babka
2007-03-03 21:18   ` Petteri Räty

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox