Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 129616 - games-emulation/generator version bump (to updated patch version)
Summary: games-emulation/generator version bump (to updated patch version)
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: 2006-04-11 11:14 UTC by trefoil
Modified: 2006-10-04 15:36 UTC (History)
1 user (show)

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


Attachments
generator-0.35-r2.ebuild (generator-0.35-r2.ebuild,1.65 KB, text/plain)
2006-04-24 15:46 UTC, trefoil
Details
generator-0.35-r3.ebuild (generator-0.35-r3.ebuild,1.67 KB, text/plain)
2006-09-20 10:24 UTC, trefoil
Details
generator-0.35-r3-execstacks.patch (generator-0.35-r3-execstacks.patch,563 bytes, patch)
2006-09-20 10:24 UTC, trefoil
Details | Diff
generator-0.35-r3.ebuild (generator-0.35-r3.ebuild,1.59 KB, text/plain)
2006-10-03 16:09 UTC, trefoil
Details

Note You need to log in before you can comment on or make changes to this bug.
Description trefoil 2006-04-11 11:14:22 UTC
Ebuild uses an older version of cbiere's patch. http://www.ghostwhitecrab.com/generator/generator-0.35-cbiere-r2.tar.bz2 is the
current release. Changelog as follows:

2005-09-02

    * Moved inclusion of most system header files to hdr/generator.h and added check for sys/param.h for less #include trouble.
    * Removed platform-specific versions of the SWAP16/SWAP32 macros as these were only used in two places.

2005-08-29

    * Applied another patch by Henry Pr
Comment 1 trefoil 2006-04-11 11:14:22 UTC
Ebuild uses an older version of cbiere's patch. http://www.ghostwhitecrab.com/generator/generator-0.35-cbiere-r2.tar.bz2 is the
current release. Changelog as follows:

2005-09-02

    * Moved inclusion of most system header files to hdr/generator.h and added check for sys/param.h for less #include trouble.
    * Removed platform-specific versions of the SWAP16/SWAP32 macros as these were only used in two places.

2005-08-29

    * Applied another patch by Henry Prêcheur to fix compile errors and warnings using GCC 4.0.
    * Replaced strsep() for IRIX which doesn't provide this non-standard function. Thanks to Daichi Kawahata.
    * Fixed all compiler warnings that were left over. As a side-effect some unnecessary emulator code was eliminated. Generator should now compile cleanly with "-W -Wall -Wformat=2" when using GCC.
    * Replaced all code which used snprintf() and removed the replacement implementation of snprintf() because the few uses of it are better handled by far less complex code. (Just in case: no snprintf() was replaced with sprintf().)
    * Removed the GCC compiler flag -minline-all-stringops which was quite unnecessary and is not available on all platforms. The GCC flag -ffast-math is only used for x86 machines and for Alpha -mieee is added as a precaution by default. Thanks to Alejandro.
    * Got rid of all C++ style comments for better compatibility with older C compilers.
Comment 2 Chris Gianelloni (RETIRED) gentoo-dev 2006-04-11 13:13:57 UTC
Thanks... ;]
Comment 3 trefoil 2006-04-19 13:54:51 UTC
The only ebuild modifications necessary to use "cbiere-r2" patch are to $SRC_URI and $S

I'm noticing some weirdnesses that weren't there when I compiled myself, and it appears that the configure switches are the problem. I'll test more soon.

0.35-r1, using both the original patch and the -r2, produces a QA notice:

QA Notice: the following files contain executable stacks
 Files with executable stacks will not work properly (or at all!)
 on some architectures/operating systems.  A bug should be filed
 at http://bugs.gentoo.org/ to make sure the file is fixed.
RWX --- --- usr/games/bin/generator-gtk

You probably want that in a seperate bug, right? ^_^
Comment 4 Chris Gianelloni (RETIRED) gentoo-dev 2006-04-19 16:12:57 UTC
Definitely.  Even better would be a patch attached to that bug.
Comment 5 trefoil 2006-04-19 18:08:46 UTC
I don't speak assembler, but from what I've read I may be able to fix it anyway. Bug 130539 is the new one. 
Comment 6 trefoil 2006-04-24 14:24:40 UTC
I wrote an updated ebuild, but am tearing my hair out over arrays in Bash. I could use some help - it won't iterate over the for loop, why, why... *sob*

src_compile() {
	local myconf="--with-gcc=$(gcc-major-version) \
		--disable-dependency-tracking --with-sdl-audio"
	local mygui=
	local myguis=

	use x86 \
		&& myconf="${myconf} --with-raze" \
		|| myconf="${myconf} --with-cmz80"

	myguis="sdl"
	use gtk && myguis="gtk" [ -n "${myguis}" ]
	use svga && myguis="svgalib" [ -n "${myguis}" ]
	
	for mygui in ${myguis}; do
		[[ -f Makefile ]] && make -s clean
		egamesconf \
			${myconf} \
			--with-${mygui} || die
		emake -j1 || die "building ${mygui}"
		mv main/generator-${mygui} my-bins/
	done
}
Comment 7 trefoil 2006-04-24 15:46:32 UTC
Created attachment 85387 [details]
generator-0.35-r2.ebuild

Nevermind on the last post! Attached is a working ebuild that builds multiple targets including SDL (existing ebuild is non-working in that regard), and removes old irrelevant seds. Added use flag to choose SDL as audio output, which is slower for me but might be preferable to some. Defaults to /dev/dsp. Tested both SDL and GTK versions on x86.
Comment 8 trefoil 2006-09-20 10:24:10 UTC
Created attachment 97557 [details]
generator-0.35-r3.ebuild

Here's an updated ebuild and patch, incorporating the execstacks fix and a few other things.

Unfortunately, now I get a corrupted display with both this version and the -r2 version in portage. I have no idea if it's a newer version of SDL, the execstacks patch, xorg7, or my video drivers that's causing this issue.
Comment 9 trefoil 2006-09-20 10:24:39 UTC
Created attachment 97558 [details, diff]
generator-0.35-r3-execstacks.patch
Comment 10 trefoil 2006-09-21 10:34:12 UTC
It seems my display error was caused by an old or corrupt ~/.genrc (config) file. So, no troubles now :)
Comment 11 trefoil 2006-10-03 16:09:55 UTC
Created attachment 98733 [details]
generator-0.35-r3.ebuild

Removed dependency on sed and cleaned it up a bit.
Comment 12 Chris Gianelloni (RETIRED) gentoo-dev 2006-10-04 15:36:19 UTC
Added to portage... thanks for the ebuild and the patch!