From: "Darrick J. Wong" <djwong@kernel.org>
To: Krzesimir Nowak <qdlacz@gmail.com>, Carlos Maiolino <cem@kernel.org>
Cc: linux-xfs@vger.kernel.org, Krzesimir Nowak <knowak@microsoft.com>
Subject: Re: [PATCH 1/1] libfrog: Fix cross-compilation issue with randbytes
Date: Tue, 26 Sep 2023 07:41:00 -0700 [thread overview]
Message-ID: <20230926144100.GD11439@frogsfrogsfrogs> (raw)
In-Reply-To: <20230926071432.51866-2-knowak@microsoft.com>
On Tue, Sep 26, 2023 at 09:14:32AM +0200, Krzesimir Nowak wrote:
> randbytes.c was mostly split off from crc32.c and, like crc32.c, is
> used for selftests, which are run on the build host. As such it should
> not include platform_defs.h which in turn includes urcu.h from
> userspace-rcu library, because the build host might not have the
> library installed.
Why not get rid of the build host crc32c selftest? It's not that useful
for cross-compiling and nowadays mkfs.xfs and xfs_repair have their own
builtin selftests. Anyone messing with xfsprogs should be running
fstests (in addition to the maintainers) so I don't really see the point
of running crc32cselftest on the *build* host.
(Carlos: any thoughts on this?)
--D
> Signed-off-by: Krzesimir Nowak <knowak@microsoft.com>
> ---
> libfrog/randbytes.c | 1 -
> libfrog/randbytes.h | 2 ++
> 2 files changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/libfrog/randbytes.c b/libfrog/randbytes.c
> index f22da0d3..2023b601 100644
> --- a/libfrog/randbytes.c
> +++ b/libfrog/randbytes.c
> @@ -6,7 +6,6 @@
> *
> * This is the buffer of random bytes used for self tests.
> */
> -#include "platform_defs.h"
> #include "libfrog/randbytes.h"
>
> /* 4096 random bytes */
> diff --git a/libfrog/randbytes.h b/libfrog/randbytes.h
> index 00fd7c4c..fddea9c7 100644
> --- a/libfrog/randbytes.h
> +++ b/libfrog/randbytes.h
> @@ -6,6 +6,8 @@
> #ifndef __LIBFROG_RANDBYTES_H__
> #define __LIBFROG_RANDBYTES_H__
>
> +#include <stdint.h>
> +
> extern uint8_t randbytes_test_buf[];
>
> #endif /* __LIBFROG_RANDBYTES_H__ */
> --
> 2.25.1
>
next prev parent reply other threads:[~2023-09-26 14:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-26 7:14 [PATCH 0/1] Fix cross-compilation issue with randbytes Krzesimir Nowak
2023-09-26 7:14 ` [PATCH 1/1] libfrog: " Krzesimir Nowak
2023-09-26 14:41 ` Darrick J. Wong [this message]
2023-09-26 21:28 ` Dave Chinner
2023-10-03 11:15 ` Carlos Maiolino
2023-10-11 11:34 ` Krzesimir Nowak
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230926144100.GD11439@frogsfrogsfrogs \
--to=djwong@kernel.org \
--cc=cem@kernel.org \
--cc=knowak@microsoft.com \
--cc=linux-xfs@vger.kernel.org \
--cc=qdlacz@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).