Re: Linux 2.6.0-test6

From: Chris Friesen (cfriesen_at_nortelnetworks.com)
Date: 09/29/03

  • Next message: Vojtech Pavlik: "Re: keyboard repeat / sound [was Re: Linux 2.6.0-test6]"
    Date:	Mon, 29 Sep 2003 11:08:25 -0400
    To: Russell King <rmk@arm.linux.org.uk>
    
    

    Russell King wrote:

    > If a header has something like these:
    >
    > struct my_headers_struct {
    > struct task_struct *tsk;
    > };
    >
    > void my_function(struct task_struct *tsk);
    >
    > and gcc warns that "struct task_struct" has not been declared, please
    > don't think about adding another header. Just declare the structure
    > in the header file which needs it like this:
    >
    > struct task_struct;

    If I do that, make a change to task_struct, then run make, will the file
    get rebuilt?

    Chris

    -- 
    Chris Friesen                    | MailStop: 043/33/F10
    Nortel Networks                  | work: (613) 765-0557
    3500 Carling Avenue              | fax:  (613) 765-2986
    Nepean, ON K2H 8E9 Canada        | email: cfriesen@nortelnetworks.com
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at  http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at  http://www.tux.org/lkml/
    

  • Next message: Vojtech Pavlik: "Re: keyboard repeat / sound [was Re: Linux 2.6.0-test6]"

    Relevant Pages

    • Re: Linux 2.6.0-test6
      ... and gcc warns that "struct task_struct" has not been declared, ... Just declare the structure ... everything being rebuilt just because one header file was touched. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: Linux 2.6.0-test6
      ... >> don't think about adding another header. ... Just declare the structure ... the right header file anyway. ... send the line "unsubscribe linux-kernel" in ...
      (Linux-Kernel)
    • Re: Exported function mangaled name
      ... that header file; it must be declared as __declspec ... You have to declare the function the same way in your .cpp file as in ... #define LIBSPEC __declspec ... See my essay on The Ultimate DLL Header File on my MVP Tips site. ...
      (microsoft.public.vc.mfc)
    • Re: make general windows module
      ... The VB version of these declarations is the "Declare Statement". ... mimicing the behavior of a "windows.h" header file for VB. ... not all Windows API calls can be called from VB as some use reference ...
      (microsoft.public.vb.general.discussion)
    • Re: confused about extern use
      ... going to achieve by declaring it as extern in the header file a.h. ... composed on one or more compilation units. ... Essentially you *declare* the type wherever it is ...
      (comp.lang.c)

    Loading