From: Paolo Bonzini <pbonzini@redhat.com>
To: Richard Zak <richard.j.zak@gmail.com>,
QEMU Developers <qemu-devel@nongnu.org>
Subject: Re: pipe2 & configure script
Date: Wed, 7 Jul 2021 16:32:34 +0200 [thread overview]
Message-ID: <1317d8b6-4233-d239-9b51-3a525e23a8a8@redhat.com> (raw)
In-Reply-To: <CAOakUfMKduLQe=juj-sZzVSkD-bSi48-k7SNiKkDKE-fTaiQ+A@mail.gmail.com>
On 07/07/21 05:24, Richard Zak wrote:
> What conditions are required for "#define CONFIG_PIPE2" to be set in
> build/config-host.h? It prevents building for Haiku as pipe2() doesn't
> exist. I didn't see anything in the configure script regarding pipe2. I
> also updated my code to the latest in the repository and this issue just
> popped up.
Does this help?
diff --git a/meson.build b/meson.build
index 660e294b7e..32d5bd3685 100644
--- a/meson.build
+++ b/meson.build
@@ -1339,7 +1339,7 @@ config_host_data.set('HAVE_STRUCT_STAT_ST_ATIM',
config_host_data.set('CONFIG_EVENTFD', cc.compiles('''
#include <sys/eventfd.h>
int main(void) { return eventfd(0, EFD_NONBLOCK | EFD_CLOEXEC); }'''))
-config_host_data.set('CONFIG_FDATASYNC', cc.compiles(gnu_source_prefix + '''
+config_host_data.set('CONFIG_FDATASYNC', cc.links(gnu_source_prefix + '''
#include <unistd.h>
int main(void) {
#if defined(_POSIX_SYNCHRONIZED_IO) && _POSIX_SYNCHRONIZED_IO > 0
@@ -1356,14 +1356,14 @@ config_host_data.set('CONFIG_MADVISE', cc.compiles(gnu_source_prefix + '''
config_host_data.set('CONFIG_MEMFD', cc.compiles(gnu_source_prefix + '''
#include <sys/mman.h>
int main(void) { return memfd_create("foo", MFD_ALLOW_SEALING); }'''))
-config_host_data.set('CONFIG_OPEN_BY_HANDLE', cc.compiles(gnu_source_prefix + '''
+config_host_data.set('CONFIG_OPEN_BY_HANDLE', cc.links(gnu_source_prefix + '''
#include <fcntl.h>
#if !defined(AT_EMPTY_PATH)
# error missing definition
#else
int main(void) { struct file_handle fh; return open_by_handle_at(0, &fh, 0); }
#endif'''))
-config_host_data.set('CONFIG_PIPE2', cc.compiles(gnu_source_prefix + '''
+config_host_data.set('CONFIG_PIPE2', cc.links(gnu_source_prefix + '''
#include <unistd.h>
#include <fcntl.h>
?
Paolo
next prev parent reply other threads:[~2021-07-07 14:33 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-07 3:24 pipe2 & configure script Richard Zak
2021-07-07 4:42 ` Thomas Huth
2021-07-07 14:36 ` Paolo Bonzini
2021-07-07 14:32 ` Paolo Bonzini [this message]
2021-07-08 2:37 ` Richard Zak
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=1317d8b6-4233-d239-9b51-3a525e23a8a8@redhat.com \
--to=pbonzini@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=richard.j.zak@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).