02 Feb, 2008, Terraco wrote in the 1st comment:
Votes: 0
Okay I hope someone can help me with this issue, but I cant find anything out about this set of errors.


gcc -Wall -O -ggdb -DNOCRYPT -DQMFIXES -c -o obj/bit.o bit.c

bit.c:52: error: initializer element is not constant

bit.c:52: error: (near initialization for 'flag_stat_table[0].structure')

bit.c:53: error: initializer element is not constant

bit.c:53: error: (near initialization for 'flag_stat_table[1].structure')
bit.c:54: error: initializer element is not constant

bit.c:54: error: (near initialization for 'flag_stat_table[2].structure')

bit.c:55: error: initializer element is not constant

bit.c:55: error: (near initialization for 'flag_stat_table[3].structure')

bit.c:56: error: initializer element is not constant

bit.c:54: error: initializer element is not constant

bit.c:54: error: (near initialization for 'flag_stat_table[2].structure')

bit.c:55: error: initializer element is not constant

bit.c:55: error: (near initialization for 'flag_stat_table[3].structure')

bit.c:56: error: initializer element is not constant

bit.c:56: error: (near initialization for 'flag_stat_table[4].structure')
bit.c:57: error: initializer element is not constant

bit.c:57: error: (near initialization for 'flag_stat_table[5].structure')

bit.c:58: error: initializer element is not constant

bit.c:58: error: (near initialization for 'flag_stat_table[6].structure')

bit.c:59: error: initializer element is not constant

bit.c:59: error: (near initialization for 'flag_stat_table[7].structure')
bit.c:60: error: initializer element is not constant

bit.c:60: error: (near initialization for 'flag_stat_table[8].structure')

bit.c:61: error: initializer element is not constant

bit.c:61: error: (near initialization for 'flag_stat_table[9].structure')

bit.c:62: error: initializer element is not constant

bit.c:62: error: (near initialization for 'flag_stat_table[10].structure')
bit.c:63: error: initializer element is not constant

bit.c:63: error: (near initialization for 'flag_stat_table[11].structure')

bit.c:64: error: initializer element is not constant

bit.c:64: error: (near initialization for 'flag_stat_table[12].structure')

bit.c:65: error: initializer element is not constant

bit.c:65: error: (near initialization for 'flag_stat_table[13].structure')

bit.c:66: error: initializer element is not constant

bit.c:66: error: (near initialization for 'flag_stat_table[14].structure')

bit.c:70: error: initializer element is not constant

bit.c:70: error: (near initialization for 'flag_stat_table[15].structure')

bit.c:71: error: initializer element is not constant

bit.c:71: error: (near initialization for 'flag_stat_table[16].structure')
bit.c:72: error: initializer element is not constant

bit.c:72: error: (near initialization for 'flag_stat_table[17].structure')

bit.c:73: error: initializer element is not constant

bit.c:73: error: (near initialization for 'flag_stat_table[18].structure')

bit.c:74: error: initializer element is not constant

bit.c:74: error: (near initialization for 'flag_stat_table[19].structure')
bit.c:75: error: initializer element is not constant

bit.c:75: error: (near initialization for 'flag_stat_table[20].structure')

bit.c:76: error: initializer element is not constant

bit.c:76: error: (near initialization for 'flag_stat_table[21].structure')

bit.c:77: error: initializer element is not constant

bit.c:77: error: (near initialization for 'flag_stat_table[22].structure')

bit.c:78: error: initializer element is not constant

bit.c:78: error: (near initialization for 'flag_stat_table[23].structure')

bit.c:79: error: initializer element is not constant

bit.c:79: error: (near initialization for 'flag_stat_table[24].structure')

bit.c:80: error: initializer element is not constant

bit.c:80: error: (near initialization for 'flag_stat_table[25].structure')
bit.c:81: error: initializer element is not constant

bit.c:81: error: (near initialization for 'flag_stat_table[26].structure')

make: *** [obj/bit.o] Error 1

/* now here is the bit.c as is */

const struct flag_stat_type flag_stat_table[] = {
/* { structure stat }, */
{area_flags, FALSE},
{sex_flags, TRUE},
{exit_flags, FALSE},
{door_resets, TRUE},
{room_flags, FALSE},
{sector_flags, TRUE},
{type_flags, TRUE},
{extra_flags, FALSE},
{wear_flags, FALSE},
{act_flags, FALSE},
{affect_flags, FALSE},
{apply_flags, TRUE},
{wear_loc_flags, TRUE},
{wear_loc_strings, TRUE},
{container_flags, FALSE},

/* ROM specific flags: */

{form_flags, FALSE},
{part_flags, FALSE},
{ac_type, TRUE},
{size_flags, TRUE},
{position_flags, TRUE},
{off_flags, FALSE},
{imm_flags, FALSE},
{res_flags, FALSE},
{vuln_flags, FALSE},
{weapon_class, TRUE},
{weapon_type2, FALSE},
{apply_types, TRUE},
{0, 0}
};

any help would be cool.
02 Feb, 2008, David Haley wrote in the 2nd comment:
Votes: 0
You can't initialize structures like that using variables like form_flags. You can only have constants.
02 Feb, 2008, Terraco wrote in the 3rd comment:
Votes: 0
well how can we fix it so we can get the mud running?
02 Feb, 2008, David Haley wrote in the 4th comment:
Votes: 0
Is this code that you added or was it in the stock distribution? If it was the stock distribution, what codebase are you using and where did you get it?
02 Feb, 2008, Terraco wrote in the 5th comment:
Votes: 0
its stock stuff, its ROM (QuickMUD). I got it from my host, but if I ask him about it I am in violation of the TOS and he shuts down my account.
02 Feb, 2008, drrck wrote in the 6th comment:
Votes: 0
Terraco said:
its stock stuff, its ROM (QuickMUD). I got it from my host, but if I ask him about it I am in violation of the TOS and he shuts down my account.


He'll find out about it sooner or later. You really shouldn't be violating your TOS.

As far as the code goes, you can remove the "const" before the structure definition and shut the compiler up, but that's just a rigged fix. You should do some research into const-correctness and fix it properly.
02 Feb, 2008, Guest wrote in the 7th comment:
Votes: 0
When you say you got it from your host, I'm curious, what sort of host offers codebases for download, but violates your TOS for actually setting them up to use there?
02 Feb, 2008, Terraco wrote in the 8th comment:
Votes: 0
he set it up to use, i used copyover and it crashed I got that fixed then everything started to error out on me, and if I ask him anything about the code or ask for help fixing it, it is a violation of my TOS.
03 Feb, 2008, David Haley wrote in the 9th comment:
Votes: 0
So your host shuts down your account if you ask for help? Nice host you have there…

Well anyhow, you should try getting a stock distribution yourself and seeing if it compiles. The only other option really is to go ahead with what drrck suggested.
0.0/9