From: Tom Wijsman <TomWij@gentoo.org>
To: gentoo-dev@lists.gentoo.org
Subject: Re: [gentoo-dev] cmake-utils.eclass and bug 475502
Date: Thu, 18 Jul 2013 01:09:43 +0200 [thread overview]
Message-ID: <20130718010943.1c46160f@TOMWIJ-GENTOO> (raw)
In-Reply-To: <51E70DEC.3060506@gentoo.org>
[-- Attachment #1: Type: text/plain, Size: 3175 bytes --]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Wed, 17 Jul 2013 23:34:36 +0200
hasufell <hasufell@gentoo.org> wrote:
> That means the methods for eclass changes must be more thoroughly.
So must the methods to write ebuilds be more thoroughly; therefore, I
think that we can somewhat build a script that checks this from an
ebuild perspective. If we optimize this and make it more perfect by
no false positives, more efficient code, caching; we might perhaps be
able to turn this into a QA check in the future. See the attachment; as
a demonstration of what I think, I quickly hacked something together:
$ time treecheck /usr/portage/dev-python/bsddb3/bsddb3-5.3.0.ebuild
distutils-r1_python_compile used
in /usr/portage/dev-python/bsddb3/bsddb3-5.3.0.ebuild, but eclass
distutils-r1 might be missing!
python_execute_function used
in /usr/portage/dev-python/bsddb3/bsddb3-5.3.0.ebuild, but eclass
python might be missing!
real 0m6.558s
user 0m3.482s
sys 0m3.096s
http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/dev-python/bsddb3/bsddb3-5.3.0.ebuild?revision=1.12&view=markup
Only 6 to 7 seconds to check an ebuild against 2000+ eclass functions!
For those interested in QA reports automation or some wicked IRC bot,
you can also run this against the whole tree by not passing an ebuild;
but at the moment, I consider this not well enough yet for that purpose.
I don't think the speed matters too much; given that the amount of
functions is limited and you don't need to run this too often, the
focus here should lie more on dealing with the false positives.
Another thing that comes to mind and shouldn't be hard to implement is
to give it an eclass, then have it just check the functions of that
eclass only across the tree; a matter of implementing a extension check
on $1 and depending on that fill in eclass_funcs or ebuilds.
To summarize it can benefit three groups of people:
1) A script (perhaps future QA check) to check for missing inherits.
2) A script for eclass maintainers to check for incorrect usage across
the three; can possible be extended to check situations were an
inherit is removed, give all cmake consumers with missing base inherit.
3) A script for QA people and reports to have an overview over the tree.
There is some potential here; so, I hope people are interested to help
contribute to or fork this piece of code into something more powerful.
- --
With kind regards,
Tom Wijsman (TomWij)
Gentoo Developer
E-mail address : TomWij@gentoo.org
GPG Public Key : 6D34E57D
GPG Fingerprint : C165 AF18 AB4C 400B C3D2 ABF0 95B2 1FCD 6D34 E57D
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (GNU/Linux)
iQEcBAEBAgAGBQJR5yQ6AAoJEJWyH81tNOV9/zoH/jp915kmOxBTasfyyRbWr1Na
/XCEw9u5EStWId6hirls1RII3xvqlMn2CZ0VZXC2x/ZZibQCB79ij6jw/lcnSKao
otFOy7h4Pp4zD6a8pofYW6DXMwBPESIVDKB3TT0g/BJtA84gX1hO2ApEYPmKZjGi
dTMSxLgr57rnmg6syIE1LYk/iaeZLTgfiLE5qdBGXFbbNDgWrBGi++y4s3s44jww
s44ZbKrPlIxwHfCvZd4px7hMUvym37p259kStfmU7eAzs88oXh9MqsffM48Z1Tt7
Mw2lHqlPQprjhgE3ikul/uMuKXFH2epfuGlV43tFUx4fsGiKr7E25lwqfGbjB4g=
=2RGb
-----END PGP SIGNATURE-----
[-- Attachment #2: treecheck.sh --]
[-- Type: application/x-shellscript, Size: 855 bytes --]
next prev parent reply other threads:[~2013-07-17 23:13 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-17 20:57 [gentoo-dev] cmake-utils.eclass and bug 475502 hasufell
2013-07-17 21:17 ` Chris Reffett
2013-07-17 21:28 ` Rick "Zero_Chaos" Farina
2013-07-17 21:34 ` hasufell
2013-07-17 21:42 ` Rick "Zero_Chaos" Farina
2013-07-17 21:47 ` hasufell
2013-07-17 21:55 ` Rick "Zero_Chaos" Farina
2013-07-17 22:15 ` hasufell
2013-07-18 7:06 ` Michał Górny
2013-07-18 22:11 ` Zac Medico
2013-07-17 23:09 ` Tom Wijsman [this message]
2013-07-18 16:40 ` Alexis Ballier
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=20130718010943.1c46160f@TOMWIJ-GENTOO \
--to=tomwij@gentoo.org \
--cc=gentoo-dev@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