[prev in list] [next in list] [prev in thread] [next in thread] 

List:       busybox
Subject:    Re: [PATCH] ps: fix build failure if FEATURE_PS_TIME is disabled
From:       walter harms <wharms () bfs ! de>
Date:       2017-08-25 7:59:12
Message-ID: 599FD8D0.3070309 () bfs ! de
[Download RAW message or body]



Am 22.08.2017 12:21, schrieb Ron Yorston:
> The global seconds_since_boot is only defined if FEATURE_PS_TIME
> is enabled.
> 
> Signed-off-by: Ron Yorston <rmy@pobox.com>
> ---
>  procps/ps.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/procps/ps.c b/procps/ps.c
> index 7edf6dbd1..8aaa7e178 100644
> --- a/procps/ps.c
> +++ b/procps/ps.c
> @@ -567,9 +567,11 @@ int ps_main(int argc UNUSED_PARAM, char **argv)
>  	};
>  
>  	INIT_G();
> +#if ENABLE_FEATURE_PS_TIME
>  	G.seconds_since_boot = get_uptime();
> -#if ENABLE_FEATURE_PS_TIME && (ENABLE_FEATURE_PS_UNUSUAL_SYSTEMS || !defined(__linux__))
> +# if ENABLE_FEATURE_PS_UNUSUAL_SYSTEMS || !defined(__linux__)
>  	G.kernel_HZ = bb_clk_tck(); /* this is sysconf(_SC_CLK_TCK) */
> +# endif
>  #endif


I never noticed that ENABLE_FEATURE_PS_UNUSUAL_SYSTEMS exists.
Perhaps we can find a more descriptive name ? like:
 FEATURE_USE_SYSCONF_CLK_TCK

re,
 wh



>  
>  	// POSIX:
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic