2014-02-11 15:25:21 +01:00
|
|
|
From 71cf16e435bf5db64abcf81a9dc6dc36ce37d58d Mon Sep 17 00:00:00 2001
|
|
|
|
From: =?UTF-8?q?P=C3=A1draig=20Brady?= <P@draigBrady.com>
|
|
|
|
Date: Tue, 14 Jan 2014 16:59:07 +0000
|
|
|
|
Subject: [PATCH] spawn: fix link error on uclibc
|
|
|
|
|
|
|
|
* m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): use AC_SEARCH_LIBS,
|
|
|
|
to incorporate -lrt if needed (on uclibc for example).
|
|
|
|
* modules/posix_spawn: Reference the substituted LIB.
|
|
|
|
|
|
|
|
Patch status: suggested by gnulib maintainer
|
|
|
|
(http://article.gmane.org/gmane.comp.lib.gnulib.bugs/33610), not in upstream
|
|
|
|
gnulib yet
|
|
|
|
|
2014-02-12 09:16:10 +01:00
|
|
|
This issue should be fixed in coreutils version 8.23.
|
2014-02-11 15:25:21 +01:00
|
|
|
|
2014-02-12 09:16:10 +01:00
|
|
|
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
|
2014-02-11 15:25:21 +01:00
|
|
|
---
|
|
|
|
|
|
|
|
diff --git a/m4/spawn_h.m4 b/m4/spawn_h.m4
|
|
|
|
index 87fe122..3eb835c 100644
|
|
|
|
--- a/m4/spawn_h.m4
|
|
|
|
+++ b/m4/spawn_h.m4
|
|
|
|
@@ -64,7 +64,15 @@ AC_DEFUN([gl_HAVE_POSIX_SPAWN],
|
|
|
|
dnl once only, before all statements that occur in other macros.
|
|
|
|
AC_REQUIRE([gl_SPAWN_H_DEFAULTS])
|
|
|
|
|
|
|
|
- AC_CHECK_FUNCS_ONCE([posix_spawn])
|
|
|
|
+ LIB_POSIX_SPAWN=
|
|
|
|
+ AC_SUBST([LIB_POSIX_SPAWN])
|
|
|
|
+ gl_saved_libs=$LIBS
|
|
|
|
+ AC_SEARCH_LIBS([posix_spawn], [rt],
|
|
|
|
+ [test "$ac_cv_search_posix_spawn" = "none required" ||
|
|
|
|
+ LIB_POSIX_SPAWN=$ac_cv_search_posix_spawn])
|
|
|
|
+ AC_CHECK_FUNCS([posix_spawn])
|
|
|
|
+ LIBS=$gl_saved_libs
|
|
|
|
+
|
|
|
|
if test $ac_cv_func_posix_spawn != yes; then
|
|
|
|
HAVE_POSIX_SPAWN=0
|
|
|
|
fi
|
|
|
|
|
|
|
|
--
|
|
|
|
1.7.7.6
|
|
|
|
|