Make/Install problems

NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Forum rules
NOTICE: This forum is archived as read only.
Please use the Github Discussions at https://github.com/exult/exult/discussions
Locked
Stu

Make/Install problems

Post by Stu »

Hello all,

First off, sorry for the noobish questions. I am both an Exult and Linux newbie, so please bear with me.

I have the Ultima files, directories, SDL, and SDL_mixer all setup and installed without a problem, yet when I do a "make" or "make install" in the exult directory I keep getting a pngio.cc error.

.src=exult-1.2

"pngio.cc: In function `int Import_png8(const char*, int, int&, int&, int&,
int&, int&, unsigned char*&, unsigned char*&, int&)':
pngio.cc:95: error: invalid conversion from `long unsigned int*' to `
png_uint_32*'
pngio.cc:95: error: invalid conversion from `long unsigned int*' to `
png_uint_32*'
pngio.cc: In function `int Import_png32(const char*, int&, int&, int&, int&,
int&, unsigned char*&, bool)':
pngio.cc:322: error: invalid conversion from `long unsigned int*' to `
png_uint_32*'
pngio.cc:322: error: invalid conversion from `long unsigned int*' to `
png_uint_32*'
make[2]: *** [pngio.lo] Error 1"

Do I just have a picky compiler or is there an actuall line error that needs to be fixed? I'm lost guys, please help me on this. Am I missing a library?

I'd hate to have to run it in windows. :)

btw: I am running a fully up to date Suse 9.2 distro, if that is any help at all.

Thanx
zosX

Re: Make/Install problems

Post by zosX »

I dunno. You are probably missing some libraries. It should compile ok on GCC 3. Do you have SDL and the appropriate dev libraries? You need dev libraries for libc, sdl, and a few other dev libraries. Dunno about the png error, but I'm guessing it is referencing some library you do not have that decodes png files. Does SDL do this in exult? Yeah, I'd guess your GCC toolkit is not complete or your are missing the needed dev libraries that exult is linked against, or your lib path is all fuxed up. :P

Suse should offer most everything you need in package form, if not, RPMs are the easiest package to find out there in the wild, though I prefer source myself.

Also, did you run configure first? It should compile cleanly if you pass a autoconfig.....
Stu

Re: Make/Install problems

Post by Stu »

*sigh*

I just don't know. I have the sdl 1.2 lib, the mixer, gcc is up to date, glibc is up to date. Everything seems fine.

Configure has a few no's listed when it runs but nothing crucial. It configures and exits fine. Just when I get to install I get the fatal png errors. Tried installing as root just to check, no dice there.

I have no idea whats going on with this problem.
Gradilla Dragon
Posts: 468
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Gradilla Dragon »

Hmm... are you in a 64 bit architecture? unsigned long int might be a 64 bit data type in 64 bit architectures, and by the name png_uint_32 I guess it's meant to be a 32 bit data type, so the pointers aren't likely to be compatible.

Please create a file called sizeTest.c with the following code:
===
#include
#include

int main(){
printf("long unsigned int: %d bits\n", sizeof(long unsigned int)*8);
printf("long unsigned int*: %d bits\n", sizeof(long unsigned int*)*8);
printf("png_uint_32: %d bits\n", sizeof(png_uint_32)*8);
printf("png_uint_32*: %d bits\n", sizeof(png_uint_32*)*8);
}
===
Compile it this way:
gcc -o sizeTest sizeTest.c

now run it:
./sizeTest

long unsigned int and png_uint_32 should have a size of 32 bits. Also, long unsigned int* should have the same size as png_uint_32*.
Please post the results of that program.
- Gradilla Dragon
Colourless
Site Admin
Posts: 731
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Colourless »

Install the latest version of Lib PNG. I think the problem is due to using an old version...

Or the problem is Exult is coded to use an old version... but I'm pretty sure that's not it.

Or, you could compile without Exult Studio support and everything will be fine then.
Stu

Re: Make/Install problems

Post by Stu »

Okay guys,

Gradilla, as you predicted the results were 32 bits across the board. Here is the output of ./sizeTest
"
long unsigned int: 32 bits
long unsigned int*: 32 bits
png_uint_32: 32 bits
png_uint_32*: 32 bits
"

I am running a full Suse 9.2 install on an IBM T30 laptop (1.8 GHz P4) so the environment should be 32 bit, right?

Colourless, I am still trying to track down the latest Lib PNG. Should I check sourceforge? I am having no luck finding it on the Suse site.

When I do a configure I get this output at the end:
"
Exult v1.2

SDL ....................... : 1.2.8
Build tools................ : yes
Build ExultStudio.......... : no

Now type 'make' to build Exult
"

So, how exactly do I compile without studio support?

Btw: I would be more than happy to post any outputs you guys need to see, configure or otherwise. Just let me know.

This is driving me crazy. lol. I am determined to get this to work though. I really appreciate all of the help guys. Sorry I am not more knowledgeable about this stuff.
Stu

Re: Make/Install problems

Post by Stu »

Okay, I found the libpng stuff on sourceforge.

My current setup is:
libpng 1.2.6-4
libpng-devel 1.2.6-4

Sourceforge has these files:
libpng 1.2.8
libpng-devel 1.0.18 (I wonder how Suse YaST2 has a newer devel than sourceforge?)

So which do I need? Also, is there any trick I need to know to installing them? Like which directory do I need to install out of and do I need to be root?

Thanks so much for the help guys.
amber

Re: Make/Install problems

Post by amber »

well stu i dont know that stuff im just replying cause u made me look at your posts and i felt like sticking my name somewhere
Colourless
Site Admin
Posts: 731
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Colourless »

Ah, Exult studio isn't building, so it's going to be in the tools. If you disable building the tools, exult 'should' build fine. But i don't know how the Exult Linux make system works so I can't help very much.
Stu

Re: Make/Install problems

Post by Stu »

Bingo!

Okay guys, I installed the latest libpng(1.2.8) and ran another configure.
Make worked. Make install worked.

Yay!

So now I am off to figure out the rest of this stuff. lol. Btw: Will the Roland sound and music files work with exult-1.2? Doc say only 1.1, but I don't see why they shouldn't work with 1.2.
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Dominus »

yeah, it's meant to say it needs 1.1 and higher.
Glad it built now for you.
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Stu

Re: Make/Install problems

Post by Stu »

I have read-tfm about 6 times so far. :)

...and the faq.

Okay. Now when I run exult (to generate my exult.cfg) it crashes my entire system. Black screen of death. Impressive. First time I have crashed Suse 9.2

*sigh* ...obviously I have read the faq and the documentation about this, have'nt figured it out yet. Any advice guys? Besides give up. :-P
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Dominus »

wow, that is not bad at all. Uh, actually bad, but ... wow...
Sorry no clue about this. I only tried Exult once on Suse 9.0 or 9.1 and with the official RPM for 1.2, but it worked with that.
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
Stu

Re: Make/Install problems

Post by Stu »

Holy

freakin

crap!

There is an exult-1.2.rpm? Good lord somebody gimme a link please!
btw: If I run exult from Konqueror instead of terminal it does not crash my system but it still just sits there at a black screen. And when I said crash I meant hold down the power button for 10 seconds to turn off the comp crash. :-P FAQ says change the fullscreen or res settings in .cfg, but ofcourse I can't generate .cfg until I run exult and quit.

Yes, I am totally willing to try an rpm at this point. Somebody throw me a link and save my sanity.
Stu

Re: Make/Install problems

Post by Stu »

haha! Okay I downloaded the rpm. Then I ran "rpm -ivv exult-1.2-1.src.rpm" as root. It stuck a tar.gz file in /usr/src/packages/SOURCES, and an exult.spec file in /usr/src/packages/SPECS

Now what the heck do I do? Sorry, I have never manually installed an rpm before.
Gradilla Dragon
Posts: 468
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Gradilla Dragon »

You got the wrong rpm. You were supposed to download the Fedora Core 1 binary rpm.
- Gradilla Dragon
Stu

Re: Make/Install problems

Post by Stu »

Gradilla-

Stupid question I am sure, but isn't fedora core Redhat? I mean, is that gonna run on Suse?
Gradilla Dragon
Posts: 468
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Gradilla Dragon »

It might work. Give it a try ;)
- Gradilla Dragon
Stu

Re: Make/Install problems

Post by Stu »

Same black screen. I give up. lol. Thanks guys.
Gradilla Dragon
Posts: 468
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Gradilla Dragon »

Well, lets see...

When the black screen is shown, press Alt+X several times and see if it quits. If so, you should have a .exult.cfg file in your home directory. Edit it to set fullscreen to "no", and run exult again.
- Gradilla Dragon
Dominus
Site Admin
Posts: 5656
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Dominus »

The Fedora RPM ran fine on my Suse system (9.0 or 9.1). You have to use Yast to install it.
When you look for the cfg file make sure you can view hidden files and that it is .exult.cfg and not just exult.cfg(as on Windows).
--
Read the documentation and the FAQ! There is no excuse for not reading them! RTFM
Read the Rules!
We do not support Piracy/Abandonware/Warez!
zosX

Re: Make/Install problems

Post by zosX »

Sounds like your X11 implementation doesn't like fullscreen SDL or something. I don't know how that stuff is configured in SuSE myself, since everything I run linux on is debianized. You should be able to CTRL+ALT+F1 to get to a console with a login. From there you should be able to kill your X server and respawn it until you get a configration that works. I'd be very suprised if a userland app completely crashed the kernel. In any case, you'd see a kernel panic and not a blank screen. No it seems like something is wrong with the app or its configuration. I'd try windowed mode first and work it out from there. Correct me if I'm wrong (I've never used SDL on linux personally) but doesn't SDL just draw over the entire X server or does it actually gain framebuffer access and can change resolutions etc? I've played with SNES9X in Linux (its really slow IMHO) and it seems to just draw over whatever resolution you are using. So, if you were running 1024, screen refreshes would naturally be fairly slow.

Also, you can switch resolutions on the fly with X, by pressing CTRL+ALT++ Or was that CTRL++? Anyways, it will cycle through whatever resolutions you have enabled in your XFree86.config.

zos
Gradilla Dragon
Posts: 468
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by Gradilla Dragon »

SDL changes the video mode if you have it configured as one of the resolutions you can switch to when pressing Ctrl+Alt+'+' and Ctrl+Alt+'-'. SDL requests a certain resolution, and if you don't have it, it switches to the smallest one where the requested resolution would fit. For example, if it requests for 320x240 and you don't have it but do have 400x300, SDL will use 400x300 and display in a 320x240 canvas centered on the screen.
- Gradilla Dragon
Stu

Re: Make/Install problems

Post by Stu »

Well, got it up and running on the exact same comp running the windows binary(dual boot) in about 1 minute. I refuse to allow windows to control my gaming destiny though....

Uninstalled and reinstalled the fedora rpm, using Yast. I even have a nifty "role playing" selection under my games directory that starts Exult. So now we have a windowed exult running, doing nothing but being black. Ctrl+Alt(+ or -) has no apparent effect whatsoever(probably because I have only one resolution setup, LCD 1024x768). Alt+x does nothing.

Running as root through terminal shows no .cfg or .exult.cfg

An interesting thing is I too run SNES9X through my linux and that works just fine. Though it will not run in fullscreen, even as root.

The only thing I can think of is x11. I mean, if sdl works with other apps, why not exult. Also, compiling from source (configure, make, make install) worked after libpng updating. So it's got to be a configuration conflict, right?

I dunno. I am pretty clueless about this stuff. I will try messing with the xserver and see what happens, otherwise I am at a dead end trying to figure this out. Finals week is eating all 5 of my good braincells....
Stu

Re: Make/Install problems

Post by Stu »

Yeah, thats gotta be it. I'm still just stabbing in the dark, but I got exult to start running from single user mode. Ofcourse it told me it could not find the game files, but hey, it worked.

So what now guys? Single user mode it works. How do I get it running under KDE?
Stu

Re: Make/Install problems

Post by Stu »

after single user startup I checked the .exult.cfg

fullscreen was already set to no. So it is not .cfg

lol. Guess I will wait till somebody posts.
zosX

Re: Make/Install problems

Post by zosX »

Stu,

I wish I could help you more, but I've never played with Exult in X11 before. I've helped some people compile it for linux and have compiled it myself a few times, but never did get to try it in Linux since all of my client PCs are all running windows around here.

You say fullscreen is disabled and it still will not work? Sounds like KDE (though it is probably more of a problem with X, KDE just adds a lot of candy to the windows, X actually renders them) and SDL are not getting along very nicely. so, yeah, if you are compiling the source without error and installing the RPM without error then indeed it is a problem with your X config or something, but hey, I'm certainly not a linux expert. Since Linux is the preferred OS for a lot of people on this forum, surely someone else has had similar problems. Does SDL try to render directly to the framebuffer? Your situation is certainly puzzling.

Stu, why not try to search the forum for problems with X in the past. I'm sure that you are not the first to encounter this. I really, truly wish I could help more, but without actually looking at your box all I can do is speculate.

Why not post your Xfree8.config from /etc/ here? It may shed *some* light on your situation or something.

zos
drcode
Site Admin
Posts: 2267
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by drcode »

Just some random thoughts:

1. SDL does write directly to the frame buffer. Do you know what your screen depth is (typically 16, 24, 32)?

2. If Exult is compiled with ES support, it tries to read/write through a socket. Maybe this is causing problems on your system. ExultStudio support can be disabled as a 'configure' option when you build from source.

3. You might try disabling audio and scaling to try to narrow down the problem.

4. I normally run KDE and never have problems with Exult in windowed or full-screen mode, so I don't think the problem is with KDE. The only times I crashed my whole system were when I was playing with OpenGL.
zosX

Re: Make/Install problems

Post by zosX »

Yeah, I really gotta agree with the Doc here. Since it uses the framebuffer (thanks for clarifying!) you most likely have issues with the X server itself and not KDE. Please realize that the two are seperate and X is what makes it all possible. X is not the GUI, but more importantly it draws the GUI. Maybe you need to try rolling your own video drivers or something, depending on what sort of video card you are using. Colour depth could be a problem too, especially if Exult is looking for 32 bit colour to draw too. Like I said, it would be interesting to see your X config file.

(and if you ask why I am trying to help, it is because I've asked silly questions in the past about linux related issues and got nothing but short, cold, unhelpful comments from other groups of people, especially from supposed
"help" groups, irc and whatnot, I'll take the time to help some ultima fans out and also I feel kinda bad about ranting n your board the other night, so there, please accept my apologies.....) :P

Godspeed!

zos
Stu

Re: Make/Install problems

Post by Stu »

no prob zos. We are all due the occasional rant. :)

I will in fact post the xconfig, promise. I'm just in the middle of finals right now, one of which is operating systems(1 week to cover all things MS, 13 weeks of fedora core 2, yay!), so give me a little bit of time to gather my sanity and pass these sadistic courses.

...see, now I am ranting. lol

One thing I think may be causing a problem is the fact that this notebook runs an ATI (7500 something I believe) video card, which I know is a picky beast when it comes to drivers.

I will return...
zosX

Re: Make/Install problems

Post by zosX »

Ooooooh, the ATI in linux huh? I've only heard mixed things. Maybe your DRI is not right or something. Yeah man, take your time. I'm not really in a big hurry or anything. :P
nadir
Site Admin
Posts: 407
Joined: Thu May 14, 2020 1:34 pm

Re: Make/Install problems

Post by nadir »

A Radeon 7500 is nothing special: it is a reasonably supported card by open source drivers (i.e. plain old Xorg or XFree86 should work fine). DRI is only useful for accelerated 3D, and Exult doesn't use any of that (yet :) ).

Also, SDL writes directly to the framebuffer only in DGA mode, which it is allowed to use only when run as root (or with the suid bit on).

Run xdpyinfo from a terminal and paste your output here.
Locked