switching from 1.7 to 1.8

Posted by Orik on Sun 15 Jul 2007 03:18 AM — 5 posts, 22,535 views.

USA #0
I've been switching things from 1.7 to 1.8 because of all the new fun stuff. I've got all the files to compile but at the very end I get errors from the o files. Here's a sample:



o/act_comm.o: In function `_Z8scramblePKci':
/home/smaugfuss/sf18/src/act_comm.c:33: multiple definition of `_note_free'
o/imc.o:/home/smaugfuss/sf18/src/imc.c:139: first defined here
o/act_info.o: In function `_Z8look_skyP9char_data':
/home/smaugfuss/sf18/src/act_info.c:144: multiple definition of `_note_free'
o/imc.o:/home/smaugfuss/sf18/src/imc.c:139: first defined here
o/act_move.o: In function `_Z9grab_wordPcS_':
/home/smaugfuss/sf18/src/act_move.c:131: multiple definition of `_note_free'
o/imc.o:/home/smaugfuss/sf18/src/imc.c:139: first defined here
o/act_obj.o: In function `_Z7advatoiPc':
/home/smaugfuss/sf18/src/bet.h:60: multiple definition of `_note_free'
o/imc.o:/home/smaugfuss/sf18/src/imc.c:139: first defined here
o/act_wiz.o: In function `_Z12get_saveflagPc':
/home/smaugfuss/sf18/src/act_wiz.c:73: multiple definition of `_note_free'
o/imc.o:/home/smaugfuss/sf18/src/imc.c:139: first defined here
o/ban.o: In function `_Z12load_banlistv':
/home/smaugfuss/sf18/src/ban.c:45: multiple definition of `_note_free'
o/imc.o:/home/smaugfuss/sf18/src/imc.c:139: first defined here
o/boards.o: In function `_Z14delete_projectP12project_data':
/home/smaugfuss/sf18/src/boards.c:39: multiple definition of `_note_free'
o/imc.o:/home/smaugfuss/sf18/src/imc.c:139: first defined here


It goes through every file and says multiple definition at the first of every function. note_free is defined in mud.h and only once throughout the whole code. I'm not sure what I've done wrong.

I've done make clean everytime I've tried to fix it and I have no idea why it keeps doing that.

Here's mud.h

/* board.c */
NOTE_DATA *note_free;
void free_global_note args ( ( NOTE_DATA *note) );

/* boards.c */
void load_boards args ( ( void ) );
BD *get_board args ( ( OBJ_DATA *obj ) );


Everything compiles fine until it reaches the very end.
Amended on Sun 15 Jul 2007 04:14 AM by Orik
USA #1
What's imc.c, line 139?
USA #2
It's the very first function, but I've been looking up the problem and I think I might have found it.

Changed in mud.h

NOTE_DATA *note_free;

to extern NOTE_DATA *note_free;

and then in board.c put
NOTE_DATA *note_free;

That works right there.
USA #3
Where did you find that *note_free declaration? mud.h does not have that in a stock distro of SmaugFUSS 1.8.
USA #4
It was with the global board snippet.