Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 340343 - games-strategy/megaglest: new package
Summary: games-strategy/megaglest: new package
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Games (show other bugs)
Hardware: All Linux
: High enhancement
Assignee: Gentoo Games
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-10-10 13:25 UTC by Kevin R André
Modified: 2012-08-19 21:15 UTC (History)
8 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Proposed ebuild for megaglest (megaglest-3.3.7-r2.ebuild,2.49 KB, text/plain)
2010-11-28 19:14 UTC, Jean Pierre R. Mazuelos
Details
Patch file for build. (megaglest-3.3.7-r2-gentoo.patch,7.34 KB, text/plain)
2010-11-28 19:16 UTC, Jean Pierre R. Mazuelos
Details
megaglest-3.4.0 ebuild (megaglest-3.4.0.ebuild,2.40 KB, text/plain)
2011-02-07 08:18 UTC, yury fedorchenko
Details
patch for megaglest-3.4.0 (megaglest-3.4.0-gentoo.patch,5.61 KB, patch)
2011-02-07 08:19 UTC, yury fedorchenko
Details | Diff
megaglest 3.5.0 ebuild (megaglest-3.5.0.ebuild,2.36 KB, text/plain)
2011-04-24 20:31 UTC, yury fedorchenko
Details
patch for 3.5.0 (megaglest-3.5.0-gentoo.patch,3.11 KB, patch)
2011-04-24 20:33 UTC, yury fedorchenko
Details | Diff
games-strategy/megaglest-3.5.2.4.ebuild (megaglest-3.5.2.4.ebuild,4.39 KB, text/plain)
2011-09-15 22:38 UTC, Patrick McMunn
Details
games-strategy/megaglest-data-3.5.2.4.ebuild (megaglest-data-3.5.2.4.ebuild,1.16 KB, text/plain)
2011-09-15 22:39 UTC, Patrick McMunn
Details
games-strategy/megaglest/metadata.xml (metadata.xml,702 bytes, text/plain)
2011-09-15 22:40 UTC, Patrick McMunn
Details
games-strategy/megaglest-3.5.2.4.ebuild (megaglest-3.5.2.4.ebuild,4.59 KB, text/plain)
2011-09-17 01:56 UTC, Patrick McMunn
Details
games-strategy/megaglest-data-3.5.2.4.ebuild (megaglest-data-3.5.2.4.ebuild,1.38 KB, text/plain)
2011-09-17 02:04 UTC, Patrick McMunn
Details
goes in megaglest-data/files dir. / patches configuration.xml to contain correct settings for a Linux system (megaglest-linux-configuration.xml-3.5.2.4.patch,1.04 KB, text/plain)
2011-09-17 02:09 UTC, Patrick McMunn
Details
megaglest-3.6.0.1.ebuild (megaglest-3.6.0.1.ebuild,4.61 KB, text/plain)
2011-12-07 20:00 UTC, Sergi Castaño
Details
megaglest-data-3.6.0.1.ebuild (megaglest-data-3.6.0.1.ebuild,1.25 KB, text/plain)
2011-12-07 20:07 UTC, Sergi Castaño
Details
Error during build with megaglest-3.6.0.1.ebuild and megaglest-data-3.6.0.1.ebuild on amd64 (megaglest_error_build.log,9.28 KB, text/plain)
2011-12-14 17:04 UTC, RedEyedMan
Details
media-libs/ftgl added to rdepends of the ebuild (megaglest-3.6.0.1-r1.ebuild,4.63 KB, text/plain)
2011-12-14 17:17 UTC, RedEyedMan
Details
megaglest-3.6.0.2.ebuild (megaglest-3.6.0.2.ebuild,4.60 KB, text/plain)
2011-12-28 16:27 UTC, Balint SZENTE
Details
games-strategy/megaglest-3.6.0.3.ebuild (megaglest-3.6.0.3.ebuild,6.83 KB, text/plain)
2012-02-14 19:30 UTC, Patrick McMunn
Details
patch to fix compile failure during creation of manpages (megaglest-3.6.0.3-help2man.patch,4.29 KB, text/plain)
2012-02-14 19:32 UTC, Patrick McMunn
Details
Updated metadata for games-strategy/megaglest (metadata.xml,1.73 KB, text/plain)
2012-02-14 19:33 UTC, Patrick McMunn
Details
games-strategy/megaglest-data-3.6.0.3.ebuild (megaglest-data-3.6.0.3.ebuild,1.14 KB, text/plain)
2012-02-14 19:37 UTC, Patrick McMunn
Details
games-strategy/megaglest-data/metadata.xml (metadata.xml,344 bytes, text/plain)
2012-02-14 19:38 UTC, Patrick McMunn
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin R André 2010-10-10 13:25:40 UTC
Requesting an ebuild for the game MegaGlest, a fork of the RTS game Glest.

Website: http://sourceforge.net/projects/megaglest

The project's description: "Currently there is no active development of the real time strategy game glest. This project aims to improve the game and its content. It already has a lot more content than the original game and contains bugfixes and improvements."

Reproducible: Always

Steps to Reproduce:
Comment 1 Johan Bergström 2010-10-11 07:41:25 UTC
CC:ing games since they might want to pick this up.
Comment 2 Jean Pierre R. Mazuelos 2010-11-28 19:14:12 UTC
Created attachment 255751 [details]
Proposed ebuild for megaglest

I tryed it onlu in 64 bits plataform.
Comment 3 Jean Pierre R. Mazuelos 2010-11-28 19:16:28 UTC
Created attachment 255753 [details]
Patch file for build.
Comment 4 yury fedorchenko 2011-02-07 08:18:45 UTC
Created attachment 261697 [details]
megaglest-3.4.0 ebuild

version bump
Comment 5 yury fedorchenko 2011-02-07 08:19:31 UTC
Created attachment 261699 [details, diff]
patch for megaglest-3.4.0
Comment 6 Miguel Marco 2011-04-09 11:09:14 UTC
The ebuild fails if curl is instaled without the static-libs use flag. Please add it to the dependencies.
Comment 7 yury fedorchenko 2011-04-24 20:31:56 UTC
Created attachment 271041 [details]
megaglest 3.5.0 ebuild

seems to work
Comment 8 yury fedorchenko 2011-04-24 20:33:03 UTC
Created attachment 271043 [details, diff]
patch for 3.5.0

patch for 3.5.0 - seems to work, but not save settings
Comment 9 themask 2011-04-30 11:35:38 UTC
i tried to install this and when i did emerge it failed and print this:

ERROR: games-strategy/megaglest-3.5.0 failed (unpack phase):
 *   failure unpacking megaglest-data-3.5.0.1.7z
 * 
 * Call stack:
 *     ebuild.sh, line   56:  Called src_unpack
 *   environment, line 3160:  Called base_src_unpack
 *   environment, line  498:  Called unpack 'megaglest-source-3.5.0.tar.bz2' 'megaglest-data-3.5.0.1.7z'
 *     ebuild.sh, line  404:  Called die
 * The specific snippet of code:
 *   					die "$myfail"

can you help me with that?
Comment 10 Patrick McMunn 2011-09-13 18:51:16 UTC
Yury, I am working on an updated ebuild. I have successfully recreated your patches for the latest version of MegaGlest, but I don't understand what the purpose of the patch is. What is it intended to accomplish?
Comment 11 Patrick McMunn 2011-09-15 22:36:53 UTC
I have rewritten the MegaGlest ebuild. Changes include updated homepage, updated EAPI to 3 so it can handle tar.xz archives, license info, new USE flags to enable/disable external libraries or to choose a dynamic or static build, updated dependencies, installing desktop entries for all four binaries and updated icon.

I've also split the ebuild into two separate ebuilds: megaglest and megaglest-data. This was done for a couple of reasons. First, the source code is sometimes updated but relies on data from a previous version, as in for minor fixes, so this simplifies updates. But more importantly, I ran into an issue where the source and data archives unpacked into the same directory, and the CMakeLists.txt from the data archive was overwriting the CMakeLists.txt from the source archive causing make to fail during the compile phase. Splitting the ebuild resolved this issue.

Hopefully I've eliminated or at least reduced the need for patches. The ebuild only edits the global glest.ini file to point the binary to the correct data files directory. There may be another way to deal with the binary being unable to find its data files, but this seemed to be the simplest way. The only issue I'm aware of is that the megaglest_configurator binary complains that it can't find /usr/share/games/megaglest/glest.ini even though the file is located there. I also have not yet tested it on AMD64, but it seems to work fine on x86. Please test and report.
Comment 12 Patrick McMunn 2011-09-15 22:38:22 UTC
Created attachment 286595 [details]
games-strategy/megaglest-3.5.2.4.ebuild
Comment 13 Patrick McMunn 2011-09-15 22:39:10 UTC
Created attachment 286597 [details]
games-strategy/megaglest-data-3.5.2.4.ebuild
Comment 14 Patrick McMunn 2011-09-15 22:40:00 UTC
Created attachment 286599 [details]
games-strategy/megaglest/metadata.xml
Comment 15 Patrick McMunn 2011-09-17 01:53:07 UTC
I have been able to address all previously mentioned issues with the ebuild. I finally discovered the right combination of parameters to pass to cmake to make the binary know where to find its data without any need to patch the source or tinker with config files. I did have to patch the configuration.xml file which is included in the 3.5.2.4 data archive. I checked with upstream, and they said the archive only shipped with the Windows version of the file, so my patch makes it match the Linux version. This should be fixed in the next release upstream. I've also tested both 32 and 64 bit installs. On my 64 bit system, cmake configure gives some warnings about being unsure if it can find lua, libpng, and jpeg, but the compile still completes successfully. I've also experienced compile failures when enabling a debug or static build or using external miniupnpc or libircclient libraries. A standard release build compiles and runs fine, so it's unclear if this is a problem with the ebuild or a problem for upstream.
Comment 16 Patrick McMunn 2011-09-17 01:56:24 UTC
Created attachment 286727 [details]
games-strategy/megaglest-3.5.2.4.ebuild
Comment 17 Patrick McMunn 2011-09-17 02:04:04 UTC
Created attachment 286729 [details]
games-strategy/megaglest-data-3.5.2.4.ebuild
Comment 18 Patrick McMunn 2011-09-17 02:09:10 UTC
Created attachment 286731 [details]
goes in megaglest-data/files dir. / patches configuration.xml to contain correct settings for a Linux system

This patch should only be relevant for 3.5.2.4 because it should be fixed upstream in the next release (and already is in the svn trunk version).
Comment 19 Sergi Castaño 2011-12-07 20:00:47 UTC
Created attachment 295125 [details]
megaglest-3.6.0.1.ebuild

First attempt of an ebuild. Works on my amd64.
Comment 20 Sergi Castaño 2011-12-07 20:07:12 UTC
Created attachment 295127 [details]
megaglest-data-3.6.0.1.ebuild

Based on existing ebuilds.
Comment 21 RedEyedMan 2011-12-14 17:04:53 UTC
Created attachment 295825 [details]
Error during build with megaglest-3.6.0.1.ebuild and megaglest-data-3.6.0.1.ebuild on amd64

Something about enabled FTGL support and other
Comment 22 RedEyedMan 2011-12-14 17:17:33 UTC
Created attachment 295827 [details]
media-libs/ftgl added to rdepends of the  ebuild

media-libs/ftgl missed from depends of the ebuild. I added it to new megaglest-3.6.0.1-r1.ebuild.
Comment 23 RedEyedMan 2011-12-14 17:22:31 UTC
With megaglest-3.6.0.1-r1.ebuild all builded fine om my amd64 system.
Comment 24 Balint SZENTE 2011-12-28 16:27:26 UTC
Created attachment 297221 [details]
megaglest-3.6.0.2.ebuild

For the game data, renaming the megaglest-data-3.6.0.1.ebuild to megaglest-data-3.6.0.2.ebuild is enough.
Comment 25 Thomas Capricelli 2011-12-30 05:31:24 UTC
Hello

data 3.6.0.2 installed without problem.

games-strategy/megaglest-3.6.0.2 failed with

Linking CXX executable /tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/mk/linux/megaglest
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.2/../../../../x86_64-pc-linux-gnu/bin/ld: Warning: alignment 8 of symbol `ftpFindExternalFTPServerIp' in ../shared_lib/liblibmegaglest.a(miniftpserver.cpp.o) is smaller than 16 in ../shared_lib/liblibmegaglest.a(ftpRuntime.c.o)
/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.2/../../../../lib64/libxerces-c.a(ICUTransService.o): In function `xercesc_3_1::ICUTransService::lowerCase(unsigned short*)':
(.text+0x144): undefined reference to `u_tolower_48'/usr/lib/gcc/x86_64-pc-linux-gnu/4.6.2/../../../../lib64/libxerces-c.a(ICUTransService.o): In function `xercesc_3_1::ICUTransService::upperCase(unsigned short*)':
(.text+0x164): undefined reference to `u_toupper_48'
......... (lot of other similar lines)


dev-libs/xerces-c-3.1.1 was not previously installed on my system and was emerged as a dep for megaglest.
Comment 26 Balint SZENTE 2011-12-30 12:48:04 UTC
On my x86_64 system it compiles successfully with:
dev-libs/xerces-c-3.1.0  USE="iconv icu sse2 threads -curl -doc -libwww -static-libs"

What USE flags do you have for xerces-c? Do you have "icu" switched on?
Comment 27 Thomas Capricelli 2012-01-03 17:05:58 UTC
Hello,

sorry for the long delay. Here is the output of emerge -a, it seems the only difference is static-lib

[ebuild   R   ] dev-libs/xerces-c-3.1.1  USE="iconv icu sse2 static-libs threads -curl -doc -libwww"
Comment 28 Rémy DUPONT 2012-01-08 13:10:39 UTC
Hello,

I just tested megaglest-3.6.0.2 and there are errors about font loading :

megaglest v3.6.0.2
Compiled using: GNUC: 40503 [64bit] on: Jan  6 2012 11:29:18
SVN: [Rev: ] - using STREFLOP
FTGL: error loading font: (null)
[2012-01-08 13:54:54] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/shared_lib/sources/graphics/font.cpp::Font Line: 196] Error [FTGL: error loading font]
FTGL: error loading font: (null)
[2012-01-08 13:54:54] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/shared_lib/sources/graphics/font.cpp::Font Line: 196] Error [FTGL: error loading font]
FTGL: error loading font: (null)
[2012-01-08 13:54:54] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/shared_lib/sources/graphics/font.cpp::Font Line: 196] Error [FTGL: error loading font]
FTGL: error loading font: (null)
[2012-01-08 13:54:54] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/shared_lib/sources/graphics/font.cpp::Font Line: 196] Error [FTGL: error loading font]
FTGL: error loading font: (null)
[2012-01-08 13:54:54] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/shared_lib/sources/graphics/font.cpp::Font Line: 196] Error [FTGL: error loading font]
FTGL: error loading font: (null)
[2012-01-08 13:54:54] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/shared_lib/sources/graphics/font.cpp::Font Line: 196] Error [FTGL: error loading font]
void Shared::Platform::createGlFontOutlines(Shared::Platform::uint32&, const std::string&, int, float, int, Shared::Graphics::FontMetrics&) not implemented.
void Shared::Platform::createGlFontOutlines(Shared::Platform::uint32&, const std::string&, int, float, int, Shared::Graphics::FontMetrics&) not implemented.
void Shared::Platform::createGlFontOutlines(Shared::Platform::uint32&, const std::string&, int, float, int, Shared::Graphics::FontMetrics&) not implemented.
void Shared::Platform::createGlFontOutlines(Shared::Platform::uint32&, const std::string&, int, float, int, Shared::Graphics::FontMetrics&) not implemented.
void Shared::Platform::createGlFontOutlines(Shared::Platform::uint32&, const std::string&, int, float, int, Shared::Graphics::FontMetrics&) not implemented.
void Shared::Platform::createGlFontOutlines(Shared::Platform::uint32&, const std::string&, int, float, int, Shared::Graphics::FontMetrics&) not implemented.
In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/glest_game/main/main.cpp::handleSIGSEGV Line: 652] Error detected: signal 11:
Error saved to logfile [/home/dupontr/.megaglest/error.log]
[2012-01-08 13:55:02] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/glest_game/main/main.cpp::handleRuntimeError Line: 416] [In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/glest_game/main/main.cpp::handleSIGSEGV Line: 652] Error detected: signal 11:
] gameInitialized = 1, program = 0x275ce10
[2012-01-08 13:55:02] *ERROR* In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/glest_game/main/main.cpp::handleRuntimeError Line: 509] [In [/var/tmp/portage/games-strategy/megaglest-3.6.0.2/work/megaglest-3.6.0.2/source/glest_game/main/main.cpp::handleSIGSEGV Line: 652] Error detected: signal 11:

Stack Trace:
megaglest:Glest::Game::handleSIGSEGV(int) address [0x5cb621] line: 0
/lib64/libc.so.6:() address [0x7fc2f39d0b80] line: 0
megaglest:Glest::Game::Renderer::getCentered3DPos(std::string const&, Shared::Graphics::Font3D*, Shared::Graphics::Vec2<float>&, int, int, bool, bool) address [0x5786a7] line: 0
megaglest:Glest::Game::Renderer::renderTextBoundingBox3D(std::string const&, Shared::Graphics::Font3D*, Shared::Graphics::Vec4<float> const&, int, int, int, int, bool, bool) address [0x579236] line: 0
megaglest:Glest::Game::Renderer::renderButton(Glest::Game::GraphicButton*, Shared::Graphics::Vec4<float> const*, bool*) address [0x57b1c0] line: 0
megaglest:Glest::Game::MenuStateRoot::render() address [0x6ac202] line: 0
megaglest:Glest::Game::MainMenu::render() address [0x605122] line: 0
megaglest:Glest::Game::Program::loopWorker() address [0x5e49d6] line: 0
megaglest:Glest::Game::glestMain(int, char**) address [0x5d4f22] line: 0
megaglest:Glest::Game::glestMainWrapper(int, char**) address [0x5d6ed1] line: 0
/lib64/libc.so.6:__libc_start_main() address [0x7fc2f39bd09d] line: 0
megaglest() [0x4b14f9] address [0x4b14f9] line: 0
]
Segmentation fault


I can launch it with : megaglest --enable-legacyfonts

but there are some error :

egaglest v3.6.0.2
Compiled using: GNUC: 40503 [64bit] on: Jan  6 2012 11:29:18
SVN: [Rev: ] - using STREFLOP
**WARNING** Forcing Legacy Fonts Enabled
[2012-01-08 14:01:13] *ERROR* Font not found [-*-arial-*-r-*-*-84-*-*-*-*-*-*-*] trying to fallback to [fixed]
[2012-01-08 14:01:13] *ERROR* Font not found [-*-arial-*-r-*-*-84-*-*-*-*-*-*-*] trying to fallback to [fixed]
[2012-01-08 14:01:13] *ERROR* Font not found [-*-arial-*-r-*-*-86-*-*-*-*-*-*-*] trying to fallback to [fixed]
[2012-01-08 14:01:13] *ERROR* Font not found [-*-arial-*-r-*-*-92-*-*-*-*-*-*-*] trying to fallback to [fixed]
[2012-01-08 14:01:14] *ERROR* Font not found [-*-arial-*-r-*-*-97-*-*-*-*-*-*-*] trying to fallback to [fixed]
[2012-01-08 14:01:14] *ERROR* Font not found [-*-arial-*-r-*-*-90-*-*-*-*-*-*-*] trying to fallback to [fixed]

ftgl is intalled

[ebuild   R    ] media-libs/ftgl-2.1.3_rc5
Comment 29 Patrick McMunn 2012-02-14 19:30:36 UTC
Created attachment 301947 [details]
games-strategy/megaglest-3.6.0.3.ebuild

I made a lot of changes in this new ebuild. I made a much greater use of the cmake-utils eclass functions to make the ebuild smaller and neater. I added several helpful comments. I added several new use flags to make the build more configurable.

Known issues:
1) Several of the modules such as map editor, model viewer, configurator, or the tools, if disabled, will cause a configure failure.
2) If the libircclient is disabled so as to use the embedded library, a configure failure will result. For this same reason, enabling static-libs will indirectly cause a configure failure.
3) Enabling freetype but disabling ftgl will result in a configure failure.

Most if not all of the above issues appear to be upstream, after briefly discussing this in the #glest IRC channel. So I will be filing a bug on this.

4) On my system, I had compilation failures during the creation of the manpages, so I created a small patch to fix it. Feel free to try the ebuild without the patch to see if this problem affects anyone else or just my system. I'll be submitting the patch to upstream.

5) For some reason, the icons are not appearing next to the KDE menu entries on my system even though the icons are installed in /usr/share/pixmaps.

I think that covers it. Feel free to email me directly with any feedback.
Comment 30 Patrick McMunn 2012-02-14 19:32:10 UTC
Created attachment 301949 [details]
patch to fix compile failure during creation of manpages
Comment 31 Patrick McMunn 2012-02-14 19:33:28 UTC
Created attachment 301951 [details]
Updated metadata for games-strategy/megaglest
Comment 32 Patrick McMunn 2012-02-14 19:37:08 UTC
Created attachment 301953 [details]
games-strategy/megaglest-data-3.6.0.3.ebuild

I made some minor tweaks to this to mimic the cmake-utils style of the new MegaGlest ebuild.
Comment 33 Patrick McMunn 2012-02-14 19:38:20 UTC
Created attachment 301955 [details]
games-strategy/megaglest-data/metadata.xml
Comment 34 Patrick McMunn 2012-02-14 19:43:58 UTC
One last thing, as far as the libircclient-1.6 dependency, see bug https://bugs.gentoo.org/show_bug.cgi?id=403227
Comment 35 Florian Manschwetus 2012-02-20 10:26:25 UTC
the games-strategy/megaglest-data-3.6.0.3.ebuild contains an bad src-uri the first ${PN} must be a ${PN/-data/}
Comment 36 Julian Ospald 2012-08-19 21:15:58 UTC
+  19 Aug 2012; Julian Ospald <hasufell@gentoo.org> +megaglest-3.6.0.3.ebuild,
+  +files/megaglest-3.6.0.3-build.patch,
+  +files/megaglest-3.6.0.3-static-build.patch, +metadata.xml:
+  initial commit wrt #340343