Hi,

 I'm compiling my project on C language using the following Makefile:

------- cut here -------------------------------
bbs : autenticacao.o idioma.o menus.o extrainfo.o
        gcc -lcrypt -lcurses -o bbs menus.o autenticacao.o idioma.o \
               extrainfo.o bbs.c

idioma.o :
        gcc -c idioma.c

autenticacao.o :
        gcc -c autenticacao.c

extrainfo.o :
        gcc -c extrainfo.c

menus.o : 
        gcc -c menus.c
clean : 
        rm -f *.o *.core
------------ cut here -------------------------

 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! 


 Even getting this warning I can compile my project! ;) Meanwhile it
appears an error that I can't resolve it! :-(

 bbs.c is the main file and I need to call a function(main_menu()) on
menus.c !

 on menu.c i've an idiom's variable declared as:

  char idiom[10];

 and main_menu() function from menu.c it's: 

    main_menu(int client_desc, char *idiom )  

  My problem is that when I call main_menu(client, idiom)(menus.c) from
bbs.c(main file) and send idiom char array as second argument, main_menu()
function get garbage on idiom variable and so don't get my string !:(((
  It's not sending my variable value ! :-( Or if it's it will erase it and
copy into that trash.

 What could it be !?

 Sorry about some confusion.

 Any help will be nice.

 Best regards,
   Nuno Carvalho


������������������������������
   Nuno Emanuel F. Carvalho
 Dep. Informatics Engineering
    University of Coimbra

  PGP key available at finger
������������������������������

Reply via email to