[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Problem from compiler !?



On Sun, Dec 27, 1998 at 04:30:49AM +0000, Nuno Carvalho wrote:
>  Meanwhile when i try to compile it i've that:
>  
> ---- cut here -------------
> nemanuel@cavern:~/bbs$ make
> gcc -c autenticacao.c
> gcc -c idioma.c
> gcc -c menus.c
> gcc -c extrainfo.c
> gcc -lcrypt -lcurses -o bbs menus.o autenticacao.o idioma.o extrainfo.o
> bbs.c
> bbs.c:29: warning: `ficheiros_BBS' initialized and declared `extern'
> nemanuel@cavern:~/bbs$ 
> ------cut here -------------
> 
>  Could someone tell me how can I remove that warning !?
>  ficheiros_BBS's variable it's defined on bbs.c file as:
> extern char *ficheiros_BBS[] = {"/in/login", "in/logout", "in/register" };
>  .... and I need to declare it! 

"extern" means that it is declared somewhere else; all you have said
here is that it exists elsewhere, ie it is created elsewhere. You should
provide the initialisation values (the part after the equals) where
you declare it. Probably, you just want to lose the "extern".


Hamish
-- 
Hamish Moffatt VK3TYD              hamish@debian.org, hamish@rising.com.au
Latest Debian packages at ftp://ftp.rising.com.au/pub/hamish. PGP#EFA6B9D5
CCs of replies from mailing lists are welcome.   http://hamish.home.ml.org


Reply to: