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

Gammon Software Solutions forum

See www.mushclient.com/spam for dealing with forum spam. Please read the MUSHclient FAQ!

[Folder]  Entire forum
-> [Folder]  SMAUG
. -> [Folder]  SMAUG coding
. . -> [Subject]  Compiling DBSC 2.5 with Cygwin for the smaug 1.4 windows exe

Home  |  Users  |  Search  |  FAQ
Username:
Register forum user name
Password:
Forgotten password?
(New message)
Subject: Compiling DBSC 2.5 with Cygwin for the smaug 1.4 windows exe
Name:
Your forum user name.
Register forum user name
Password:
Your forum password.
Forgotten password?
Message:
Message to be posted (in English, please).
Forum codes:
Check this if your message uses 'forum codes' or templates (auto-detected for new posts).
Forum codes Templates

Save this message ...


Subject review (reverse sequence)

Pages: 1 2  

Posted by David Haley   USA  (3,881 posts)  [Biography] bio   Moderator
Date Mon 26 Jan 2009 08:58 PM (UTC)  quote  ]
Message
Ah, I think you must be referring to the line-ending convention that Cygwin will use. (And yes, it's Unix vs. DOS, no Mac in there AFAIK.)

David Haley aka Ksilyan
Head Programmer,
Legends of the Darkstone

http://david.the-haleys.org
[Go to top] top

Posted by Muchalipski   (4 posts)  [Biography] bio
Date Mon 26 Jan 2009 08:51 PM (UTC)  quote  ]
Message
When you install Cygwin you can select it to be a mimic more or less like DOS or Unix base I believe. Not sure if that effects how it compiles. I should have said Unix rather then Mac.

I reinstalled a few things and it works fine. Thanks for the speedy reply though.
[Go to top] top

Posted by Nick Gammon   Australia  (18,772 posts)  [Biography] bio   Forum Administrator
Date Mon 26 Jan 2009 07:38 PM (UTC)  quote  ]
Message
Can you please paste the make output? You said you got the "same error" but one person reported getting "cannot find -luser32" and later reported getting "undefined reference to `_deflate'".


Quote:

And I'm using the Cygwin like Mac terminal not PC DOS.


I don't understand what you mean by this. Is a Mac involved?

- Nick Gammon

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

Posted by Muchalipski   (4 posts)  [Biography] bio
Date Mon 26 Jan 2009 05:52 PM (UTC)  quote  ]

Amended on Mon 26 Jan 2009 06:00 PM (UTC) by Muchalipski

Message
Hello, I've been having the same problem. I get that same error. I've downloaded the Zlib for Cygwin do I need to add a line somewhere?


Here are the instructions I've followed. And I'm using the Cygwin like Mac terminal not PC DOS.

DragonBall Saga Codebase Cygwin Install Instructions
----------------------------------------------------
1)  Download the Cygwin setup program from http://www.cygwin.com/

2)  Run setup.exe

3)  Select the following packages if they are not already:
    Base
     - zlib
    Devel
     - gcc-g++
     - make
     - patchutils
    Libs
     - crypt
     - gmp
    Shells
     - tcsh

4)  Select any other packages you wish to download.  I'd suggest getting
    Devel->gdb also as it is a very useful debugging tool.

5)  Wait while Cygwin downloads and installs.

6)  After Cygwin is installed, run it and let Cygwin set up your home folder.

7)  Copy the DBSC files to "C:\cygwin\home\username" (default location).

8)  Open up and edit "dbsc/src/Makefile" and find the following lines:
      #Uncomment if you wish to enable the Mud Client Compression Protocol
      #Comment it out it if you are compiling with Cygwin
      OPT_FLAG = -DMCCP
    Comment out "OPT_FLAG = -DMCCP" by putting a pound (#) symbol just before
    that line.  It should now look like this: 
      #Uncomment if you wish to enable the Mud Client Compression Protocol
      #Comment it out it if you are compiling with Cygwin
      #OPT_FLAG = -DMCCP

9)  Now in Cygwin just head over to the dbsc/src folder and type "make".

10)  After DBSC is compiled, while still in the dbsc/src folder type "./startup"
    or if you want to do other things in Cygwin while DBSC is running type
    "nohup ./startup &"

11) Finally start up your favorite MUD client and connect to the following
    address: localhost and use "9000" as the port number.  If you want to change
    what port DBSC starts on, open up and edit "dbsc/src/startup" and find the
    following lines:
      # Set the port number.
      set port = 9000
    Just change the "9000" to what ever number you want DBSC to use.  Most MUD's
    use numbers between 1000 and 9999.

=============================================
               Last Update
                May 2005
---------------------------------------------

And here is the makefile... any way I can add a line to make an exe?


CC      = gcc
#PROF   = -p

# 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

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

#DBUGFLG = -DREQUESTS

#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

#Uncomment if you wish to enable the Mud Client Compression Protocol
#Comment it out it if you are compiling with Cygwin
#OPT_FLAG = -DMCCP

C_FLAGS = $(OPT_FLAG) -O -g3 -Wall $(PROF) $(DBUGFLG) $(SOLARIS_FLAG) $(TIME) $(REG)
L_FLAGS = $(OPT_FLAG) $(PROF) $(SOLARIS_LINK) ${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 = act_comm.o act_info.o act_move.o act_obj.o act_wiz.o ban.o \
          board.o boards.o bounty.o build.o clans.o colorize.o comm.o \
          comments.o const.o db.o deity.o editor.o fight.o finger.o grub.o \
          handler.o hashstr.o hiscores.o hotboot.o house.o ibuild.o ident.o \
          imm_host.o interp.o magic.o makeobjs.o mapout.o marry.o \
          misc.o mpxset.o mud_comm.o mud_prog.o new_fun.o pfiles.o planes.o \
          planet.o player.o polymorph.o rare.o requests.o reset.o save.o \
          services.o shops.o skills.o skills_android.o skills_dbs.o skills_genie.o \
          space.o special.o stat_obj.o tables.o track.o update.o dns.o new_auth.o \
          sha256.o

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 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 marry.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 sha256.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:
	make dbs

dbs: $(O_FILES)
	rm -f dbsaga
	$(CC) $(L_FLAGS) -o dbsaga $(O_FILES)
	chmod g+w dbsaga
	chmod a+x dbsaga
	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

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

clean:
	rm -f *.o dbsaga *~

[Go to top] top

Posted by Shichiroji   USA  (22 posts)  [Biography] bio
Date Fri 28 Oct 2005 08:53 PM (UTC)  quote  ]
Message
Thanks, I'll get it and let you know what happens
[Go to top] top

Posted by Zeno   USA  (2,867 posts)  [Biography] bio   Moderator
Date Fri 28 Oct 2005 08:38 PM (UTC)  quote  ]
Message
You're missing the zlib header file which is required for MCCP.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Shichiroji   USA  (22 posts)  [Biography] bio
Date Fri 28 Oct 2005 08:26 PM (UTC)  quote  ]
Message
ok, after downloading some new files for cygwin this is how it looks after I make...I personally don't know how to code, but trying to learn so all help is appreciated


$ make
make dbs
make[1]: Entering directory `/cygdrive/c/dbsc/src'
rm -f dbsaga
gcc -DMCCP -lm -lz -o dbsaga act_comm.o act_info.o act_move.o act_obj.o act_
wiz.o ban.o board.o boards.o bounty.o build.o clans.o colorize.o comm.o comments
.o const.o db.o deity.o editor.o fight.o finger.o grub.o handler.o hashstr.o his
cores.o hotboot.o house.o ibuild.o ident.o imm_host.o interp.o magic.o makeobjs.
o malloc.o mapout.o marry.o misc.o mpxset.o mud_comm.o mud_prog.o new_fun.o pfil
es.o planes.o planet.o player.o polymorph.o rare.o requests.o reset.o save.o ser
vices.o shops.o skills.o skills_android.o skills_dbs.o skills_genie.o space.o sp
ecial.o stat_obj.o tables.o track.o update.o dns.o new_auth.o -lcrypt
comm.o: In function `write_to_descriptor':
/cygdrive/c/dbsc/src/comm.c:1778: undefined reference to `_deflate'
comm.o: In function `compressStart':
/cygdrive/c/dbsc/src/comm.c:5835: undefined reference to `_deflateInit_'
comm.o: In function `compressEnd':
/cygdrive/c/dbsc/src/comm.c:5870: undefined reference to `_deflate'
/cygdrive/c/dbsc/src/comm.c:5876: undefined reference to `_deflateEnd'
fight.o: In function `damage':
/cygdrive/c/dbsc/src/fight.c:2795: undefined reference to `_floorl'
/cygdrive/c/dbsc/src/fight.c:2816: undefined reference to `_floorl'
collect2: ld returned 1 exit status
make[1]: *** [dbs] Error 1
make[1]: Leaving directory `/cygdrive/c/dbsc/src'
make: *** [all] Error 2
[Go to top] top

Posted by Zeno   USA  (2,867 posts)  [Biography] bio   Moderator
Date Thu 27 Oct 2005 12:09 PM (UTC)  quote  ]
Message
See this topic:
http://www.gammon.com.au/forum/bbshowpost.php?bbsubject_id=448

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Shichiroji   USA  (22 posts)  [Biography] bio
Date Thu 27 Oct 2005 03:32 AM (UTC)  quote  ]
Message
ok, here is what I got when Cygwin got done compiling


$ make
make dbs
make[1]: Entering directory '/cygdrive/c/dbsc/src'
rm -f dbsaga
gcc -DMCCP -lm -lz -o dbsaga act_comm.o act_info.o act_move.o act_obj.o act_wiz.o ban.o board.o boards.o bounty.o build.o clans.o colorize.o comm.o comments.o const.o db.o deity.o editor.o fight.o finger.o grub.o handler.o haststr.o hiscores.o hotboot.o house.o ibuild.o ident.o imm_host.o interp.o magic.o makeobjs.o malloc.o mapout.o marry.o misc.o mpxset.o mud_comm.o mud_prog.o new_fun.o pfiles.o planes.o planet.o player.o polymorph.o rare.o requests.o reset.o save.o servies.o shops.o skills.o skills_android.o skills_dbs.o skills_genie.o space.o special.o stat_obj.o tables.o track.o update.o dns.o new_auth.o -lcrypt
?user/lip?gcc?i686-pc-cygwin/3.4.4/../../../../i686-pc-cygwin/bin/ld: cannot find -luser32
collect2: ld returned 1 sexit status
make[1]: *** [dbs] error 1
make[1]: Leaving directory '/cygdrive/c/dbsc/src'
make: *** [all] error 2
[Go to top] top

Posted by Shichiroji   USA  (22 posts)  [Biography] bio
Date Tue 25 Oct 2005 07:04 PM (UTC)  quote  ]
Message
Well, trying to install all the files for cygwin, Zeno helped out, trying to get the correct packages now, when I get done with that I'll post if there is another problem, Thanks
[Go to top] top

Posted by Gatewaysysop2   USA  (142 posts)  [Biography] bio
Date Tue 25 Oct 2005 03:24 AM (UTC)  quote  ]
Message
I think perhaps you should copy and paste what you're seeing when Cygwin "doesn't work" so that people here can better understand your problem. It could be something simple for all we know, but just saying that it doesn't work leaves way too many questions unanswered about how to get it working.

Again, show us what you're seeing and someone will probably be able to help you.


"The world of men is dreaming, it has gone mad in its sleep, and a snake is strangling it, but it can't wake up." -D.H. Lawrence
[Go to top] top

Posted by Zeno   USA  (2,867 posts)  [Biography] bio   Moderator
Date Mon 24 Oct 2005 05:31 PM (UTC)  quote  ]
Message
You mean like there is no 'make' command or anything? If so, then you didn't get the correct packages. They have to be installed correctly to work.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Shichiroji   USA  (22 posts)  [Biography] bio
Date Mon 24 Oct 2005 05:23 PM (UTC)  quote  ]
Message
ok, I know I probably sound like an ediot but I've reinstalled cygwin and still can't get it to compile, I went through the smaug help on compiling here and the commands wouldn't work, I even tried making sure I had everything downloaded and still nothing, what am I doing wrong?
[Go to top] top

Posted by Zeno   USA  (2,867 posts)  [Biography] bio   Moderator
Date Mon 24 Oct 2005 11:38 AM (UTC)  quote  ]

Amended on Mon 24 Oct 2005 11:47 AM (UTC) by Zeno

Message
DBSC wasn't "made" in Windows, so it won't come with a Win exe.

Yes, compiling it will make an exec.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Shichiroji   USA  (22 posts)  [Biography] bio
Date Mon 24 Oct 2005 04:50 AM (UTC)  quote  ]
Message
Well, I would use the .exe that comes with it if it did, but none came with it so...when I compile using Cygwin will it make one?
[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.


5,547 views.

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

[Reply to this subject]  Reply to this subject   [New subject]  Start a new subject   [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

[Home]

Written by Nick Gammon - 5K

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

[Best viewed with any browser - 2K]    [Internet Contents Rating Association (ICRA) - 2K]    [Web site powered by FutureQuest.Net]