Menu

#675 FCEUX 2.2.2 does not compile on Mac OS X Yosemite via Homebrew

SDL
closed:fixed
9
2016-03-29
2014-10-21
Nate
No

I attempted to install FCEUX on Mac OS 10.10 Yosemite after upgrading this evening and was unable to get it to compile after running brew install fceux. I received the following error.

==> Patching
patching file SConstruct
patching file SConstruct
patching file src/drivers/sdl/SConscript
==> /usr/local/opt/scons/bin/scons
#include <SDL SDL.h="">
         ^
1 error generated.
scons: *** [src/drivers/sdl/input.o] Error 1
scons: building terminated because of errors.

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/homebrew/homebrew-games/issues

When I ran ssl-config --cflags --libs, I got the following:

-I/usr/local/include/SDL -D_GNU_SOURCE=1 -D_THREAD_SAFE
-L/usr/local/lib -lSDLmain -lSDL -Wl,-framework,Cocoa

It appears that the file sdl-video.cpp under src/drivers/sdl was referencing SDL using #include <SDL/SDL.h>, but the path already included SDL. I was able to change the line to #include <SDL.h>. I then created another tarball with the updated code, copied it over the existing tarball, updated the formula with the new SHA and was able to compile and install the package.

The issue was line 6 of sdl-video.h

- #include <SDL SDL.h="">
+ #include <SDL.h>

Let me know if you guys have any questions.

Thanks,
Nate

Discussion

  • zeromus

    zeromus - 2016-03-29

    testing posting to a random thread
    by the way, we won't apply this patch. the problem is in the build script, not the source file, which builds fine on plenty of platforms.

     
  • Lukas Sabota

    Lukas Sabota - 2016-03-29

    Applied a patch in r3202 to resolve this. We use "#include<SDL.h>" in sdl.h so I don't see a problem doing it in sdl-video.h.

    That being said; there is no reason OSX/Homebrew shouldn't support "#include<SDL SDL.h="">" which is where the header is supposed to be installed. You should also file a bug with homebrew sdl recipe if you care about that.

    Fixed in r3202 to get around homebrew's broken SDL installation only because this should not break any other build targets.

     

    Last edit: Lukas Sabota 2016-03-29
  • Lukas Sabota

    Lukas Sabota - 2016-03-29
    • status: open --> closed:fixed
    • assigned_to: Lukas Sabota
    • Priority: 7 --> 9
     

Log in to post a comment.