The patch that moves "config.h" to the top of scanner.l (and hence
scanner.c) has to happen before the files are pregenerated, otherwise
there is an error on AIX:
In file included from scanner.c:2792:
/usr/include/unistd.h:171: error: conflicting types for 'lseek64'
/usr/include/unistd.h:169: error: previous declaration of 'lseek64' was here
On AIX, config.h defines _LARGE_FILES. This interacts badly with other
includes generated at the top of scanner.c, leading to errors like this:
In file included from scanner.c:2784:
/usr/include/unistd.h:171: error: conflicting types for 'lseek64'
/usr/include/unistd.h:169: error: previous declaration of 'lseek64' was here
In file included from /usr/include/unistd.h:746,
from scanner.c:2784:
/usr/include/sys/lockf.h:64: error: conflicting types for 'lockf64'
/usr/include/sys/lockf.h:62: error: previous declaration of 'lockf64' was here