News:

If you like the game and can afford to, please donate to support MegaGlest.

Main Menu

Fedora RPM

Started by gauret, 5 November 2006, 23:08:58

gauret

Hi,

I'm trying to make an RPM for Fedora Core 5, and it fails to build the map editor :
$ jam
...found 410 target(s)...
...updating 1 target(s)...
LinkApplication glest_map_editor
/usr/lib/gcc/i386-redhat-linux/4.1.1/../../../crt1.o: In function `_start':
(.text+0x18): undefined reference to `main'
collect2: ld returned 1 exit status

    g++ -o glest_map_editor   ./build/i386-redhat-linux-gnu/optimize/shared_lib/sources/libglestlib.a   -L/usr/lib -lSDL -lpthread -lGL  -lm -lGLU -lGL  -lm -lxerces-c -lpthread -L/usr/lib -lvorbis -lm -lvorbisfile -L/usr/lib -logg -lopenal -pthread -lwx_gtk2u_gl-2.6 -lwx_gtk2u_xrc-2.6 -lwx_gtk2u_qa-2.6 -lwx_gtk2u_html-2.6 -lwx_gtk2u_adv-2.6 -lwx_gtk2u_core-2.6 -lwx_baseu_xml-2.6 -lwx_baseu_net-2.6 -lwx_baseu-2.6

...failed LinkApplication glest_map_editor ...
...failed updating 1 target(s)...


My GCC is 4.1.1.
Any idea ?

Thetargos

#1
Do you have all required dependencies satisfied? SLD-devel packages, openal-devel packages, etc? You can install most of them with Yum.

gauret

#2
I'm sorry, it was due to my very particular setup. My Mesa sources did'nt match the binaries.
It now builds fine (on FC6). If everything works as expected, Fedora will soon be shipping glest :)

Thetargos

#3
Quote from: "gauret"I'm sorry, it was due to my very particular setup. My Mesa sources did'nt match the binaries.
It now builds fine (on FC6). If everything works as expected, Fedora will soon be shipping glest :oops:

Thetargos

#4
How did you build it, did you also build the xerces-c dependency as RPM?

gauret

-
#5
Yes, I just took the xerces-c rpm from Dag, did a few cleanups, compiled it and used it. You can find it here :
[url=http://gauret.free.fr/fichiers/rpms/fedora/xerces-c-2.7.0-1.src.rpm]http://gauret.free.fr/fichiers/rpms/fed ... -1.src.rpm[/url]

The src.rpm for the game are here :
[url=http://gauret.free.fr/fichiers/rpms/fedora/glest-2.0.0-1.src.rpm]http://gauret.free.fr/fichiers/rpms/fed ... -1.src.rpm[/url]
[url=http://gauret.free.fr/fichiers/rpms/fedora/glest-data-2.0.0-1.src.rpm]http://gauret.free.fr/fichiers/rpms/fed ... -1.src.rpm[/url]


It needs a few fixes yet, for exemple I'd like to make Glest look for a log file in the users's home directory ( ~/.glest/glest.log ) instead of the game directory, which is not normally writable by users.

Thetargos

#6
Interesting, I may take a look at your src.rpms, do you know of any problems for building on x86_64? 'cause that's what I have.

wayward

#7
]I'm sorry, it was due to my very particular setup. My Mesa sources did'nt  match the binaries. It now builds fine (on FC6). If everything works as expected, Fedora will soon be shipping Glest

 I'm haviing a prob myself with the depends... wrote a note on the Fedora-Games forum.
Is it SLD or SDL lib-devel? Looks like a really good project and  I have some ideas for it. Do you think it would run on a dedicated $100 laptop, from that project? I would want to strip out everything from the install, except just what Glest would barely need to run with a wireless connect to a large server. It's resolution isn't great, the specs are at
http://www.ted.com

Lemme know what you think. Ric[/url]

gauret

-
#8
The srpms are here :
[url=http://gauret.free.fr/fichiers/rpms/fedora/glest-2.0.0-1.src.rpm]http://gauret.free.fr/fichiers/rpms/fed ... -1.src.rpm[/url]
[url=http://gauret.free.fr/fichiers/rpms/fedora/glest-data-2.0.0-1.src.rpm]http://gauret.free.fr/fichiers/rpms/fed ... -1.src.rpm[/url]

They build in "mock", which means the BuildRequires are correct.

I have no idea if they will work on a $100 laptop, I guess it mainly depends on the video card for 3D.

Thetargos

#9
Indeed. If used Intel i9x video, it may actually play rather well at say 800x600 resoultion. By the way I could not find the specs of said laptop (I assume it is like OLPC one) in the link you provided.

gauret, I had trouble getting the .src.rpms from your links (404 errors), will try with these new links you provided.

Edit
The download seems to be working now, thanks. I had trouble getting the glest-data src.rpm.

gauret

-
#10
Yeah, I had trouble uploading this big package at some point.
You may also need :
[url=http://gauret.free.fr/fichiers/rpms/fedora/xerces-c-2.7.0-1.src.rpm]http://gauret.free.fr/fichiers/rpms/fed ... -1.src.rpm[/url]

Thetargos

#11
I already have that installed. Thanks. I need to take a look at your glest-data spec as I'm having trouble running glest with the rebuilt src.rpm of the binary. Also it would look like the data package overrides the Linux-specific glest.ini (will have to look more carefully, maybe I "contaminated" the sources).

gauret

-
#12
Quote from: ThetargosI need to take a look at your glest-data spec as I'm having trouble running glest with the rebuilt src.rpm of the binary. Also it would look like the data package overrides the Linux-specific glest.ini (will have to look more carefully, maybe I "contaminated" the sources).

In the glest-data spec file : [url=http://gauret.free.fr/fichiers/rpms/fedora/glest-data.spec]http://gauret.free.fr/fichiers/rpms/fed ... -data.spec[/url] you can see that the provided glest.ini file is removed line 35.
In the main glest spec file : [url=http://gauret.free.fr/fichiers/rpms/fedora/glest.spec]http://gauret.free.fr/fichiers/rpms/fedora/glest.spec[/url] the linux-specific glest.ini file is installed in the build root on line 50.

So probably something specific to your setup. Try to reinstall both rebuilt rpms and to remove your ~/.glest dir (backup it just in case...)

Thetargos

#13
Indeed... Apparently apprently my SOURCES directory was messed up, nothing an rm -rf woudln't solve, though.

martenzo

#14
Is there a normal rpm in sight? As in not .src.rpm but just .rpm . I can't install form source (I'm trying to follow the instructions in docs but they're obviously outdates, as there is no ./configure in mk/linux/)

gauret

#15
As soon as it is accepted in Fedora, it will be available just like any other package.
In the meantime, you can rebuild the src.rpms using this procedure :
 1. Install the package "rpmdevtools"
 2. Run "rpmdev-setuptree"
 3. Download the two src.rpm
 4. Run "rpmbuild --rebuild glest-*.src.rpm"
 5. If it asks for additional packages, install them and go back to 4.
 6. The rebuilt rpms are in ~/rpmbuild/RPMS, install them

If you don't have xerces-c installed already, you'll have to rebuild and install it using the src.rpm I provided and the same procedure.

Thetargos

#16
You just have to have all the deps that the docs say and get the src.rpm, then you just have to:
rpmbuild --rebuild <package>.src.rpm
and that should be it. It should generate two rpms: glest-2.0.0.<arch>.rpm and glest-debuginfo-2.0.0.<arch>.rpm (or something along those lines)

Edit
Ooops, did not see your answer...

By the way, will you be submitting both packages to Extras, glest and xerces-c?

gauret

#17
Quote from: "Thetargos"By the way, will you be submitting both packages to Extras, glest and xerces-c?

Already done :
glest: https://bugzilla.redhat.com/bugzilla/sh ... ?id=216130
glest-data: https://bugzilla.redhat.com/bugzilla/sh ... ?id=216131
xerces-c: https://bugzilla.redhat.com/bugzilla/sh ... ?id=210553

Thetargos

#18
I've read the submissions, apparently the bulk of the discussion is about the xerces-c package and the samples, I suppose that inclussion to Extras of Glest will be determined of when will xerces-c submission will be accepted. Is this the case?

gauret

#19
Yes. Glest depends on xerces-c to build, so xerces-c must enter first.

Thetargos

#20
I see... Were you able to determine the best way to have Glest look at $HOME/.glest/glest.ini and make the needed directory or copy the file to that location if the file does not exist? I'm not so much of a coder, but I scanned through the source code and couldn't determine how could this be done, I wonder if by means of launcher script these parameters could be set? Just pondering on it, I may finally have the motivation to learn C++ :D

gauret

#21
Quote from: "Thetargos"Were you able to determine the best way to have Glest look at $HOME/.glest/glest.ini and make the needed directory or copy the file to that location if the file does not exist?

I asked the games gurus at Fedora and they came up with a great idea. The glest executable in /usr/bin is actually a shell script which creates ~/.glest if it does not exist, cd in this directory, symlinks the data directories from /usr/share/glest, copies the /usr/share/glest/glest.ini (setting the resolution to the one you're using and the language to your current language) if it did not exist, and runs the game. It works just fine, and does not use more disk space than necessary.
The SuSE packager already did this kind of script too, so I borrowed some code from him also.

As a result, you just install the rpm, click on the glest icon in the games menu, and there you go :)

Thetargos

#22
I was thinking of something of the sort... Excellent idea. Reminds me a lot of how other games work, like UT series and Quake and Doom.

ElGranPepe

#23
I'm sorry, it was due to my very particular setup. My Mesa sources did'nt match the binaries.
It now builds fine (on FC6). If everything works as expected, Fedora will soon be shipping glest  :(  :D  :?  8)  :lol:

gauret

#24
Glest has just passed QA, which means Fedora 6 users will be able to simply install the glest package in a day or two !