I wasn't going to ask this because I thought it was peculiar to my custom build environment, but I discovered this is no longer true. If I manually call gcc to compile a file that uses the atomic built-in __sync_add_and_fetch, it compiles and links fine. But if I use it in an autotool'd project, linking will fail complaining that __sync_add_and_fetch doesn't exist. No custom march or cflags are being set. How is this possible? O_o Is there anyway that GCC will choose to compile with atomic builtins disabled without specifying a march flag? I've tried the manual compile with/without -D_REENTRANT, -g, and -O2 and it makes no difference. Always succeeds. The only other thing I can think of is that somehow what is *linked* against can cause GCC to drop atomic builtins. Is this known to happen? The implication is my configure test for the presence of __sync_add_and_fetch always succeeds even though my app won't build, defeating its point.