first off id like to say that even though this is my first post, this form has helped me alot, i like to make sure my question hasent already been answered befor i post, thanks guys
following is cygwin output, (wow, hey look at that i got all the way to my fisrt make without posting a question, and i only had to download 5 times!)
$ make
make swrip
make[1]: Entering directory `/home/src'
gcc -c -g3 -Wall -DREQUESTS act_wiz.c
In file included from mud.h:264,
from act_wiz.c:32:
alias.h:39:98: warning: no newline at end of file
act_wiz.c:1838: error: conflicting types for `trunc'
/usr/include/math.h:144: error: previous declaration of `trunc'
act_wiz.c: In function `do_form_password':
act_wiz.c:4976: warning: implicit declaration of function `crypt'
make[1]: *** [act_wiz.o] Error 1
make[1]: Leaving directory `/home/src'
make: *** [all] Error 2
$ qdb
BASH: qdb: command not found
$
this is line 1838 of act_wiz.c
void trunc(char *s, int len)
{
if ( strlen(s) > len )
s[len] = '\0';
}
this the function the crypt error is in
/* Online high level immortal command for displaying what the encryption
* of a name/password would be, taking in 2 arguments - the name and the
* password - can still only change the password if you have access to
* pfiles and the correct password
*/
void do_form_password( CHAR_DATA *ch, char *argument)
{
char arg[MAX_STRING_LENGTH];
argument = one_argument(argument, arg);
ch_printf(ch, "Those two arguments encrypted would result in: %s",
crypt(arg, argument)); //this is line 4976
return;
}
my makefile looks like this...
CC = gcc
PROF =
NOCRYPT =
#Uncomment the next line if you want request support
DBUGFLG = -DREQUESTS
C_FLAGS = -g3 -Wall $(PROF) $(NOCRYPT) $(DBUGFLG)
L_FLAGS = $(PROF) -lcrypt
O_FILES = act_comm.o act_info.o act_move.o act_obj.o act_wiz.o boards.o \
build.o clans.o comm.o comments.o const.o db.o fight.o \
handler.o hashstr.o id.o interp.o magic.o makeobjs.o \
misc.o mud_comm.o mud_prog.o newarena.o player.o requests.o \
reset.o save.o shops.o skills.o special.o tables.o track.o update.o \
space.o space2.o bounty.o swskills.o alias.o grub.o mapper.o
C_FILES = act_comm.c act_info.c act_move.c act_obj.c act_wiz.c boards.c \
build.c clans.c comm.c comments.c const.c db.c fight.c \
handler.c hashstr.c id.c interp.c magic.c makeobjs.c \
misc.c mud_comm.c mud_prog.c newarena.c player.c requests.c \
reset.c save.c shops.c skills.c special.c tables.c track.c update.c \
space.c space2.c bounty.c swskills.c alias.c grub.c mapper.c
H_FILES = mud.h bet.h
all:
# co $(H_FILES)
make swrip
# rm -f $(H_FILES)
mv swrip ../bin/swrip
swrip: $(O_FILES)
rm -f swrip
$(CC) $(L_FLAGS) -o swrip $(O_FILES) -lm
chmod g+w swrip
chmod g+w $(O_FILES)
.c.o: mud.h
$(CC) -c $(C_FLAGS) $<
clean:
rm -f $(O_FILES)
any ideas?
following is cygwin output, (wow, hey look at that i got all the way to my fisrt make without posting a question, and i only had to download 5 times!)
$ make
make swrip
make[1]: Entering directory `/home/src'
gcc -c -g3 -Wall -DREQUESTS act_wiz.c
In file included from mud.h:264,
from act_wiz.c:32:
alias.h:39:98: warning: no newline at end of file
act_wiz.c:1838: error: conflicting types for `trunc'
/usr/include/math.h:144: error: previous declaration of `trunc'
act_wiz.c: In function `do_form_password':
act_wiz.c:4976: warning: implicit declaration of function `crypt'
make[1]: *** [act_wiz.o] Error 1
make[1]: Leaving directory `/home/src'
make: *** [all] Error 2
$ qdb
BASH: qdb: command not found
$
this is line 1838 of act_wiz.c
void trunc(char *s, int len)
{
if ( strlen(s) > len )
s[len] = '\0';
}
this the function the crypt error is in
/* Online high level immortal command for displaying what the encryption
* of a name/password would be, taking in 2 arguments - the name and the
* password - can still only change the password if you have access to
* pfiles and the correct password
*/
void do_form_password( CHAR_DATA *ch, char *argument)
{
char arg[MAX_STRING_LENGTH];
argument = one_argument(argument, arg);
ch_printf(ch, "Those two arguments encrypted would result in: %s",
crypt(arg, argument)); //this is line 4976
return;
}
my makefile looks like this...
CC = gcc
PROF =
NOCRYPT =
#Uncomment the next line if you want request support
DBUGFLG = -DREQUESTS
C_FLAGS = -g3 -Wall $(PROF) $(NOCRYPT) $(DBUGFLG)
L_FLAGS = $(PROF) -lcrypt
O_FILES = act_comm.o act_info.o act_move.o act_obj.o act_wiz.o boards.o \
build.o clans.o comm.o comments.o const.o db.o fight.o \
handler.o hashstr.o id.o interp.o magic.o makeobjs.o \
misc.o mud_comm.o mud_prog.o newarena.o player.o requests.o \
reset.o save.o shops.o skills.o special.o tables.o track.o update.o \
space.o space2.o bounty.o swskills.o alias.o grub.o mapper.o
C_FILES = act_comm.c act_info.c act_move.c act_obj.c act_wiz.c boards.c \
build.c clans.c comm.c comments.c const.c db.c fight.c \
handler.c hashstr.c id.c interp.c magic.c makeobjs.c \
misc.c mud_comm.c mud_prog.c newarena.c player.c requests.c \
reset.c save.c shops.c skills.c special.c tables.c track.c update.c \
space.c space2.c bounty.c swskills.c alias.c grub.c mapper.c
H_FILES = mud.h bet.h
all:
# co $(H_FILES)
make swrip
# rm -f $(H_FILES)
mv swrip ../bin/swrip
swrip: $(O_FILES)
rm -f swrip
$(CC) $(L_FLAGS) -o swrip $(O_FILES) -lm
chmod g+w swrip
chmod g+w $(O_FILES)
.c.o: mud.h
$(CC) -c $(C_FLAGS) $<
clean:
rm -f $(O_FILES)
any ideas?