linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH e2fsprogs] fuse2fs: might need librt
@ 2016-06-09 10:57 Gustavo Zacarias
  2016-06-09 20:57 ` Theodore Ts'o
  0 siblings, 1 reply; 2+ messages in thread
From: Gustavo Zacarias @ 2016-06-09 10:57 UTC (permalink / raw)
  To: linux-ext4; +Cc: Gustavo Zacarias

It uses clock_gettime() which in older glibc versions is in librt.

Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
---
 configure.ac     | 5 +++++
 misc/Makefile.in | 3 ++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/configure.ac b/configure.ac
index 67d7231..a387dfd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1162,6 +1162,11 @@ if test "$ac_cv_func_dlopen" = yes ; then
 fi
 AC_SUBST(MAGIC_LIB)
 dnl
+dnl Check to see if librt is required for clock_gettime() (glibc < 2.17)
+dnl
+AC_CHECK_LIB(rt, clock_gettime, [CLOCK_GETTIME_LIB=-lrt])
+AC_SUBST(CLOCK_GETTIME_LIB)
+dnl
 dnl Check to see if the FUSE library is -lfuse or -losxfuse
 dnl
 FUSE_CMT=
diff --git a/misc/Makefile.in b/misc/Makefile.in
index 43e3c7e..070a6e3 100644
--- a/misc/Makefile.in
+++ b/misc/Makefile.in
@@ -387,7 +387,8 @@ fuse2fs: $(FUSE2FS_OBJS) $(DEPLIBS) $(DEPLIBBLKID) $(DEPLIBUUID) \
 		$(LIBEXT2FS)
 	$(E) "	LD $@"
 	$(Q) $(CC) $(ALL_LDFLAGS) -o fuse2fs $(FUSE2FS_OBJS) $(LIBS) \
-		$(LIBFUSE) $(LIBBLKID) $(LIBUUID) $(LIBEXT2FS) $(LIBINTL)
+		$(LIBFUSE) $(LIBBLKID) $(LIBUUID) $(LIBEXT2FS) $(LIBINTL) \
+		$(CLOCK_GETTIME_LIB)
 
 journal.o: $(srcdir)/../debugfs/journal.c
 	$(E) "	CC $@"
-- 
2.7.3


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH e2fsprogs] fuse2fs: might need librt
  2016-06-09 10:57 [PATCH e2fsprogs] fuse2fs: might need librt Gustavo Zacarias
@ 2016-06-09 20:57 ` Theodore Ts'o
  0 siblings, 0 replies; 2+ messages in thread
From: Theodore Ts'o @ 2016-06-09 20:57 UTC (permalink / raw)
  To: Gustavo Zacarias; +Cc: linux-ext4

On Thu, Jun 09, 2016 at 07:57:31AM -0300, Gustavo Zacarias wrote:
> It uses clock_gettime() which in older glibc versions is in librt.
> 
> Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>

Thanks, applied.

						- Ted

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-06-09 20:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-06-09 10:57 [PATCH e2fsprogs] fuse2fs: might need librt Gustavo Zacarias
2016-06-09 20:57 ` Theodore Ts'o

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).