ZSNES FTBFS

Hans de Goede j.w.r.degoede at gmail.com
Sun Sep 4 19:40:07 CEST 2011


Hi,

On 09/04/2011 04:39 PM, Andrea Musuruane wrote:
> Hi,
>      I was going to update ZSNES to explicitly requires pulseaudio-libs
> (BZ #1926) and I found out that ZSNES doesn't compile with gcc 4.6.0
> (F15+).
>
> The buildlog is here (for devel):
> http://buildsys.rpmfusion.org/logs/fedora-development-rpmfusion_free/10187-zsnes-1.51-8.fc16/i686/build.log
>
> The problem seems to be that _FORTIFY_SOURCE breaks parsegen:
> https://bugs.launchpad.net/ubuntu/+source/zsnes/+bug/819774/comments/8
>
> Ubuntu *fixed* this disabling _FORTIFY_SOURCE for parsegen. This is
> not permitted in Fedora. Unluckily I don't have the necessary
> knowledge to fix this myself.
>
> Any help is appreciated.

Hmm, the problem is some auto-generated code, making this not easy and the
error is rather obscure too.

Attached is what I believe is an elegant solution, which only disables
FORTIFY_SOURCE for the auto-generated files. I believe it is even
suitable for sending upstream.

Regards,

Hans
-------------- next part --------------
diff -up src/parsegen.cpp~ src/parsegen.cpp
--- src/parsegen.cpp~	2011-09-04 19:24:34.000000000 +0200
+++ src/parsegen.cpp	2011-09-04 19:34:58.509204919 +0200
@@ -662,6 +662,7 @@ void output_parser_start(ostream& c_stre
            << "Config file handler generated by Nach's Config file handler creator.\n"
            << "*/\n"
            << "\n"
+           << "#undef _FORTIFY_SOURCE\n"
            << "#include <stdio.h>\n"
            << "#include <stdlib.h>\n"
            << "#include <ctype.h>\n"


More information about the rpmfusion-developers mailing list