This appears to work. I have pushed a change to metis.py to do this define the Mac. We should eventually have BuildSystem check for __thread but I'm too lazy to do that today.> Can you pass it in through the CFLAGS environment variable as is? (Ugly, but I think CMake claims to respect that variable.)