Use -std=gnu99 instead of -std=c99. c99 gives trouble with glibc.