FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian GCC

 
 
LinkBack Thread Tools
 
Old 11-25-2011, 11:14 PM
Jonathan Nieder
 
Default Suggested buildd log check

Hi,

You wrote[1]:

> If you have ideas for warnings/diagnostics visibile in buildd logs
> that are worth having listed in a view like that, please let me
> know.

I'm not sure how your infrastructure copes with something like this,
but I would find it useful to have gcc 4.6's machine-parsable warnings
in such a list. They look like this:

../../src/gcc/graphite.c:59:29: warning: non-local variable 'cloog_pointers__' with anonymous type is questionable in C++ [-Wc++-compat]

I guess a regex like "[-W[-+=a-z0-9]*]" would do, plus
"[-pedantic]" and "[-fpermissive]"..

I suppose these could all be lumped as one diagnostic type, except
that when new gcc releases introduce new warnings (like the recent
-Wunused-but-set-variable and -Wunused-but-set-parameter), they could
get a different tag. What do you think?

Thanks very much for this work,
Jonathan

[1] https://buildd.debian.org/~brlink/


--
To UNSUBSCRIBE, email to debian-gcc-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20111126001453.GB12853@elie.hsd1.il.comcast.net">h ttp://lists.debian.org/20111126001453.GB12853@elie.hsd1.il.comcast.net
 
Old 11-26-2011, 01:50 PM
Matthias Klose
 
Default Suggested buildd log check

On 11/26/2011 01:14 AM, Jonathan Nieder wrote:
> Hi,
>
> You wrote[1]:
>
>> If you have ideas for warnings/diagnostics visibile in buildd logs
>> that are worth having listed in a view like that, please let me
>> know.
>
> I'm not sure how your infrastructure copes with something like this,
> but I would find it useful to have gcc 4.6's machine-parsable warnings
> in such a list. They look like this:
>
> ../../src/gcc/graphite.c:59:29: warning: non-local variable 'cloog_pointers__' with anonymous type is questionable in C++ [-Wc++-compat]
>
> I guess a regex like "[-W[-+=a-z0-9]*]" would do, plus
> "[-pedantic]" and "[-fpermissive]"..
>
> I suppose these could all be lumped as one diagnostic type, except
> that when new gcc releases introduce new warnings (like the recent
> -Wunused-but-set-variable and -Wunused-but-set-parameter), they could
> get a different tag. What do you think?
>
> Thanks very much for this work,
> Jonathan
>
> [1] https://buildd.debian.org/~brlink/

The first issue with this kind of approach is that not all build logs are
verbose by default. So a first step would be to decide if you have a verbose
build log, or some quiet mess, and submit bug reports for the latter (there is a
lintian report for this, although the lintian maintainers think this is not the
right place).

It would be good not to limit this to warnings only. Another use case is the
check if build flags are really passed to the upstream build system; this seems
to be a requisite to the hardening release goal, because you generally can't see
for every object in the resulting binary if it was built with or without
hardening defaults.

So, a more general approach might be more useful in terms for the wheezy release.

Matthias


--
To UNSUBSCRIBE, email to debian-gcc-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 4ED0FCB6.7080302@debian.org">http://lists.debian.org/4ED0FCB6.7080302@debian.org
 
Old 11-26-2011, 02:01 PM
"Bernhard R. Link"
 
Default Suggested buildd log check

* Jonathan Nieder <jrnieder@gmail.com> [111126 01:15]:
> > If you have ideas for warnings/diagnostics visibile in buildd logs
> > that are worth having listed in a view like that, please let me
> > know.
>
> I'm not sure how your infrastructure copes with something like this,
> but I would find it useful to have gcc 4.6's machine-parsable warnings
> in such a list. They look like this:
>
> ../../src/gcc/graphite.c:59:29: warning: non-local variable 'cloog_pointers__' with anonymous type is questionable in C++ [-Wc++-compat]
>
> I guess a regex like "[-W[-+=a-z0-9]*]" would do, plus
> "[-pedantic]" and "[-fpermissive]"..
>
> I suppose these could all be lumped as one diagnostic type, except
> that when new gcc releases introduce new warnings (like the recent
> -Wunused-but-set-variable and -Wunused-but-set-parameter), they could
> get a different tag. What do you think?

While this could be extracted, I'm not sure it makes that much sense.

Few packages are totally warning free and some are quite harmless, to
it could distract to have too much information. (it could be info and
not error and warning, but it still might not have that much
information).

Also the logs are usually done with very different compiler versions.
Having packages in unstable with the last log two years old is not that
uncommon.

I definitely plan to add information pages for any dangerous warnings
(currently a global rescan also looking for "warning: assignment makes
pointer from integer without a cast" is running), and I'd love to get
hints for other interesting warnings like those to add to that list.

I can also gather more information, but would like to see some idea what
to actually do with that vast amount of information.

Bernhard R. Link


--
To UNSUBSCRIBE, email to debian-gcc-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20111126150123.GA14474@server.brlink.eu">http://lists.debian.org/20111126150123.GA14474@server.brlink.eu
 
Old 11-26-2011, 02:18 PM
"Bernhard R. Link"
 
Default Suggested buildd log check

* Matthias Klose <doko@debian.org> [111126 15:50]:
> It would be good not to limit this to warnings only. Another use case is the
> check if build flags are really passed to the upstream build system; this seems
> to be a requisite to the hardening release goal, because you generally can't see
> for every object in the resulting binary if it was built with or without
> hardening defaults.

This was already on my TODO list, but not near the top. So if
anyone has some ideas or wants to write some little checkscript to look
for those that would very much be appreciated.

I guess one needs:

- some checks to look for builds hiding compiler options
(as that makes detecting which build flags impossible and
also means porters have it much harder to investigate stuff)

- some way to find out which buildflags the package got if it asked.
(version of dpkg-buildflags exporting those also printed them.
Currently there is no such information in the log. One might guess
them from looking what dpkg-dev version was installed, but I guess
it might be best to have dpkg-buildpackage print them and that
information extracted).

- some way to identify command lines calling a compiler. gcc can be
called as cc, gcc, or something like i486-gnu-gcc. (similar for g++).

Bernhard R. Link

P.S: I guess the discussion left the topic of this mailing list. Any
better to switch to?


--
To UNSUBSCRIBE, email to debian-gcc-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: 20111126151840.GB14474@server.brlink.eu">http://lists.debian.org/20111126151840.GB14474@server.brlink.eu
 

Thread Tools




All times are GMT. The time now is 07:49 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org