In order to enable 64bit off_t you may need to provide a few -Defines,
esp. "-D_FILE_OFFSET_BITS=64"
. The AC_SYS_LARGEFILE macro
will generally take care of that and put a #define in your config.h
file. Just include it as the first #include of your sources which you
should do anyway.
However, that might not be so easy if the thing to compile happens to be source file automatically generated by a wrapper generator. Those tend to put their own wrapper-include first and whenever that one does include some system include then it may also have gone to include the system feature.h file which does react to the magic defines - but only once. A later include of "config.h" does have no effect then.
There, you need to look at a few options. First, you may try to omit the generation of config.h altogether, the autoconf system will then add all config.h #defines to CFLAGS automatically. If you need to set some AC_CONFIG_HEADER for another part of your code, then you might try to add the needed -Defines yourself to CFLAGs in the configure script. That needs some minimal knowledge on the ac-cache variables involved but a look at the definition of AC_SYS_LARGEFILE will help here.
If you have some special build setup, you may also look for an equivalent of `gcc -imacros config.h` or `gcc -include config.h`. However, such stuff is not particularly portable. Patching up the generated source files may turn out to be even more portable than that. But before attempting that one, you should check in-depth the documentation of the wrapper-generator - sophisticated systems like SWIG allow to add pre-include code with a special syntax. And if it is not there - go and file a bug with the maintainer of the wrapper generator. May be point him to this site to raise awareness for the problems involved with using largefile on some systems.