From patchwork Thu Jul 23 11:18:34 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Baruch Siach X-Patchwork-Id: 499343 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ozlabs.org (Postfix) with ESMTP id 91009140B0D for ; Thu, 23 Jul 2015 21:19:10 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id CDC84333CF; Thu, 23 Jul 2015 11:19:09 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id FWO0QltO+nts; Thu, 23 Jul 2015 11:19:02 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id 175FE333BF; Thu, 23 Jul 2015 11:18:59 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 1BB061C1017 for ; Thu, 23 Jul 2015 11:18:55 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 175AC919A1 for ; Thu, 23 Jul 2015 11:18:55 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Mcg6RohiZOr3 for ; Thu, 23 Jul 2015 11:18:52 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mx.tkos.co.il (guitar.tcltek.co.il [192.115.133.116]) by whitealder.osuosl.org (Postfix) with ESMTPS id 97930919A3 for ; Thu, 23 Jul 2015 11:18:52 +0000 (UTC) Received: from tarshish.tkos.co.il (unknown [10.0.8.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) by mx.tkos.co.il (Postfix) with ESMTPSA id F3111440532; Thu, 23 Jul 2015 14:18:48 +0300 (IDT) From: Baruch Siach To: buildroot@busybox.net Date: Thu, 23 Jul 2015 14:18:34 +0300 Message-Id: X-Mailer: git-send-email 2.1.4 Subject: [Buildroot] [PATCH 1/2] openipmi: fix missing -lrt for clock_gettime X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Add a patch to detect when -lrt is needed. This fixes build with glibc < 2.17. Fixes: http://autobuild.buildroot.net/results/2b0/2b0eb7149c7bdd8ebd72c1070aeefb210379a889/ http://autobuild.buildroot.net/results/49f/49fbd7e2dc72279c5b54d0f59a055e3e5e73f648/ Signed-off-by: Baruch Siach --- ...c-detect-lrt-requirement-for-clock_gettim.patch | 57 ++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 package/openipmi/0002-configure.ac-detect-lrt-requirement-for-clock_gettim.patch diff --git a/package/openipmi/0002-configure.ac-detect-lrt-requirement-for-clock_gettim.patch b/package/openipmi/0002-configure.ac-detect-lrt-requirement-for-clock_gettim.patch new file mode 100644 index 000000000000..d58ffd7caf26 --- /dev/null +++ b/package/openipmi/0002-configure.ac-detect-lrt-requirement-for-clock_gettim.patch @@ -0,0 +1,57 @@ +From d3be03464be7fa3844dfe0837a7e2c920c107836 Mon Sep 17 00:00:00 2001 +From: Baruch Siach +Date: Thu, 23 Jul 2015 13:35:35 +0300 +Subject: [PATCH] configure.ac: detect -lrt requirement for clock_gettime + +glibc versions before 2.17 require link with -lrt. + +Upstream status: sent, stuck in moderator's queue + +Signed-off-by: Baruch Siach +--- + configure.ac | 8 ++++++++ + unix/Makefile.am | 4 ++-- + 2 files changed, 10 insertions(+), 2 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 18401f161d45..6b350a41a916 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -854,6 +854,14 @@ OPENIPMI_SWIG_SO="${PYTHON_POSIX_SO}:\$(top_builddir)/lib/.libs/libOpenIPMI.so:\ + AC_SUBST(OPENIPMI_SWIG_LIBS) + AC_SUBST(OPENIPMI_SWIG_SO) + ++LIB_CLOCK_GETTIME= ++clk_saved_libs=$LIBS ++AC_SEARCH_LIBS([clock_gettime], [rt], ++ [test "$ac_cv_search_clock_gettime" = "none required" || ++ LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime]) ++AC_SUBST([LIB_CLOCK_GETTIME]) ++LIBS=$clk_saved_libs ++ + # Everything from here to AC_OUTPUT is for libedit + + # AC_PROG_LIBTOOL runs AC_CANONICAL_HOST +diff --git a/unix/Makefile.am b/unix/Makefile.am +index a108bc679c9a..fb60242d5d3b 100644 +--- a/unix/Makefile.am ++++ b/unix/Makefile.am +@@ -9,13 +9,13 @@ lib_LTLIBRARIES = libOpenIPMIposix.la libOpenIPMIpthread.la + + libOpenIPMIpthread_la_SOURCES = posix_thread_os_hnd.c selector.c + libOpenIPMIpthread_la_LIBADD = -lpthread $(GDBM_LIB) \ +- $(top_builddir)/utils/libOpenIPMIutils.la ++ $(top_builddir)/utils/libOpenIPMIutils.la $(LIB_CLOCK_GETTIME) + libOpenIPMIpthread_la_LDFLAGS = -rdynamic -version-info $(LD_VERSION) \ + -Wl,-Map -Wl,libOpenIPMIpthread.map + + libOpenIPMIposix_la_SOURCES = posix_os_hnd.c selector.c + libOpenIPMIposix_la_LIBADD = $(top_builddir)/utils/libOpenIPMIutils.la \ +- $(GDBM_LIB) ++ $(GDBM_LIB) $(LIB_CLOCK_GETTIME) + libOpenIPMIposix_la_LDFLAGS = -rdynamic -version-info $(LD_VERSION) \ + -Wl,-Map -Wl,libOpenIPMIposix.map + +-- +2.1.4 +