Wed 31 Aug 2016 05:55:34 PM UTC, original submission:
This comes from Chromium OS and gentoo bugs below:
https://bugs.gentoo.org/471102
https://bugs.chromium.org/p/chromium/issues/detail?id=464024
To quote a part of the CrOS bug mentioned above:
<q>
To support large device major/minor numbers that come up with some devices, stat64 has to be used instead of stat. stat will return EOVERFLOW with these large minor numbers
</q>
See also comment 4 from the CrOS bug:
<q>
another option for autoconf based packages is to use this macro in configure.ac:
AC_USE_SYSTEM_EXTENSIONS
that will turn on all the fun extensions that people generally want (GNU/LFS/etc...). if the project wants to be portable, then use this macro:
AC_SYS_LARGEFILE
do that after the call to AC_PROG_CC.
note that by switching to LFS, you might find latent bugs in the code where they use int or long to hold offsets instead of off_t, or they assume sizeof(off_t) == sizeof(long). for the most part, it probably won't be an issue, including stat() usage. just keep it in mind if you get build warnings / weird runtime crashes. in my experience, it's not generally a problem.
</q>
|