tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Is statfs() still supposed to be in libc?



On 03/27/18 10:54, Kamil Rytarowski wrote:
On 27.03.2018 17:29, Jason Bacon wrote:
While upgrading ncbi-blast+, I looked deeper into a workaround for a
statfs() issue.  The blast configure script incorrectly determines that
statfs() is supported on NetBSD, when in reality is was deprecated and
removed from the API a long time ago, superseded by statvfs().

However, the statfs() function is still in libc and this is all the
configure script checks for.

Is statfs() still needed internally, or should it be removed from libc
at this point?

statfs() is supported internally as a compat symbol and shall not be
used by a newly compiled code.

Every user is mandated to migrate to statvfs().

With a libc major bump, statfs() will likely disappear, although we will
keep maintaining it in the kernel compat layer.

Thanks.  I'll propose a patch to NCBI to make their configure script a little smarter.  Their code already supports statvfs(), but it tries to use statfs() on NetBSD simply because it's present in libc.

For now, we hack around it with

.if ${OPSYS} == NetBSD
# statfs is deprecated on NetBSD, but still exists in libc
# configure checks only for undefined reference, not for usability
CONFIGURE_ENV+=         ac_cv_func_statfs=no
.endif


Home | Main Index | Thread Index | Old Index