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


Register forum user name Search FAQ

Gammon Forum

[Folder]  Entire forum
-> [Folder]  SMAUG
. -> [Folder]  Compiling the server
. . -> [Subject]  imc.c more errors

imc.c more errors

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


Posted by Glennjoos   (10 posts)  [Biography] bio
Date Mon 27 Apr 2020 07:16 PM (UTC)
Message
I am using gcc version 9.3.1 20200408 (Red Hat 9.3.1-2) (GCC)

Downloaded the 1.9 SmaugFUSS

Running an a virtual Fedora 31 in VM Workstation

glennjoos@ess-linux src]$ make
make -s smaug
Compiling o/imc.o....
imc.c: In function ‘void imc_update_tellhistory(CHAR_DATA*, const char*)’:
imc.c:1565:38: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
1565 | if( IMCTELLHISTORY( ch, x ) == '\0' )
| ^~~~
imc.c: In function ‘void imclog(const char*, ...)’:
imc.c:218:32: error: ‘%s’ directive output may be truncated writing up to 4095 bytes into a region of size 4091 [-Werror=format-truncation=]
218 | snprintf( buf2, LGST, "IMC: %s", buf );
| ^~ ~~~
imc.c:218:12: note: ‘snprintf’ output between 6 and 4101 bytes into a destination of size 4096
218 | snprintf( buf2, LGST, "IMC: %s", buf );
| ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
imc.c: In function ‘void imcbug(const char*, ...)’:
imc.c:232:33: error: ‘%s’ directive output may be truncated writing up to 4095 bytes into a region of size 4090 [-Werror=format-truncation=]
232 | snprintf( buf2, LGST, " IMC: %s", buf );
| ^~ ~~~
imc.c:232:12: note: ‘snprintf’ output between 7 and 4102 bytes into a destination of size 4096
232 | snprintf( buf2, LGST, " IMC: %s", buf );
| ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


Getting a bunch of this.
Is my compiler just too new?
[Go to top] top

Posted by Fiendish   USA  (2,525 posts)  [Biography] bio   Global Moderator
Date Reply #1 on Mon 27 Apr 2020 09:25 PM (UTC)

Amended on Mon 27 Apr 2020 09:26 PM (UTC) by Fiendish

Message
Quote:
Downloaded the 1.9 SmaugFUSS

Can you provide a link?

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

Posted by Glennjoos   (10 posts)  [Biography] bio
Date Reply #2 on Mon 27 Apr 2020 11:40 PM (UTC)
Message
https://smaugmuds.afkmods.com/files/
[Go to top] top

Posted by Fiendish   USA  (2,525 posts)  [Biography] bio   Global Moderator
Date Reply #3 on Tue 28 Apr 2020 01:04 PM (UTC)
Message
It looks like that hasn't been updated in a long time. What if you try the one from this github repository, which looks like it's much more recent? https://github.com/Arthmoor/SmaugFUSS

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

Posted by Glennjoos   (10 posts)  [Biography] bio
Date Reply #4 on Wed 29 Apr 2020 02:59 PM (UTC)
Message
ok Fiendish, did what you suggested, and now...

glennjoos@ess-linux src]$ make
make -s smaug
Compiling o/imc.o....
Compiling o/act_comm.o....
Compiling o/act_info.o....
Compiling o/act_move.o....
Compiling o/act_obj.o....
Compiling o/act_wiz.o....
Compiling o/ban.o....
Compiling o/boards.o....
Compiling o/build.o....
Compiling o/calendar.o....
Compiling o/chess.o....
Compiling o/clans.o....
Compiling o/color.o....
Compiling o/comm.o....
In file included from comm.c:30:
mccp.h:18:10: fatal error: zlib.h: No such file or directory
18 | #include <zlib.h>
| ^~~~~~~~
compilation terminated.
make[1]: *** [Makefile:102: o/comm.o] Error 1
make: *** [Makefile:46: all] Error 2



But let me ask you this, I have a 1.4 mud I owned back in 2002 named Snowdens Revenge. I kinda want to get it back running, is it worth upgrading Smaug? I do have bugs now, but it runs.
[Go to top] top

Posted by Nick Gammon   Australia  (23,016 posts)  [Biography] bio   Forum Administrator
Date Reply #5 on Wed 29 Apr 2020 08:33 PM (UTC)

Amended on Thu 30 Apr 2020 03:44 AM (UTC) by Nick Gammon

Message

Install the zlib library from: https://www.zlib.net/

I had a similar problem in Ubuntu recently (because I had reinstalled it). To fix that:


- Nick Gammon

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

Posted by Fiendish   USA  (2,525 posts)  [Biography] bio   Global Moderator
Date Reply #6 on Wed 29 Apr 2020 11:25 PM (UTC)

Amended on Wed 29 Apr 2020 11:26 PM (UTC) by Fiendish

Message
Quote:
But let me ask you this, I have a 1.4 mud I owned back in 2002 named Snowdens Revenge. I kinda want to get it back running, is it worth upgrading Smaug? I do have bugs now, but it runs.

That question is a whole other kettle of fish. I would say that upgrading is definitely worthwhile. The fixes between 1.4 and 1.9 are pretty signfiicant. MCCP support wasn't added until v1.6 for instance. But I can't predict how it will affect any customizations you've made.

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

Posted by Glennjoos   (10 posts)  [Biography] bio
Date Reply #7 on Thu 30 Apr 2020 01:43 PM (UTC)
Message
Nick, I checked that first.

Last metadata expiration check: 0:19:14 ago on Thu 30 Apr 2020 10:21:21 AM EDT.
Package zlib-1.2.11-21.fc32.x86_64 is already installed.
Dependencies resolved.
Nothing to do.
Complete!


sudo yum install zlib1g-dev
Updating Subscription Management repositories.
Unable to read consumer identity
This system is not registered to Red Hat Subscription Management. You can use subscription-manager to register.
Last metadata expiration check: 0:20:43 ago on Thu 30 Apr 2020 10:21:21 AM EDT.
No match for argument: zlib1g-dev
Error: Unable to find a match: zlib1g-dev
[Go to top] top

Posted by Fiendish   USA  (2,525 posts)  [Biography] bio   Global Moderator
Date Reply #8 on Thu 30 Apr 2020 04:04 PM (UTC)

Amended on Thu 30 Apr 2020 04:05 PM (UTC) by Fiendish

Message
1. Fedora and Ubuntu don't use the same name scheme for development packages. Fedora calls it zlib-devel.
2. You should really use dnf instead of yum these days.

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

Posted by Glennjoos   (10 posts)  [Biography] bio
Date Reply #9 on Thu 30 Apr 2020 04:23 PM (UTC)
Message
ok, did all that, hopefully this is the last question.

Did the make, everything ran just fine. But, I dont see a startup file in /src. This the the git download Feindish suggested.
[Go to top] top

Posted by Glennjoos   (10 posts)  [Biography] bio
Date Reply #10 on Thu 30 Apr 2020 07:13 PM (UTC)
Message
nevermind.... chmod is your friend.

thanks for all your help.
[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.


24,444 views.

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]