util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Samuel Thibault <samuel.thibault@ens-lyon.org>
To: Karel Zak <kzak@redhat.com>
Cc: util-linux@vger.kernel.org
Subject: Fix building util-linux on non-linux
Date: Tue, 17 Nov 2020 21:20:17 +0100	[thread overview]
Message-ID: <20201117202017.afatx2kpuxp5kf7u@function> (raw)

[-- Attachment #1: Type: text/plain, Size: 63 bytes --]

Hello,

The attached patch fixes building on non-linux

Samuel

[-- Attachment #2: patch --]
[-- Type: text/plain, Size: 1471 bytes --]

diff --git a/login-utils/Makemodule.am b/login-utils/Makemodule.am
index 4f52cea3c..8bc3ee37e 100644
--- a/login-utils/Makemodule.am
+++ b/login-utils/Makemodule.am
@@ -31,8 +31,10 @@ dist_man_MANS += login-utils/sulogin.8
 sulogin_SOURCES = \
 	login-utils/sulogin.c \
 	login-utils/sulogin-consoles.c \
-	login-utils/sulogin-consoles.h \
-	lib/plymouth-ctrl.c
+	login-utils/sulogin-consoles.h
+if USE_PLYMOUTH_SUPPORT
+sulogin_SOURCES += lib/plymouth-ctrl.c
+endif
 sulogin_LDADD = $(LDADD) libcommon.la
 
 if HAVE_LIBCRYPT
diff --git a/sys-utils/hwclock.c b/sys-utils/hwclock.c
index 1f7ef3317..db448687d 100644
--- a/sys-utils/hwclock.c
+++ b/sys-utils/hwclock.c
@@ -678,7 +678,7 @@ display_time(struct timeval hwctime)
 #ifndef SYS_settimeofday
 # ifdef __NR_settimeofday
 #  define SYS_settimeofday	__NR_settimeofday
-# else
+# elif defined(__NR_settimeofday_time32)
 #  define SYS_settimeofday	__NR_settimeofday_time32
 # endif
 #endif
diff --git a/term-utils/Makemodule.am b/term-utils/Makemodule.am
index 92df7dbc8..c424dbdf8 100644
--- a/term-utils/Makemodule.am
+++ b/term-utils/Makemodule.am
@@ -42,8 +42,10 @@ endif # BUILD_SCRIPTLIVE
 if BUILD_AGETTY
 sbin_PROGRAMS += agetty
 dist_man_MANS += term-utils/agetty.8
-agetty_SOURCES = term-utils/agetty.c \
-		 lib/plymouth-ctrl.c
+agetty_SOURCES = term-utils/agetty.c
+if USE_PLYMOUTH_SUPPORT
+agetty_SOURCES += lib/plymouth-ctrl.c
+endif
 agetty_LDADD = $(LDADD) libcommon.la
 if BSD
 agetty_LDADD += -lutil

             reply	other threads:[~2020-11-17 20:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-17 20:20 Samuel Thibault [this message]
2020-11-18  9:34 ` Fix building util-linux on non-linux Karel 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=20201117202017.afatx2kpuxp5kf7u@function \
    --to=samuel.thibault@ens-lyon.org \
    --cc=kzak@redhat.com \
    --cc=util-linux@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;
as well as URLs for NNTP newsgroup(s).