Re: Fix non-Linux build

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

 



On Sun, Sep 17, 2023 at 06:36:31PM +0200, Samuel Thibault wrote:
> Here are some fixes for non-linux build.

Thanks!

> diff --git a/configure.ac b/configure.ac
> index 5f609dec7..061e22e15 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -1906,7 +1906,8 @@ AS_IF([test "x$build_enosys" = xyes], [
>  ])
>  AM_CONDITIONAL([BUILD_ENOSYS], [test "x$build_enosys" = xyes])
>  
> -UL_BUILD_INIT([lsclocks], [yes])
> +UL_BUILD_INIT([lsclocks], [check])
> +UL_REQUIRES_LINUX([lsclocks])
>  AM_CONDITIONAL([BUILD_LSCLOCKS], [test "x$build_lsclocks" = xyes])

Applied.

> --- a/libmount/src/hooks.c
> +++ b/libmount/src/hooks.c
> @@ -315,9 +315,11 @@ static int call_hook(struct libmnt_context *cxt, struct hookset_hook *hook)
>  {
>  	int rc = 0;
>  
> +#if LINUX
>  	if (mnt_context_is_fake(cxt))
>  		DBG(CXT, ul_debugobj(cxt, " FAKE call"));
>  	else
> +#endif
>  		rc = hook->func(cxt, hook->hookset, hook->data);

It seems better to not use libmount/src/hooks.c on non-Linux systems.
Fixed (but not tested:-).

 Karel


-- 
 Karel Zak  <kzak@xxxxxxxxxx>
 http://karelzak.blogspot.com




[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux