[libvirt] [PATCH] build: exclude more files from all the syntax checks
Pino Toscano
ptoscano at redhat.com
Fri Oct 6 12:56:40 UTC 2017
On Friday, 6 October 2017 12:32:28 CEST Michal Privoznik wrote:
> On 10/05/2017 01:07 PM, Pino Toscano wrote:
> > The majority of the syntax check is taylored for C sources, so some of
> > the checks already cause false positives for non-C sources (and thus
> > there are exclusion regexps in place).
> >
> > Instead, just exclude more non-C files from all the checks:
> > - pot files: they are templates for po files (already excluded), and
> > they are automatically generated from sources
> > - pl files: Perl sources, which have own APIs, style, etc; they are
> > helper scripts, not "real" sources
> > - spec/spec.in files: RPM packaging files
> > - js/woff/html.in files: files for web pages
> > - diff/patch files: patches
> > - stp files: SystemTap scripts
> > - syms files: linker symbols files
> > - conf files: generic configuration files
> > - data/cpuinfo files: procinfo/cpuinfo files
> >
> > Python files (.py) are left allowed, since there is at least one syntax
> > check specifically for them.
> >
> > Signed-off-by: Pino Toscano <ptoscano at redhat.com>
> > ---
> > cfg.mk | 29 +++++++++++++----------------
> > 1 file changed, 13 insertions(+), 16 deletions(-)
> >
> > diff --git a/cfg.mk b/cfg.mk
> > index 0f4065b98..44a19594e 100644
> > --- a/cfg.mk
> > +++ b/cfg.mk
> > @@ -91,7 +91,7 @@ endif
> >
> > # Files that should never cause syntax check failures.
> > VC_LIST_ALWAYS_EXCLUDE_REGEX = \
> > - (^(docs/(news(-[0-9]*)?\.html\.in|.*\.patch))|\.(po|fig|gif|ico|png))$$
> > + \.(po|fig|gif|ico|png|pot|pl|spec|spec\.in|js|woff|diff|patch|html\.in|stp|syms|conf|data|cpuinfo)$$
>
> .spec is not in the repo, so it's never checked. And then, we perhaps
> want to check .spec.in? For instance for space at EOF.
.spec is generated from .spec.in, so for a builddir==srcdir build,
syntax-check will find both; hence, IMHO both ought to be either
skipped or checked, but together.
Jirka, you are the one working on the packaging side: what do you think
about the changes above (at least from the .spec point of view)?
Thanks,
--
Pino Toscano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part.
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20171006/36210c31/attachment-0001.sig>
More information about the libvir-list
mailing list