Running OS X 10.10 w/ Apple Clang v6. I installed scons (2.3.4) and SDL (1.2.15) via Homebrew.
Upon running scons I get:
scons: Reading SConscript files ...
platform: darwin
Checking for C library dw... no
Checking for C function asprintf()... yes
Checking for inflate in C library z... yes
Checking for C library SDL... no
Did not find libSDL or SDL.lib, exiting!
Thank you for your help in advance!
Thanks for opening this issue. I no longer have access to an OSX machine (and neither do any of the other SDL devs AFAIK) so I'm unable to look into this. You might want to try clearing your scons cache . If you find a solution for your issue feel free to post it here, but I'm unable to look into this issue
Thanks for the quick answer!
In the meantime I managed to make the include and lib directories visible to scons with:
But then it halts at trying to execute
pkg-config
:Maybe someone can chip in and see if we can solve this together. In case I can solve it, I'll report back.
Thanks again!
Last edit: Audiophilip 2015-01-15
you should be able to "brew install pkg-config"
pkg-config should be a dependency in the brew recipie but I don't think it is
OK, now I have it: making sure I have both X11 and 'pkg-config` installed (actually, you get the latter as well by installing X11), I could successfully build fceux. Yay! Problem solved.
So again, for the sake of clarity: the solution to the problem in the title is: make sure to set
CFLAGS
andLDFLAGS
environment variables to the right paths before runningscons
.Last edit: Audiophilip 2015-01-19
FWIW this seems strangely familiar to me. I've debugged something related to this recently, but it was in linux. I think around that time I made some edits to the scons scripts, but I'm not sure I fixed everything. I dont remember all the details
I can't reproduce on Arch Linux, but if you are able to reproduce this on linux, let me know what distribution and version - and check that the development package for sdl is installed (the one with headers, etc) and diagnose
This bug has been sitting around for over a year now so I am going to close it. Feel free to re-open this is anyone cares, but none of the fceux team has apple hardware or access to OSX to be able to test any of this so I'm not sure how much help we can be.
I wrote a homebrew recipie for fceux while I was borrowing a mac one day and that worked at the time. I would recommend starting from there and tweaking the recipie to work for your particular version of OSX.
Just to append to the above, I also needed to set the CFLAGS and LDFLAGS, but additionally had to add import the PATH from the external environment. See http://scons.org/doc/1.2.0/HTML/scons-user/x1673.html I use Mac Ports which installs most things under /opt/local. Blank environments rarely include that by default.
I wound up using the line env = Environment(options = opts, ENV=os.environ), though I suspect env = Environment(ENV = {'PATH' : os.environ['PATH']}) is sufficient.
Last edit: Tom Piercy 2017-08-20