[LTP] [PATCH 1/2] getrlimit/getrlimit03: add configure-time check for struct ulimit64

Petr Vorel pvorel@suse.cz
Mon Dec 3 22:25:05 CET 2018


Hi Greg,

Reviewed-by: Petr Vorel <pvorel@suse.cz>

> +++ b/m4/ltp-rlimit64.m4
> @@ -0,0 +1,10 @@
> +dnl SPDX-License-Identifier: GPL-2.0-or-later
> +dnl Copyright (c) 2018 Google, Inc.
> +
> +AC_DEFUN([LTP_CHECK_RLIMIT64],[
> +AC_CHECK_TYPES([struct rlimit64],,,[
> +#include <sys/time.h>
> +#include <sys/resource.h>
> +])
> +])
Glibc and uclibc-ng define struct rlimit64 only #ifdef __USE_LARGEFILE64.
Would it make sense to change autoconf test to AC_COMPILE_IFELSE and pass -D_LARGEFILE64_SOURCE to it?
+ Use it in Makefile, of course.


Kind regards,
Petr


More information about the ltp mailing list