[Home] [Downloads] [Search] [Help/forum]


Register forum user name Search FAQ

Gammon Forum

[Folder]  Entire forum
-> [Folder]  SMAUG
. -> [Folder]  Running the server
. . -> [Subject]  DBSaga Compiling Issues

DBSaga Compiling Issues

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page


Pages: 1 2  

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Thu 01 Oct 2020 04:16 AM (UTC)

Amended on Thu 01 Oct 2020 04:18 AM (UTC) by Ohlookadime

Message
Hello everyone OLaD here. I'm new to coding and found this old DBSaga codebase. I've spent a week on this forum and other boards trying to get this to compile on my widows 10 x64 with cygwin.

I know this has been addressed many times and is an old topic. I hope you all are still around to help a newbie like me!

This is the newest result of running 'make' in cygwin.

NOTE; per instructions with the read me with the code, the folder dbs is moved into the c:\cygwin64\home\ohloo\ dir


Quote:

OhLoo@LAPTOP-SCPLGT8K ~
$ cd dbs/src

OhLoo@LAPTOP-SCPLGT8K ~/dbs/src
$ make
Makefile:93: warning: ignoring prerequisites on suffix rule definition
Starting the Compile.. ...
make -s dbs
Makefile:93: warning: ignoring prerequisites on suffix rule definition
Compiling DBS - < o/act_comm.o >
make[1]: gcc34: No such file or directory
make[1]: *** [Makefile:90: o/act_comm.o] Error 127
make: *** [Makefile:64: all] Error 2



this is the make file



Quote:

CC = gcc34
#PROF = -p
NOCRYPT =

# Uncomment the line below if you have problems with math functions
MATH_LINK = -lm

# Uncomment the two lines below if compiling on a Solaris box
#SOLARIS_FLAG = -Dsun -DSYSV
#SOLARIS_LINK = -lnsl -lsocket

#Uncomment the line below if you are getting a line like:
#interp.c:757: warning: int format, time_t arg (arg 7)
TIME = -DTIMEFORMAT

#Uncomment the line below if you are getting implicit decleration of re_exec
#REG = -DREGEX

#Uncomment the line below if you are getting undefined re_exec errors
NEED_REG = -lgnuregex

#Uncomment the line below if you are getting undefined crypt errors
#NEED_CRYPT = -NOCRYPT

#DBUGFLG = -DREQUESTS

#IMC2 - Comment out to disable IMC2 support
IMC = 1

#Uncomment the line below if you want a performance increase though beware
#your core files may not be as much of a benefit if you do.
#OPT_FLAG = -finline-functions -funroll-loops -fdefer-pop -fstrength-reduce
OPT_FLAG = -DMCCP

C_FLAGS = $(OPT_FLAG) -O -g3 -Wall $(PROF) $(NOCRYPT) $(DBUGFLG) -DSMAUG $(SOLARIS_FLAG) $(TIME) $(REG)
L_FLAGS = $(OPT_FLAG) $(PROF) $(SOLARIS_LINK) $(NEED_CRYPT) ${MATH_LINK} -lz

#D_FLAGS : For the DNS Slave process. No need in linking all the extra libs for this.
D_FLAGS = -g3 -O $(PROF) $(SOLARIS_LINK)

O_FILES = $(patsubst %.c,o/%.o,$(C_FILES))

C_FILES = act_comm.c act_info.c act_move.c act_obj.c act_wiz.c ban.c \
board.c boards.c bounty.c build.c changes.c clans.c colorize.c comm.c \
comments.c const.c db.c deity.c editor.c fight.c finger.c grub.c \
handler.c hashstr.c hiscores.c hotboot.c house.c ibuild.c ident.c \
imm_host.c interp.c magic.c makeobjs.c mapout.c mapper.c marry.c md5.c\
misc.c mpxset.c mud_comm.c mud_prog.c new_fun.c pfiles.c planes.c \
planet.c player.c polymorph.c rare.c requests.c reset.c save.c \
services.c shops.c skills.c skills_android.c skills_dbs.c\
space.c special.c stat_obj.c tables.c track.c update.c dns.c skills_genie.c \
new_auth.c

H_FILES = mud.h bet.h board.h finger.h hotboot.h house.h pfiles.h rare.h new_auth.h

#ifdef IMC
# C_FILES := imc.c $(C_FILES)
# O_FILES := imc.o $(O_FILES)
# C_FLAGS := $(C_FLAGS) -DIMC -DIMCSMAUG
#endif

all:
@echo Starting the Compile.. $< ...
$(MAKE) -s dbs

dbs: $(O_FILES)
rm -f dbsaga
$(CC) $(L_FLAGS) -o dbsaga $(O_FILES) -lcrypt
echo "DBS is fully compiled. Enjoy.";
chmod g+w dbsaga
chmod a+x dbsaga
chmod g+w $(O_FILES)

dbs2: $(O_FILES)
rm -f dbsaga2
$(CC) $(L_FLAGS) -o dbsaga2 $(O_FILES)
chmod g+w dbsaga2
chmod a+x dbsaga2
chmod g+w $(O_FILES)

dns: resolver.o
rm -f resolver
$(CC) $(D_FLAGS) -o resolver resolver.o
chmod g+w resolver
chmod a+x resolver
chmod g+w resolver.o

o/%.o: %.c
echo "Compiling DBS - < $@ >";
$(CC) -c $(C_FLAGS) $< -o $@

.c.o: mud.h
$(CC) -c $(C_FLAGS) $<

clean:
@echo Cleaning Code $< ...
rm -f o/*.o dbsaga *~
@echo Done.
[Go to top] top

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Reply #1 on Thu 01 Oct 2020 05:13 AM (UTC)
Message
also this lol



and the startup file



ohlookadime said:

#!/bin/csh -f

# Set the port number.
set port = 6000
if ( "$1" != "" ) set port="$1"

# Change to area directory.
cd ../area

# Set limits.
nohup
nice
limit stack 1024k
ulimit -Sc unlimited
if ( -e shutdown.txt ) rm -f shutdown.txt

while ( 1 )
# If you want to have logs in a different directory,
# change the 'set logfile' line to reflect the directory name.

# rm ../log/syslog.9
# We have space to archive old log files now...
if ( -e ../log/syslog.9 ) then
set index = 1000
while ( 1 )
set archivefile = ../log/archived/$index.log
if ( ! -e $archivefile ) break
@ index++
end
mv ../log/syslog.9 $archivefile
endif

mv ../log/syslog.8 ../log/syslog.9
mv ../log/syslog.7 ../log/syslog.8
mv ../log/syslog.6 ../log/syslog.7
mv ../log/syslog.5 ../log/syslog.6
mv ../log/syslog.4 ../log/syslog.5
mv ../log/syslog.3 ../log/syslog.4
mv ../log/syslog.2 ../log/syslog.3
mv ../log/syslog.1 ../log/syslog.2
mv ../log/syslog.log ../log/syslog.1
#touch ../log/syslog.log

# start DBSaga tarball backup
# cd ../../
# mv backup/dbsbackup.current.tar.gz backup/dbsbackup.previous.tar.gz
# tar -czf backup/dbsbackup.current.tar.gz -X backup/exclude.list ./dbs
# cd dbs/area
cd ../area
# end DBSaga tarball backup

cp ../system/hiscores.dat ../system/hiscores.bak

set logfile = ../log/syslog.log

# Record starting time
date > $logfile
date > ../area/boot.txt

# Record initial charges
# charges >> $logfile

# Run SMAUG.
# NO! Run DBSaga!
../src/dbsaga $port >&! $logfile

# ../src/smaug 7654 >&! $logfile
# ../src/smaug $port >&! $logfile
# ../src/smaug >>&! $logfile

# Record ending charges
# charges >> $logfile

# # Delete this out if no adb.
# if ( -e core ) then
# echo '$c' | adb ../src/smaug
# endif

# Let's see if this works...
# Using old index value, would be nice to have
# it be the date for the file name
if ( -e core ) then
set index = 1000
while ( 1 )
set crashfile = ../crash/$index.crash
if ( ! -e $crashfile ) break
@ index++
end
\mv core ../src
cd ../src
date > $crashfile
gdb -batch -x commands dbsaga core >> $crashfile
# mv core ../crash/core.$index
rm -f core
cd ../area
endif

# Restart, giving old connections a chance to die.
if ( -e shutdown.txt ) then
rm -f shutdown.txt
exit 0
endif
sleep 10
end






I am so sorry for how this may appear to to bombard the board with it.

thank you all so much for your help in advance.
[Go to top] top

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Reply #2 on Thu 01 Oct 2020 05:13 AM (UTC)
Message
also this lol



and the startup file



ohlookadime said:

#!/bin/csh -f

# Set the port number.
set port = 6000
if ( "$1" != "" ) set port="$1"

# Change to area directory.
cd ../area

# Set limits.
nohup
nice
limit stack 1024k
ulimit -Sc unlimited
if ( -e shutdown.txt ) rm -f shutdown.txt

while ( 1 )
# If you want to have logs in a different directory,
# change the 'set logfile' line to reflect the directory name.

# rm ../log/syslog.9
# We have space to archive old log files now...
if ( -e ../log/syslog.9 ) then
set index = 1000
while ( 1 )
set archivefile = ../log/archived/$index.log
if ( ! -e $archivefile ) break
@ index++
end
mv ../log/syslog.9 $archivefile
endif

mv ../log/syslog.8 ../log/syslog.9
mv ../log/syslog.7 ../log/syslog.8
mv ../log/syslog.6 ../log/syslog.7
mv ../log/syslog.5 ../log/syslog.6
mv ../log/syslog.4 ../log/syslog.5
mv ../log/syslog.3 ../log/syslog.4
mv ../log/syslog.2 ../log/syslog.3
mv ../log/syslog.1 ../log/syslog.2
mv ../log/syslog.log ../log/syslog.1
#touch ../log/syslog.log

# start DBSaga tarball backup
# cd ../../
# mv backup/dbsbackup.current.tar.gz backup/dbsbackup.previous.tar.gz
# tar -czf backup/dbsbackup.current.tar.gz -X backup/exclude.list ./dbs
# cd dbs/area
cd ../area
# end DBSaga tarball backup

cp ../system/hiscores.dat ../system/hiscores.bak

set logfile = ../log/syslog.log

# Record starting time
date > $logfile
date > ../area/boot.txt

# Record initial charges
# charges >> $logfile

# Run SMAUG.
# NO! Run DBSaga!
../src/dbsaga $port >&! $logfile

# ../src/smaug 7654 >&! $logfile
# ../src/smaug $port >&! $logfile
# ../src/smaug >>&! $logfile

# Record ending charges
# charges >> $logfile

# # Delete this out if no adb.
# if ( -e core ) then
# echo '$c' | adb ../src/smaug
# endif

# Let's see if this works...
# Using old index value, would be nice to have
# it be the date for the file name
if ( -e core ) then
set index = 1000
while ( 1 )
set crashfile = ../crash/$index.crash
if ( ! -e $crashfile ) break
@ index++
end
\mv core ../src
cd ../src
date > $crashfile
gdb -batch -x commands dbsaga core >> $crashfile
# mv core ../crash/core.$index
rm -f core
cd ../area
endif

# Restart, giving old connections a chance to die.
if ( -e shutdown.txt ) then
rm -f shutdown.txt
exit 0
endif
sleep 10
end






I am so sorry for how this may appear to to bombard the board with it.

thank you all so much for your help in advance.
[Go to top] top

Posted by Nick Gammon   Australia  (23,001 posts)  [Biography] bio   Forum Administrator
Date Reply #3 on Thu 01 Oct 2020 07:13 AM (UTC)
Message
The first thing is to get the "make" working and by the look of it you possibly don't have an "o" directory (for the object files) underneath the "src" directory.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Reply #4 on Fri 02 Oct 2020 02:14 AM (UTC)
Message
There is one already. In the dbs/src dir
[Go to top] top

Posted by Nick Gammon   Australia  (23,001 posts)  [Biography] bio   Forum Administrator
Date Reply #5 on Fri 02 Oct 2020 06:25 AM (UTC)
Message
Try running make in debug mode. Possibly:


make --dry-run



You should see echoed what make is trying to do, what files it is sending to gcc (or g++) so you can confirm if the source files exists, and the destination directories exist.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Reply #6 on Sat 03 Oct 2020 03:34 AM (UTC)
Message
This is what I got. I'm a complete n00b still but I didn't see anything bad.

https://pastebin.com/mkEY8wsf
[Go to top] top

Posted by Nick Gammon   Australia  (23,001 posts)  [Biography] bio   Forum Administrator
Date Reply #7 on Sat 03 Oct 2020 04:35 AM (UTC)
Message
Does gcc34 exist? Try typing:


gcc34 --version

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Reply #8 on Sun 04 Oct 2020 12:42 AM (UTC)
Message
There is one already. In the dbs/src dir
[Go to top] top

Posted by Nick Gammon   Australia  (23,001 posts)  [Biography] bio   Forum Administrator
Date Reply #9 on Sun 04 Oct 2020 07:42 AM (UTC)
Message
What? Can you please post the output from typing:


gcc34 --version

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Fiendish   USA  (2,518 posts)  [Biography] bio   Global Moderator
Date Reply #10 on Mon 05 Oct 2020 09:19 PM (UTC)

Amended on Mon 05 Oct 2020 09:20 PM (UTC) by Fiendish

Message
Quote:
Does gcc34 exist?

Quote:
There is one already. In the dbs/src dir

Quote:
What?

LOL. This exchange got me laughing.

https://github.com/fiendish/aardwolfclientpackage
[Go to top] top

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Reply #11 on Mon 05 Oct 2020 11:31 PM (UTC)

Amended on Tue 06 Oct 2020 01:50 AM (UTC) by Ohlookadime

Message
lol im sorry about that. I been trying to reply on my phone and its having issues apparently lol. This is what I got from;

gcc34 --ver
Quote:

OhLoo@LAPTOP-SCPLGT8K ~/dbs/src
$ gcc34 --version
-bash: gcc34: command not found


I've reinstalled more gcc packages for cygwin, apparently I don't have the right ones yet lol. Thank y'all for the continued help!


[EDIT]
I have removed the '34' from gcc34 in the make file, that has solved the gcc issue. Now this is showing when I run make again.

https://pastebin.com/SJdkrSpZ
[Go to top] top

Posted by Nick Gammon   Australia  (23,001 posts)  [Biography] bio   Forum Administrator
Date Reply #12 on Tue 06 Oct 2020 04:31 AM (UTC)
Message
It looks like the same error, over and over for each file. Why you get that message I can't say, as I can't see the source code you are using.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] top

Posted by Ohlookadime   (12 posts)  [Biography] bio
Date Reply #13 on Tue 06 Oct 2020 05:32 AM (UTC)
Message
Nick Gammon said:

... as I can't see the source code you are using.


I could upload the archive I have as a zip or is there another way to show you? I'd really like to get this to work.

Thank you.
[Go to top] top

Posted by Nick Gammon   Australia  (23,001 posts)  [Biography] bio   Forum Administrator
Date Reply #14 on Tue 06 Oct 2020 06:48 AM (UTC)
Message
Perhaps post the link to where it is?

An occupational hazard of compiling old source code is that compilers have become more strict. They try to stop you doing things like buffer overflow, which people exploit to hack into systems.

Thus, code that compiled 10 or 20 years ago doesn't compile now. So, you need to understand what the code does in order to fix the issues. Sometimes this is not at all simple.

- Nick Gammon

www.gammon.com.au, www.mushclient.com
[Go to top] 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.


38,938 views.

This is page 1, subject is 2 pages long: 1 2  [Next page]

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.

[Home]


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at HostDash]