Summary: | games-strategy/freelords-0.3.7 does not compile with gcc-4.1; patch inside + patch for a freelordsrc problem | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Alexis Ballier <aballier> |
Component: | [OLD] Games | Assignee: | Gentoo Games <games> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | hkbst |
Priority: | High | ||
Version: | 2006.0 | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 140707 | ||
Attachments: |
The patch for compile time problems.
The freelordsrc patch. The ebuild that applies those patches. |
Description
Alexis Ballier
2006-05-16 14:25:55 UTC
Created attachment 86882 [details, diff]
The patch for compile time problems.
It's mostly trivial fixes. All changes but the "int -> long" should be arch independant.
The int -> long is an amd64 specific fix, a pointer was casted into an int, what caused a compile error. Casting it into a long fixes the issue and should also be arch independant.
Created attachment 86885 [details, diff]
The freelordsrc patch.
freelordsrc generation was not good for the savegame dir, what caused problem with perms when trying to run freelords because it tried to write to /var/tmp/portage/....
This patch simply removes the line about savegames location, by default they go to ~/.freelords/ so that solves the issue.
Created attachment 86886 [details]
The ebuild that applies those patches.
This only adds two epatch lines to the current freelords-0.3.7 ebuild.
With this, freelords runs perfectly on my system ;)
I confirm that freelords fails to compile with gcc-4.1.1 v1.5 of the ebuild freelords-0.3.7 has this line epatch "${FILESDIR}/${P}"-gcc41.patch but your new version (based on 1.4 apparently) has epatch ${FILESDIR}/${P}.gcc41.patch So apparently there are already some patches for gcc-4.1, which maybe aren't used? Should your patch be appended to this file or replace it or something other? Did you send a patch to the freelords developers? I've had a look at the patch in portage, it is the same as the one I submitted but without the amd64 fix. The dev who added this patch probably did not look for bugs here. I've not sent it upstream since it's only trivial fixes. hmm, it's been three months and this patch has still not been merged :( Specifically this patch is missing from portage: diff -N -u -r freelords-0.3.7-old/src/OptionsDialog.cpp freelords-0.3.7/src/OptionsDialog.cpp --- freelords-0.3.7-old/src/OptionsDialog.cpp 2006-05-16 22:38:32.921421416 +0200 +++ freelords-0.3.7/src/OptionsDialog.cpp 2006-05-16 22:46:17.083151544 +0200 @@ -245,7 +245,7 @@ d_smooth_scrolling->Hide(); d_show_next_player->Hide(); - unsigned int mode = (unsigned int)item->GetUserData(); + unsigned long mode = (unsigned long)item->GetUserData(); switch(mode) { Using Alexis' ebuild and patches freelords compiles and runs. I did get a segmentation fault when clicking languages. In fact 0.3.4 does not compile with gcc 4.1 either. This means that the stable ebuild cannot be compiled on a regular stable system any more :( (Unfortunately, I do not have time at the moment to see whether the patch provided applies cleanly to 0.3.4). Updated GCC 4.1.1 patch and added the other patch... emerge --sync in an hour to get the newer version... I am also marking it stable where necessary so it will work with the stable tree... |