public inbox for linux-nfs@vger.kernel.org
 help / color / mirror / Atom feed
From: liezhi.yang@windriver.com
To: linux-nfs@vger.kernel.org
Subject: [nfs-utils PATCH] reexport.h: Include unistd.h to compile with musl
Date: Thu, 14 Dec 2023 18:12:06 +0800	[thread overview]
Message-ID: <20231214101206.70608-1-liezhi.yang@windriver.com> (raw)

From: Robert Yang <liezhi.yang@windriver.com>

Fixed error when compile with musl
reexport.c: In function 'reexpdb_init':
reexport.c:62:17: error: implicit declaration of function 'sleep' [-Werror=implicit-function-declaration]
   62 |                 sleep(1);

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
---
 support/reexport/reexport.h | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/support/reexport/reexport.h b/support/reexport/reexport.h
index 85fd59c1..02f86844 100644
--- a/support/reexport/reexport.h
+++ b/support/reexport/reexport.h
@@ -1,6 +1,8 @@
 #ifndef REEXPORT_H
 #define REEXPORT_H
 
+#include <unistd.h>
+
 #include "nfslib.h"
 
 enum {
-- 
2.35.5


             reply	other threads:[~2023-12-14  9:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-14 10:12 liezhi.yang [this message]
2024-01-04  0:42 ` [nfs-utils PATCH] reexport.h: Include unistd.h to compile with musl Steve Dickson
2024-11-11 17:24 ` Steve Dickson

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=20231214101206.70608-1-liezhi.yang@windriver.com \
    --to=liezhi.yang@windriver.com \
    --cc=linux-nfs@vger.kernel.org \
    /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