[Top] [All Lists]

Re: XFS removal of #define STATIC static

To: fdavis@xxxxxxxxx
Subject: Re: XFS removal of #define STATIC static
From: Keith Owens <kaos@xxxxxxx>
Date: Wed, 23 Oct 2002 13:56:17 +1000
Cc: linux-xfs@xxxxxxxxxxx
In-reply-to: Your message of "22 Oct 2002 22:09:28 EST." <1035342569.1086.39.camel@xxxxxxxxxxxxxxxxxxxxxxx>
Sender: linux-xfs-bounce@xxxxxxxxxxx
On 22 Oct 2002 22:09:28 -0500, 
Stephen Lord <lord@xxxxxxx> wrote:
>On Tue, 2002-10-22 at 22:02, Frank Davis wrote:
>> Hello all,
>>     Per a recent email on linux-kernel@xxxxxxxxxxxxxxx, Alan Cox stated 
>> that
>> #define STATIC static
>> is outdated (no longer used). As a result, I've removed references to 
>> the outdated macro in all files except for XFS (defined in 
>> fs/xfs/linux/xfs_linux.h) within the 2.5.44-ac1 kernel. Would it be 
>> possible for the XFS team to also remove this outdated macro? Thanks.
>The only reason I can think of needing this is for symbol tables
>in debuggers - and trying to keep some semblance of the same
>code base between Irix and Linux. Not sure if we really have
>a debugger setup on linux where being able to turn off static
>helps to be honest, does a gdb symbol table include static

kdb has no problems with static functions.  gdb has static functions in
its symbol tables, but debugging (or disassembling) static inline
functions with gdb is unreliable.  There have been a few times when I
have compiled with -DSTATIC= to get a decent disassembly under gdb.
OTOH, it is just as easy to manually remove static from the individual
function you are looking at.

>Unless someone is feeling bored and wants to knock up a sed script
>I am not sure this will happen, but I don't really have an objection
>beyond the above.

p_modify $(fgrep -rwl STATIC fs/xfs/)
perl -i -lpe 's/\bSTATIC\b/static/g;' $(fgrep -rwl STATIC fs/xfs/)
Hand edit fs/xfs/pagebuf/{page_buf_internal.h,xfs_linux.h},
fs/xfs/Makefile, fs/xfs/linux/Makefile, fs/xfs/pagebuf/Makefile


<Prev in Thread] Current Thread [Next in Thread>