Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ SMAUG
➜ Compiling the server
➜ SWR 2.0 Heavily Modified, Buggy, for Cygwin on Windwows2K
SWR 2.0 Heavily Modified, Buggy, for Cygwin on Windwows2K
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Tue 28 Sep 2004 11:33 PM (UTC) |
Message
| Hello, as you can guess from my name I need some help. It is with compiling my code base which is based off of SWR 2.0 but heavily modified. The code base is extremely buggy but before I attempt to correct these bugs in the code I want to find out why the code does not compile. It completes the linking of all the .c files but near the ned when it attempts to make swr.exe there is an error with the process any help would be nice. I have included the compiling list taken from Cygwin and also a copy of my makefile, also modified. The Makefile no longer includes any of the if conditions used if you aren't compiling with cygwin so don't worry about those being gone I did it. | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #1 on Tue 28 Sep 2004 11:35 PM (UTC) |
Message
| $ make
make swr
make[1]: Entering directory '/swr/src'
gcc -c -g3 -Wall -export-dynamic act_comm.c
act_comm.c: In function 'do_say':
act_comm.c:1704: warning: implicit declaration of function 'tone convert'
act_comm.c:1704: warning: format argument is not a pointer (arg 3)
act_comm.c:1731: warning: format argument is not a pointer (arg 3)
act_comm.c: At atop level:
act_comm.c:3712: warning: type mismatch with previous implicit declaration
act_comm.c:1731: warning: previous implicit declaration of 'tone_convert'
act_comm.c:3712: warning: 'tone_convert' was previously implicitly declared to return 'int'
gcc -c -g3 -Wall -export-dynamic act_info.c
act_info.c: In function 'do_look':
act_info.c1096: warning: assignment makes pointer from integer without a cast
gcc -c -g3 -Wall -export-dynamic act_move.c
act_move.c: In function 'generate_exit':
act_move.c:599: warning: use of cast expressions as lvalues is deprecated
gcc -c -g3 -Wall -export-dynamic act_obj.c
gcc -c -g3 -Wall -export-dynamic act_wiz.c
act_wiz.c: In function 'do_pcrename':
act_wiz.c:7181: warning: implicit declaration of function 'write_board'
act_wiz.c: In function 'do_immortalize':
act_wiz.c:7890: warning: implicit declaration of function 'build_wizinfo'
gcc -c -g3 -Wall -export-dynamic bank.c
gcc -c -g3 -Wall -export-dynamic boards.c
gcc -c -g3 -Wall -export-dynamic bounty.c
gcc -c -g3 -Wall -export-dynamic build.c
gcc -c -g3 -Wall -export-dynamic clans.c
gcc -c -g3 -Wall -export-dynamic comm.c
gcc -c -g3 -Wall -export-dynamic comments.c
gcc -c -g3 -Wall -export-dynamic const.c
const.c:42: warning: missing braces around initializer
const.c:42: warning: (near initalization for 'race_table[0].affected')
gcc -c -g3 -Wall -export-dynamic cyber.c
gcc -c -g3 -Wall -export-dynamic db.c
gcc -c -g3 -Wall -export-dynamic expionage.c
gcc -c -g3 -Wall -export-dynamic fight.c
gcc -c -g3 -Wall -export-dynamic greet.c
gcc -c -g3 -Wall -export-dynamic handler.c
handler.c: In function 'obj_to_char':
handler.c:1708: warning: comparison of distinct pointer types lacks a cast
handler.c: At top level:
handler.c:5069: warning: static declaration for 'LetterConversion' follows non-static
gcc -c -g3 -Wall -export-dynamic hashstr.c
gcc -c -g3 -Wall -export-dynamic id.c
gcc -c -g3 -Wall -export-dynamic force.c
gcc -c -g3 -Wall -export-dynamic makeobjs.c
gcc -c -g3 -Wall -export-dynamic save.c
gcc -c -g3 -Wall -export-dynamic interp.c
gcc -c -g3 -Wall -export-dynamic tables.c
gcc -c -g3 -Wall -export-dynamic medic.c
gcc -c -g3 -Wall -export-dynamic misc.c
gcc -c -g3 -Wall -export-dynamic mud_comm.c
gcc -c -g3 -Wall -export-dynamic mud_prog.c
gcc -c -g3 -Wall -export-dynamic planets.c
planets.c: In function 'do_setplanet':
planets.c:666: warning: passing arg 1 of 'send_string_list_to_char' from incompatible pointer type
planets.c:673: warning: passing arg 1 of 'send_string_list_to_char' from incompatible pointer type
gcc -c -g3 -Wall -export-dynamic player.c
player.c:636:18: warning: trigraph ??) ignored
gcc -c -g3 -Wall -export-dynamic requests.c
gcc -c -g3 -Wall -export-dynamic pfiles.c
gcc -c -g3 -Wall -export-dynamic virtual.c
gcc -c -g3 -Wall -export-dynamic reset.c
gcc -c -g3 -Wall -export-dynamic shops.c
gcc -c -g3 -Wall -export-dynamic structure.c
gcc -c -g3 -Wall -export-dynamic skills.c
skills.c: In function 'do_palm':
skills.c:4756: warning: implicit declaration of function 'get_obj_palm'
skills.c: At top level:
skills.c:4950: warning: type mismatch with previous implicit declaration
skills.c:4915: warning: previous implicit declaration of 'get_obj_palm'
skills.c:4950: warning: 'get_obj_palm' was previously implicitly declared to return 'int'
| Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #2 on Tue 28 Sep 2004 11:35 PM (UTC) |
Message
| gcc -c -g3 -Wall -export-dynamic special.c
gcc -c -g3 -Wall -export-dynamic track.c
gcc -c -g3 -Wall -export-dynamic update.c
gcc -c -g3 -Wall -export-dynamic general.c
gcc -c -g3 -Wall -export-dynamic space.c
space.c In function 'fread_ship':
space.c:3407: warning: assignment makes pointer from integer without a cast
space.c In function 'do_radar':
space.c:14341: warning: assignment makes pointer from integer without a cast
space.c: In function 'deploy_pod':
space.c:17835: warning: suggest explicit braces to avoid ambigous 'else'
space.c: In function 'do_excape':
space.c:17925: warning: unused variable 'buf'
gcc -c -g3 -Wall -export-dynamic morespace.c
morespace.c: In function 'do_viewship':
morespace.c:1533: warning: unused variable 'arg2'
gcc -c -g3 -Wall -export-dynamic shuttle.c
gcc -c -g3 -Wall -export-dynamic slicer.c
slicer.c: In function 'do_fakesignal':
slicer.c:202: warning: implicit declaration of function 'get_hangar_id'
slicer.c:202: warning: assignment makes pointer from integer without a cast
slicer.c:264: warning: assignment makes pointer from integer without a cast
slicer.c: In function 'do_locateship':
slicer.c:401: warning: implicit declaration of function 'can_land'
slicer.c: In function 'do_short'
slicer.c:450: warning: unused variable 'ship'
gcc -c -g3 -Wall -export-dynamic swskills.c
gcc -c -g3 -Wall -export-dynamic quest.c
gcc -c -g3 -Wall -export-dynamic vehicles.c
gcc -c -g3 -Wall -export-dynamic vendor.c
gcc -c -g3 -Wall -export-dynamic websrv.c
gcc -c -g3 -Wall -export-dynamic mc_mem.c
gcc -c -g3 -Wall -export-dynamic ismalloc.c
gcc -c -g3 -Wall -export-dynamic kylixen.c
gcc -c -g3 -Wall -export-dynamic slay.c
gcc -c -g3 -Wall -export-dynamic restore.c
gcc -c -g3 -Wall -export-dynamic changes.c
gcc -c -g3 -Wall -export-dynamic zarius.c
gcc -c -g3 -Wall -export-dynamic starmap.c
gcc -c -g3 -Wall -export-dynamic backup.c
gcc -c -g3 -Wall -export-dynamic alias.c
gcc -c -g3 -Wall -export-dynamic designship.c
gcc -c -g3 -Wall -export-dynamic chance.c
gcc -c -g3 -Wall -export-dynamic asteroids.c
asteroids.c: In function 'get_asteroid_here':
asteroids.c:110:warning: assignment makes pointer from integer without a cast
asteroids.c:114:warning: assignment makes pointer from integer without a cast
asteroids.c: In function 'extract_asteroid':
asteroids.c:198:warning: comparison between pointer and integer
asteroids.c:199:warning: assignment makes pointer from integer without a cast
asteroids.c:201:warning: comparison between pointer and integer
asteroids.c:202:warning: assignment makes pointer from integer without a cast
asteroids.c:212:warning: assignment makes pointer from integer without a cast
asteroids.c:212:warning: assignment makes pointer from integer without a cast
asteroids.c: In function 'asteroid_to_system':
asteroids.c:246:warning: comparison between pointer and integer
asteroids.c:247:warning: assignment makes pointer from integer without a cast
asteroids.c:251:warning: assignment makes pointer from integer without a cast
asteroids.c:252:warning: assignment makes pointer from integer without a cast
asteroids.c:255:warning: assignment makes pointer from integer without a cast
rm -f swr swr.exe
gcc -export-dynamic -lcrypt -ldl -o swr.exe act_comm.o act_info.o act_move.o act_obj.o act_wiz.o bank.o boards.o bounty.o build.o clans.o comm.o comments.o const.o cyber.o db.o expionage.o fight.o greet.o handler.o hashstr.o id.o force.o makeobjs.o save.o interp.o tables.o medic.o misc.o mud_comm.o mud_prog.o planets.o player.o requests.o pfiles.o virtual.o reset.o shops.o structure.o skills.o special.o track.o update.o general.o space.o morespace.o shuttle.o slicer.o swskills.o quest.o vehicles.o vendor.o websrv.o mc_mem.o smalloc.o kylixen.o slay.o restore.o changes.o zarius.o starmap.o backup.o alias.o designship.o chance.o asteroids.o -lm
/usr/lib/gcc-lib/i686-pc-cygwin/3.3.3/../../../../i686-pc-cygwin/bin/ld: cannot find -ldl
collect2: ld returned 1 exit status
make[1]: *** [swr] Error 1
make[1]: Leaving directory '/swr/src'
make: *** [all] Error 2 | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #3 on Tue 28 Sep 2004 11:36 PM (UTC) |
Message
| CC = gcc
PROF =
NOCRYPT =
CYGWIN = -DCYGWIN
#DBUGFLG = -DREQUESTS
#DEBUG = -DDEBUG -DMC_MEM_INTRO -DMEMORY_HASH=101 -ggdb
C_FLAGS = -g3 -Wall $(PROF) $(NOCRYPT) $(DBUGFLG) $(DEBUG) $(EXPORT_SYMBOLS)
L_FLAGS = $(PROF) -lcrypt -ldl
EXPORT_SYMBOLS = -export-dynamic
O_FILES = act_comm.o act_info.o act_move.o act_obj.o act_wiz.o bank.o boards.o \
bounty.o build.o clans.o comm.o comments.o const.o cyber.o db.o espionage.o \
fight.o greet.o handler.o hashstr.o id.o force.o makeobjs.o save.o interp.o tables.o \
medic.o misc.o mud_comm.o mud_prog.o planets.o player.o requests.o pfiles.o virtual.o \
reset.o shops.o structure.o skills.o special.o track.o update.o general.o space.o \
morespace.o shuttle.o slicer.o swskills.o quest.o vehicles.o vendor.o websrv.o mc_mem.o smalloc.o \
kylixen.o slay.o restore.o changes.o zarius.o starmap.o backup.o alias.o designship.o chance.o asteroids.o \
C_FILES = act_comm.c act_info.c act_move.c act_obj.c act_wiz.c bank.c boards.c \
bounty.c build.c clans.c comm.c comments.c const.c cyber.c db.c espionage.c \
fight.c greet.c handler.c hashstr.c id.c force.c makeobjs.c save.c interp.c tables.c \
medic.c misc.c mud_comm.c mud_prog.c planets.c player.c requests.c pfiles.c virtual.c \
reset.c shops.c structure.c skills.c special.c track.c update.c general.c space.c \
morespace.c shuttle.c slicer.c swskills.c quest.c vehicles.c vendor.c websrv.c mc_mem.c smalloc.c \
kylixen.c slay.c restore.c changes.c zarius.c starmap.c backup.c alias.c designship.c chance.c asteroids.c \
H_FILES = mud.h bet.h pfiles.h slay.h help.h restore.h changes.h zarius.h alias.h shuttle.h
all:
make swr
swr: $(O_FILES)
rm -f swr swr.exe
$(CC) -export-dynamic $(L_FLAGS) -o swr.exe $(O_FILES) -lm
chmod g+w swr.exe
chmod g+w $(O_FILES)
.c.o: mud.h
$(CC) -c $(C_FLAGS) $<
clean:
rm -f swr *.o
new:
make clean
make all
| Top |
|
Posted by
| Greven
Canada (835 posts) Bio
|
Date
| Reply #4 on Wed 29 Sep 2004 02:21 AM (UTC) |
Message
| I beleive that you need to remove the -ldl, as I do not beleive that it is supported in cygwin, but I could be wrong, check that though. |
Nobody ever expects the spanish inquisition!
darkwarriors.net:4848
http://darkwarriors.net | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #5 on Wed 29 Sep 2004 03:07 AM (UTC) |
Message
| I did as you said and I did get a swr.exe file in the directory. I moved the cygwin1.dll into the src directory along with it. In order to run the executable file from the area directory what command do I use in cygwin. | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #6 on Wed 29 Sep 2004 03:10 AM (UTC) |
Message
| $ make
make swr
make[1]: Entering directory '/swr/src'
rm -f swr swr.exe
gcc -export-dynamic -lcrypt -o swr.exe {All the .o files} -lm
chmod g+w swr.exe
chmod g+w {All the .o files}
make[1]: Leaving directory '/swr/src' | Top |
|
Posted by
| Greven
Canada (835 posts) Bio
|
Date
| Reply #7 on Wed 29 Sep 2004 03:53 AM (UTC) |
Message
| Do you have a startup script? That would probably work best. If not, you can do this:
1) Go into your area directory
2) "../src/swr.exe <port>", where port is whatever port you wanna run it under.
If you want to have the mud boot and run in the background, so you can do other things in the shell, you want to use "../src/swr.exe <port> &".
Hope that helps. |
Nobody ever expects the spanish inquisition!
darkwarriors.net:4848
http://darkwarriors.net | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #8 on Wed 29 Sep 2004 03:58 AM (UTC) |
Message
| Yes I have a startup script in my src directory but I can't even begin to make sense of the code within it. Can you tell me how to use it? | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #9 on Wed 29 Sep 2004 03:59 AM (UTC) |
Message
| . /etc/init.d/functions
RETVAL=0
start() {
echo -n $"SWD Starting Up"
cd /muds/swd/area
daemon /muds/swd/src/swdestiny 1111
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && touch /muds/swd/log/lockfile
}
stop() {
echo -n $"SWD Shutting Down"
killproc mud_executable_name
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && rm -f /muds/swd/log/lockfile
}
case "$1" in
start)
start
;;
stop)
stop
;;
restart|reload)
stop
start
RETVAL=$?
;;
condrestart)
if [ -f /muds/swd/src/swdestiny ]; then
stop
start
RETVAL=$?
fi
;;
status)
status swdestiny
RETVAL=$?
;;
*)
echo $"Usage: $0 {start|stop|restart|condrestart|status}"
exit 1
esac
exit $RETVAL | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #10 on Wed 29 Sep 2004 04:03 AM (UTC) |
Message
| When I tried your idea I got
For: ../src/swr.exe
Got: Nothing
For: ../src/swr.exe 4000
Got: Nothing
For: ../src/swr.exe 4000 &
Got: [1664]
For: ../src/swr.exe ./startup 4000
Got: [1]+ Exit 128 ../src/swr.exe 4000
The last I tried cause an old friend of mine owns a mud and that is how he starts his up with './starup' | Top |
|
Posted by
| SOSMudder
(10 posts) Bio
|
Date
| Reply #11 on Wed 29 Sep 2004 04:27 AM (UTC) |
Message
| I found a releated startup problem on the forum
http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=4552
And found that by going into the src directory I was able to activate the startup script with ./startup
However I got an error but found that by removing the
. /etc/init.d/functions
at the top of the startup script it tried to activate giving me the options of start, stop, restart, condrestart, and status.
However the directory of the startup file is incorrect. My copy of the mud is in c:\cygwin\swr\(area, src, ...)
Please tell me what to change in the startup file in order to correct the startup file. I know it has to do with the directory changes with the cd command but I don't know how far back to cd them such as to swr or all the way to c:
Also the swdestiny is to be replaced with swr but I don't know if it should be swr.exe or swr since I'm not certain if this was configured for cygwin or if even when cygwin is used to add the .exe to the name | Top |
|
Posted by
| Greven
Canada (835 posts) Bio
|
Date
| Reply #12 on Wed 29 Sep 2004 05:20 AM (UTC) |
Message
| I dunno why thats not working for you, when I try it in m cygwin, this works:$ cd ../area
$ ../src/swreality.exe 4848 &
[1] 4388
$ c:\Mud Files\swr1fuss\src\swreality.exe (4268): *** cygheap version mismatch detected - 0x61780000/0x616D000
0.
You have multiple copies of cygwin1.dll on your system.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version. The most recent version *should*
reside in x:\cygwin\bin, where 'x' is the drive on which you have
installed the cygwin distribution.
[1]+ Exit 128 ../src/swreality.exe 4848
Now, have other problems, but accessing it like that shouldn't be any problem. That script file seems odd for an SWR, though I never use 2.0 as I dislike it.
If your using the startup, looks to me like you want to use[ $RETVAL -eq 0 ] && touch ../log/lockfile
Assuming that 2.0 isn't that different, and /log is still in the same directory as /area and /src. |
Nobody ever expects the spanish inquisition!
darkwarriors.net:4848
http://darkwarriors.net | Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
31,587 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top