Build error in OS X

The last few days, I have been getting an error message when building blender.
The error is:scons: done reading SConscript files.
scons: Building targets …
Compiling ==> ‘avi.c’
Compiling ==> ‘avi_codecs.c’
cc1: error: unrecognized command line option “-ftemplate-depth=1024”
Compiling ==> ‘avi_endian.c’
cc1: error: unrecognized command line option “-ftemplate-depth=1024”
cc1: error: unrecognized command line option “-ftemplate-depth=1024”
Compiling ==> ‘avi_mjpeg.c’
scons: *** [/Users/xxx/blender-build/build/darwin/source/blender/avi/intern/avi.o] Error 1
scons: *** [/Users/xxx/blender-build/build/darwin/source/blender/avi/intern/avi_codecs.o] Error 1
scons: *** [/Users/xxx/blender-build/build/darwin/source/blender/avi/intern/avi_endian.o] Error 1
cc1: error: unrecognized command line option “-ftemplate-depth=1024”
scons: *** [/Users/xxx/blender-build/build/darwin/source/blender/avi/intern/avi_mjpeg.o] Error 1
scons: building terminated because of errors.

I’ve done an svn update on both blender and libs, and also started with a fresh user-config file (since it has helped when I had errors in the past) but I’m still getting the error.

Does anybody know what I have to do to fix this?

Guess nobody else builds Blender on os x…

I figured out the above plus a few other issues.

Now I get:
extern/Eigen3/Eigen/src/Core/TriangularMatrix.h:444:5: fatal error: recursive template instantiation exceeded maximum depth of 128

Anybody?

Which OSx version are you running currently?

Sorry, I didn’t get a notification of your reply.

I’m on 10.9.
I got past the previous message too, but have some other error now. Don’t remember atm as I’m not at my Mac, but I’ll post it later today.