Re: [systemd-devel] Removing unnecessary includes

2015-02-23 Thread Thomas H.P. Andersen
On Mon, Feb 23, 2015 at 2:02 PM, Lennart Poettering wrote: > On Sun, 22.02.15 14:56, Thomas H.P. Andersen (pho...@gmail.com) wrote: > >> > For info I am attaching a diff with the changes so far: 1309 includes >> > removed out of the current 7707. It is only compile and "make >> > check"-tested. I

Re: [systemd-devel] Removing unnecessary includes

2015-02-23 Thread Lennart Poettering
On Sun, 22.02.15 14:56, Thomas H.P. Andersen (pho...@gmail.com) wrote: > > For info I am attaching a diff with the changes so far: 1309 includes > > removed out of the current 7707. It is only compile and "make > > check"-tested. I am only looking for comments (and perhaps compile > > testing on a

Re: [systemd-devel] Removing unnecessary includes

2015-02-22 Thread Thomas H.P. Andersen
On Sun, Feb 15, 2015 at 11:53 PM, Thomas H.P. Andersen wrote: > On Tue, Feb 10, 2015 at 10:05 PM, Lennart Poettering > wrote: >> On Sat, 07.02.15 10:29, Thomas H.P. Andersen (pho...@gmail.com) wrote: >> >>> Hi, >>> >>> I am looking at ways to automatically trim the unnecessary includes. >>> One w

Re: [systemd-devel] Removing unnecessary includes

2015-02-12 Thread Lennart Poettering
On Wed, 11.02.15 23:46, Thomas H.P. Andersen (pho...@gmail.com) wrote: > On Wed, Feb 11, 2015 at 12:39 PM, Lennart Poettering > wrote: > > On Wed, 11.02.15 01:40, Thomas H.P. Andersen (pho...@gmail.com) wrote: > > > >> Yep. Makes sense. > >> > >> Here is a status on what I have done so far. > >>

Re: [systemd-devel] Removing unnecessary includes

2015-02-11 Thread Zbigniew Jędrzejewski-Szmek
On Wed, Feb 11, 2015 at 11:46:37PM +0100, Thomas H.P. Andersen wrote: > On Wed, Feb 11, 2015 at 12:39 PM, Lennart Poettering > wrote: > > On Wed, 11.02.15 01:40, Thomas H.P. Andersen (pho...@gmail.com) wrote: > > > >> Yep. Makes sense. > >> > >> Here is a status on what I have done so far. > >> >

Re: [systemd-devel] Removing unnecessary includes

2015-02-11 Thread Thomas H.P. Andersen
On Wed, Feb 11, 2015 at 12:39 PM, Lennart Poettering wrote: > On Wed, 11.02.15 01:40, Thomas H.P. Andersen (pho...@gmail.com) wrote: > >> Yep. Makes sense. >> >> Here is a status on what I have done so far. >> >> include-what-you-want does the following: >> 1) sorts the includes >> 2) adds missing

Re: [systemd-devel] Removing unnecessary includes

2015-02-11 Thread Lennart Poettering
On Wed, 11.02.15 01:40, Thomas H.P. Andersen (pho...@gmail.com) wrote: > Yep. Makes sense. > > Here is a status on what I have done so far. > > include-what-you-want does the following: > 1) sorts the includes > 2) adds missing headers for any symbols used > 3) adds forward declarations > 4) rem

Re: [systemd-devel] Removing unnecessary includes

2015-02-10 Thread Thomas H.P. Andersen
On Tue, Feb 10, 2015 at 10:13 PM, Lennart Poettering wrote: > On Mon, 09.02.15 10:19, Thomas H.P. Andersen (pho...@gmail.com) wrote: > >> include-what-you-use is actually pretty nice. It is also a little bit >> crazy. It wants to include everything directly and we would add a lot >> includes for e

Re: [systemd-devel] Removing unnecessary includes

2015-02-10 Thread Lennart Poettering
On Mon, 09.02.15 10:19, Thomas H.P. Andersen (pho...@gmail.com) wrote: > include-what-you-use is actually pretty nice. It is also a little bit > crazy. It wants to include everything directly and we would add a lot > includes for errno.h, string.h, stdlib.h, stdbool.h, stddef.h, etc etc > everywhe

Re: [systemd-devel] Removing unnecessary includes

2015-02-10 Thread Lennart Poettering
On Sat, 07.02.15 10:29, Thomas H.P. Andersen (pho...@gmail.com) wrote: > Hi, > > I am looking at ways to automatically trim the unnecessary includes. > One way to do it is a script[1] which simply tests if the compile > still works after removing each include one at a time. It does this in > reve

Re: [systemd-devel] Removing unnecessary includes

2015-02-09 Thread Thomas H.P. Andersen
On Sat, Feb 7, 2015 at 3:38 PM, Thomas H.P. Andersen wrote: > On Sat, Feb 7, 2015 at 2:37 PM, Ronny Chevalier > wrote: >> 2015-02-07 14:05 GMT+01:00 Daniele Nicolodi : >>> On 07/02/15 10:29, Thomas H.P. Andersen wrote: I am looking at ways to automatically trim the unnecessary includes.

Re: [systemd-devel] Removing unnecessary includes

2015-02-07 Thread Thomas H.P. Andersen
On Sat, Feb 7, 2015 at 2:37 PM, Ronny Chevalier wrote: > 2015-02-07 14:05 GMT+01:00 Daniele Nicolodi : >> On 07/02/15 10:29, Thomas H.P. Andersen wrote: >>> I am looking at ways to automatically trim the unnecessary includes. >>> One way to do it is a script[1] which simply tests if the compile >>

Re: [systemd-devel] Removing unnecessary includes

2015-02-07 Thread Thomas H.P. Andersen
On Sat, Feb 7, 2015 at 2:05 PM, Daniele Nicolodi wrote: > On 07/02/15 10:29, Thomas H.P. Andersen wrote: >> I am looking at ways to automatically trim the unnecessary includes. >> One way to do it is a script[1] which simply tests if the compile >> still works after removing each include one at a

Re: [systemd-devel] Removing unnecessary includes

2015-02-07 Thread Ronny Chevalier
2015-02-07 14:05 GMT+01:00 Daniele Nicolodi : > On 07/02/15 10:29, Thomas H.P. Andersen wrote: >> I am looking at ways to automatically trim the unnecessary includes. >> One way to do it is a script[1] which simply tests if the compile >> still works after removing each include one at a time. It do

Re: [systemd-devel] Removing unnecessary includes

2015-02-07 Thread Daniele Nicolodi
On 07/02/15 10:29, Thomas H.P. Andersen wrote: > I am looking at ways to automatically trim the unnecessary includes. > One way to do it is a script[1] which simply tests if the compile > still works after removing each include one at a time. It does this in > reverse order for all includes in the

[systemd-devel] Removing unnecessary includes

2015-02-07 Thread Thomas H.P. Andersen
Hi, I am looking at ways to automatically trim the unnecessary includes. One way to do it is a script[1] which simply tests if the compile still works after removing each include one at a time. It does this in reverse order for all includes in the .c files. Using -Werror we catch any new warnings