index -summary -history -testscript perl / python problems -with callframes -with structures -largefile seeks -broken builds systems -freeBSD/darwin -linux/solaris -64on32 mix -distro makers -win32/other (2) libraries - libc ..(3264)
- zlib ..(-32-)
- gtk2 ..(-64-)
converting -old non-off_t code -going largefile -longlong default -face dualmode -make twinlibs -and defend (it) programming -largefile default -off_t in headers -make export64 -find mismatch -the autowrappers -environ changes -best practice? old library -dualmode renames -the extra function -largefile64_source -glibc headers -libgz example *** new library -dual export -largefiles win32 -compat32 calls -compat32 library -long32 dualmode links -some quotes -sitemap / mpl -large.file Group* -ac-archive Site*
(C) 2003-12-21 Guido U. Draheim |
largefile with auto generated wrappers
In order to enable 64bit off_t you may need to provide a few -Defines,
esp. 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. |