Skip to contentSkip to conversation

nfs-utils: fix static build

GIT PULL New Yann E. MORIN 2 participants 7 messages Nov 27, 2014

lore
Share & tools
lore
#0 lore raw

Hello All!

This small series fixes nfs-utils for static builds. Not much to say besides what the various changelogs already say.

If needed, I can drop renaming the patches if it is not wanted for the master branch, or they can be folded each into its following changeset.

Changes v1 -> v2:
- fix the nfs-utils patch to get rid of a latent bug, use the same patch as sent upstream

Regards,
Yann E. MORIN.

The following changes since commit 3a66731b9c50e62a6768edc9f21da867a74869b9:

infra: do not append an empty LD_LIBRARY_PATH (2014-11-27 22:07:15 +0100)

are available in the git repository at:

git://git.busybox.net/~ymorin/git/buildroot yem/for-release

for you to fetch changes up to ffb61e77dc527abadcf5c155b2163c3fcc9b9329:

package/nfs-utils: use pkg-config to find libtirpc (2014-11-27 22:25:42 +0100)

----------------------------------------------------------------
Yann E. MORIN (4):
package/libtirpc: rename patches package/libtirpc: add -pthread to the private libraries package/nfs-utils: rename patches package/nfs-utils: use pkg-config to find libtirpc

 ...ble-parts-of-TIRPC-requiring-NIS-support.patch} |   0
 ...ut-RPC-support-does-not-install-rpcent.h.patch} |   0
 ...patch => 0003-Make-IPv6-support-optional.patch} |   0
 ...dd-rpcgen-program-from-nfs-utils-sources.patch} |   0
 ...y-generate-XDR-header-files-from-.x-sour.patch} |   0
 ...-files-needed-to-build-rpcbind-on-top-of.patch} |   0
 package/libtirpc/0007-needs-pthread.patch          |  25 +++++
 ...-AM_CONDITIONAL-in-conditional-execution.patch} |   0
 ...oo.patch => 0002-Patch-taken-from-Gentoo.patch} |   0
 ...-Switch-legacy-index-in-favour-of-strchr.patch} |   0
 ...libc.patch => 0004-fix-build-with-uClibc.patch} |   0
 ...of-getrpcbynumber-when-getrpcbynumber_r-.patch} |   0
 ...igure-script-find-getrpcbynumber-in-libt.patch} |   0
 ... 0007-sockaddr-h-needs-stddef-h-for-NULL.patch} |   0
 package/nfs-utils/0008-tirpc-with-pkgconfig.patch  | 102 +++++++++++++++++++++
 package/nfs-utils/nfs-utils.mk                     |   2 +-
 16 files changed, 128 insertions(+), 1 deletion(-)
 rename package/libtirpc/{libtirpc-0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch => 0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch} (100%)
 rename package/libtirpc/{libtirpc-0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch => 0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch} (100%)
 rename package/libtirpc/{libtirpc-0004-Make-IPv6-support-optional.patch => 0003-Make-IPv6-support-optional.patch} (100%)
 rename package/libtirpc/{libtirpc-0008-Add-rpcgen-program-from-nfs-utils-sources.patch => 0004-Add-rpcgen-program-from-nfs-utils-sources.patch} (100%)
 rename package/libtirpc/{libtirpc-0009-Automatically-generate-XDR-header-files-from-.x-sour.patch => 0005-Automatically-generate-XDR-header-files-from-.x-sour.patch} (100%)
 rename package/libtirpc/{libtirpc-0010-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch => 0006-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch} (100%)
 create mode 100644 package/libtirpc/0007-needs-pthread.patch
 rename package/nfs-utils/{nfs-utils-0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch => 0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0002-Patch-taken-from-Gentoo.patch => 0002-Patch-taken-from-Gentoo.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0003-Switch-legacy-index-in-favour-of-strchr.patch => 0003-Switch-legacy-index-in-favour-of-strchr.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0004-fix-build-with-uClibc.patch => 0004-fix-build-with-uClibc.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch => 0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch => 0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0007-sockaddr-h-needs-stddef-h-for-NULL.patch => 0007-sockaddr-h-needs-stddef-h-for-NULL.patch} (100%)
 create mode 100644 package/nfs-utils/0008-tirpc-with-pkgconfig.patch
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
#1 lore raw

PATCH v2 1/4 package/libtirpc: rename patches

---
 ...port.patch => 0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch} | 0
 ...ch => 0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch} | 0
 ...-IPv6-support-optional.patch => 0003-Make-IPv6-support-optional.patch} | 0
 ...sources.patch => 0004-Add-rpcgen-program-from-nfs-utils-sources.patch} | 0
 ...ch => 0005-Automatically-generate-XDR-header-files-from-.x-sour.patch} | 0
 ...ch => 0006-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch} | 0
 6 files changed, 0 insertions(+), 0 deletions(-)
 rename package/libtirpc/{libtirpc-0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch => 0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch} (100%)
 rename package/libtirpc/{libtirpc-0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch => 0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch} (100%)
 rename package/libtirpc/{libtirpc-0004-Make-IPv6-support-optional.patch => 0003-Make-IPv6-support-optional.patch} (100%)
 rename package/libtirpc/{libtirpc-0008-Add-rpcgen-program-from-nfs-utils-sources.patch => 0004-Add-rpcgen-program-from-nfs-utils-sources.patch} (100%)
 rename package/libtirpc/{libtirpc-0009-Automatically-generate-XDR-header-files-from-.x-sour.patch => 0005-Automatically-generate-XDR-header-files-from-.x-sour.patch} (100%)
 rename package/libtirpc/{libtirpc-0010-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch => 0006-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch} (100%)
package/libtirpc/0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch renamed from package/libtirpc/libtirpc-0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch +0 -0
similarity index 100%
rename from package/libtirpc/libtirpc-0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch
rename to package/libtirpc/0001-Disable-parts-of-TIRPC-requiring-NIS-support.patch
package/libtirpc/0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch renamed from package/libtirpc/libtirpc-0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch +0 -0
similarity index 100%
rename from package/libtirpc/libtirpc-0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch
rename to package/libtirpc/0002-uClibc-without-RPC-support-does-not-install-rpcent.h.patch
package/libtirpc/0003-Make-IPv6-support-optional.patch renamed from package/libtirpc/libtirpc-0004-Make-IPv6-support-optional.patch +0 -0
similarity index 100%
rename from package/libtirpc/libtirpc-0004-Make-IPv6-support-optional.patch
rename to package/libtirpc/0003-Make-IPv6-support-optional.patch
package/libtirpc/0004-Add-rpcgen-program-from-nfs-utils-sources.patch renamed from package/libtirpc/libtirpc-0008-Add-rpcgen-program-from-nfs-utils-sources.patch +0 -0
similarity index 100%
rename from package/libtirpc/libtirpc-0008-Add-rpcgen-program-from-nfs-utils-sources.patch
rename to package/libtirpc/0004-Add-rpcgen-program-from-nfs-utils-sources.patch
package/libtirpc/0005-Automatically-generate-XDR-header-files-from-.x-sour.patch renamed from package/libtirpc/libtirpc-0009-Automatically-generate-XDR-header-files-from-.x-sour.patch +0 -0
similarity index 100%
rename from package/libtirpc/libtirpc-0009-Automatically-generate-XDR-header-files-from-.x-sour.patch
rename to package/libtirpc/0005-Automatically-generate-XDR-header-files-from-.x-sour.patch
package/libtirpc/0006-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch renamed from package/libtirpc/libtirpc-0010-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch +0 -0
similarity index 100%
rename from package/libtirpc/libtirpc-0010-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch
rename to package/libtirpc/0006-Add-more-XDR-files-needed-to-build-rpcbind-on-top-of.patch
Signature · 1 line
1.9.1
#2 lore raw

PATCH v2 2/4 package/libtirpc: add -pthread to the private libraries

In reply to Yann E. MORIN

Fixes:

    http://autobuild.buildroot.net/results/17d/17d1d94e6f1617851e374f4fe9804f1e5ea9e99f/
    http://autobuild.buildroot.net/results/c08/c08b7be40c8f208147a4f95ad897e4a1df7e108d/
    and maybe a bunch of others...
---
 package/libtirpc/0007-needs-pthread.patch | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)
 create mode 100644 package/libtirpc/0007-needs-pthread.patch
package/libtirpc/0007-needs-pthread.patch new file +25 -0
new file mode 100644
index 0000000..6cdf98a
@@ -0,0 +1,25 @@
+pkg-config: needs pthread as private library
+
+libtirpc needs pthreads. This is automatically pulled in when linking
+with the shared library, thanks to the DT_NEEDED ELF tags.
+
+But for a static library, there is no such mechanism to identify
+required libraries.
+
+Thus, add -pthread to the private libraries in the pkg-config file.
+
+Signed-off-by: "Yann E. MORIN" <[email protected]>
+
+---
+Patch sent upstream:
+    http://sourceforge.net/p/libtirpc/mailman/message/33072076/
+
+diff -durN libtirpc-0.2.4.orig/libtirpc.pc.in libtirpc-0.2.4/libtirpc.pc.in
+--- libtirpc-0.2.4.orig/libtirpc.pc.in	2013-12-09 21:59:51.000000000 +0100
++++ libtirpc-0.2.4/libtirpc.pc.in	2014-11-23 14:02:58.677760108 +0100
+@@ -8,4 +8,5 @@
+ Requires:
+ Version: @PACKAGE_VERSION@
+ Libs: -L at libdir@ -ltirpc
++Libs.private: -pthread
+ Cflags: -I at includedir@/tirpc
Signature · 1 line
1.9.1
#3 lore raw

PATCH v2 3/4 package/nfs-utils: rename patches

In reply to Yann E. MORIN
---
 ...tch => 0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch} | 0
 ...2-Patch-taken-from-Gentoo.patch => 0002-Patch-taken-from-Gentoo.patch} | 0
 ...of-strchr.patch => 0003-Switch-legacy-index-in-favour-of-strchr.patch} | 0
 ...-0004-fix-build-with-uClibc.patch => 0004-fix-build-with-uClibc.patch} | 0
 ...ch => 0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch} | 0
 ...ch => 0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch} | 0
 ...def-h-for-NULL.patch => 0007-sockaddr-h-needs-stddef-h-for-NULL.patch} | 0
 7 files changed, 0 insertions(+), 0 deletions(-)
 rename package/nfs-utils/{nfs-utils-0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch => 0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0002-Patch-taken-from-Gentoo.patch => 0002-Patch-taken-from-Gentoo.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0003-Switch-legacy-index-in-favour-of-strchr.patch => 0003-Switch-legacy-index-in-favour-of-strchr.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0004-fix-build-with-uClibc.patch => 0004-fix-build-with-uClibc.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch => 0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch => 0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch} (100%)
 rename package/nfs-utils/{nfs-utils-0007-sockaddr-h-needs-stddef-h-for-NULL.patch => 0007-sockaddr-h-needs-stddef-h-for-NULL.patch} (100%)
package/nfs-utils/0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch renamed from package/nfs-utils/nfs-utils-0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch +0 -0
similarity index 100%
rename from package/nfs-utils/nfs-utils-0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch
rename to package/nfs-utils/0001-build-avoid-AM_CONDITIONAL-in-conditional-execution.patch
package/nfs-utils/0002-Patch-taken-from-Gentoo.patch renamed from package/nfs-utils/nfs-utils-0002-Patch-taken-from-Gentoo.patch +0 -0
similarity index 100%
rename from package/nfs-utils/nfs-utils-0002-Patch-taken-from-Gentoo.patch
rename to package/nfs-utils/0002-Patch-taken-from-Gentoo.patch
package/nfs-utils/0003-Switch-legacy-index-in-favour-of-strchr.patch renamed from package/nfs-utils/nfs-utils-0003-Switch-legacy-index-in-favour-of-strchr.patch +0 -0
similarity index 100%
rename from package/nfs-utils/nfs-utils-0003-Switch-legacy-index-in-favour-of-strchr.patch
rename to package/nfs-utils/0003-Switch-legacy-index-in-favour-of-strchr.patch
package/nfs-utils/0004-fix-build-with-uClibc.patch renamed from package/nfs-utils/nfs-utils-0004-fix-build-with-uClibc.patch +0 -0
similarity index 100%
rename from package/nfs-utils/nfs-utils-0004-fix-build-with-uClibc.patch
rename to package/nfs-utils/0004-fix-build-with-uClibc.patch
package/nfs-utils/0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch renamed from package/nfs-utils/nfs-utils-0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch +0 -0
similarity index 100%
rename from package/nfs-utils/nfs-utils-0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch
rename to package/nfs-utils/0005-Allow-usage-of-getrpcbynumber-when-getrpcbynumber_r-.patch
package/nfs-utils/0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch renamed from package/nfs-utils/nfs-utils-0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch +0 -0
similarity index 100%
rename from package/nfs-utils/nfs-utils-0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch
rename to package/nfs-utils/0006-Let-the-configure-script-find-getrpcbynumber-in-libt.patch
package/nfs-utils/0007-sockaddr-h-needs-stddef-h-for-NULL.patch renamed from package/nfs-utils/nfs-utils-0007-sockaddr-h-needs-stddef-h-for-NULL.patch +0 -0
similarity index 100%
rename from package/nfs-utils/nfs-utils-0007-sockaddr-h-needs-stddef-h-for-NULL.patch
rename to package/nfs-utils/0007-sockaddr-h-needs-stddef-h-for-NULL.patch
Signature · 1 line
1.9.1
#4 lore raw

PATCH v2 4/4 package/nfs-utils: use pkg-config to find libtirpc

In reply to Yann E. MORIN

Fixes:

    http://autobuild.buildroot.net/results/17d/17d1d94e6f1617851e374f4fe9804f1e5ea9e99f/
    http://autobuild.buildroot.net/results/c08/c08b7be40c8f208147a4f95ad897e4a1df7e108d/
    and probably some others as well...
---
 package/nfs-utils/0008-tirpc-with-pkgconfig.patch | 102 ++++++++++++++++++++++
 package/nfs-utils/nfs-utils.mk                    |   2 +-
 2 files changed, 103 insertions(+), 1 deletion(-)
 create mode 100644 package/nfs-utils/0008-tirpc-with-pkgconfig.patch
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +102 -0
new file mode 100644
index 0000000..62c820b
@@ -0,0 +1,102 @@
+From 1ecd1f2008bfab7bb3cd6ada135c980414a7f1ba Mon Sep 17 00:00:00 2001
+From: "Yann E. MORIN" <[email protected]>
+Date: Sun, 23 Nov 2014 15:53:56 +0100
+Subject: [PATCH] configure: use pkg-config to find libtirpc
+
+Currently, we use a custom function to find libtirpc's headers and
+libraries. This works fine for shared linking.
+
+But for static linking, this forgets to link with -lpthread, which is
+required by libtirpc.
+
+A recent patch was sent to libtirpc to add that missing -lpthread in its
+Libs.private section of its .pc file. Thus, pkg-config will soon be able
+to return the appropriate libraries.
+
+So, use pkg-config to find libtirpc.
+
+And for older libtirpc versions, there is no change in behaviour: we're
+still missing the -lpthread. But once libtirpc has been fixed, we'll
+automatically get that missing library for free! :-)
+
+Remove the --with-libirpc flag as it is no longer needed: pkg-config
+will provide us with the -I and -L flags, now.
+
+Signed-off-by: "Yann E. MORIN" <[email protected]>
+Cc: Steve Dickson <[email protected]>
+
+---
+Patch sent upstream:
+    http://article.gmane.org/gmane.linux.nfs/67708
+---
+ aclocal/libtirpc.m4 | 68 ++++++++++-------------------------------------------
+ 1 file changed, 13 insertions(+), 55 deletions(-)
+
+diff --git a/aclocal/libtirpc.m4 b/aclocal/libtirpc.m4
+index b823364..4a19c1a 100644
+--- a/aclocal/libtirpc.m4
++++ b/aclocal/libtirpc.m4
+@@ -2,50 +2,19 @@ dnl Checks for TI-RPC library and headers
+ dnl
+ AC_DEFUN([AC_LIBTIRPC], [
+ 
+-  AC_ARG_WITH([tirpcinclude],
+-              [AC_HELP_STRING([--with-tirpcinclude=DIR],
+-                              [use TI-RPC headers in DIR])],
+-              [tirpc_header_dir=$withval],
+-              [tirpc_header_dir=/usr/include/tirpc])
+-
+-  dnl if --enable-tirpc was specifed, the following components
+-  dnl must be present, and we set up HAVE_ macros for them.
+-
+-  if test "$enable_tirpc" != "no"; then
+-
+-    dnl look for the library
+-    AC_CHECK_LIB([tirpc], [clnt_tli_create], [:],
+-                 [if test "$enable_tirpc" = "yes"; then
+-			AC_MSG_ERROR([libtirpc not found.])
+-		  else
+-			AC_MSG_WARN([libtirpc not found. TIRPC disabled!])
+-			enable_tirpc="no"
+-		  fi])
+-  fi
+-
+-  if test "$enable_tirpc" != "no"; then
+-    dnl also must have the headers installed where we expect
+-    dnl look for headers; add -I compiler option if found
+-    AC_CHECK_HEADERS([${tirpc_header_dir}/netconfig.h],
+-    		      AC_SUBST([AM_CPPFLAGS], ["-I${tirpc_header_dir}"]),
+-		      [if test "$enable_tirpc" = "yes"; then
+-			 AC_MSG_ERROR([libtirpc headers not found.])
+-		       else
+-			 AC_MSG_WARN([libtirpc headers not found. TIRPC disabled!])
+-			 enable_tirpc="no"
+-		       fi])
+-
+-  fi
+-
+-  dnl now set $LIBTIRPC accordingly
+-  if test "$enable_tirpc" != "no"; then
+-    AC_DEFINE([HAVE_LIBTIRPC], 1,
+-              [Define to 1 if you have and wish to use libtirpc.])
+-    LIBTIRPC="-ltirpc"
+-  else
+-    LIBTIRPC=""
+-  fi
+-
++  PKG_PROG_PKG_CONFIG([0.9.0])
++  AS_IF(
++    [test "$enable_tirpc" != "no"],
++    [PKG_CHECK_MODULES([TIRPC], [libtirpc >= 0.2.4],
++                       [LIBTIRPC="${TIRPC_LIBS}"
++                        AM_CPPFLAGS="${AM_CPPFLAGS} ${TIRPC_CFLAGS}"
++                        AC_DEFINE([HAVE_LIBTIRPC], [1],
++                                  [Define to 1 if you have and wish to use libtirpc.])],
++                       [AS_IF([test "$enable_tirpc" = "yes"],
++                              [AC_MSG_ERROR([libtirpc not found.])],
++                              [LIBTIRPC=""])])])
++
++  AC_SUBST([AM_CPPFLAGS])
+   AC_SUBST(LIBTIRPC)
+ 
+ ])dnl
package/nfs-utils/nfs-utils.mk +1 -1
index 522e790..8b56edf 100644
@@ -28,7 +28,7 @@ NFS_UTILS_TARGETS_$(BR2_PACKAGE_NFS_UTILS_RPC_LOCKD) += usr/sbin/rpc.lockd
 NFS_UTILS_TARGETS_$(BR2_PACKAGE_NFS_UTILS_RPC_RQUOTAD) += usr/sbin/rpc.rquotad
 
 ifeq ($(BR2_PACKAGE_LIBTIRPC),y)
-NFS_UTILS_CONF_OPTS += --enable-tirpc --with-tirpcinclude=$(STAGING_DIR)/usr/include/tirpc/
+NFS_UTILS_CONF_OPTS += --enable-tirpc
 NFS_UTILS_DEPENDENCIES += libtirpc
 else
 NFS_UTILS_CONF_OPTS += --disable-tirpc
Signature · 1 line
1.9.1
#5 lore raw

PATCH v2 4/4 package/nfs-utils: use pkg-config to find libtirpc

Quoted 32 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Yann" == Yann E MORIN <[email protected]> writes:

Fixes:

    http://autobuild.buildroot.net/results/17d/17d1d94e6f1617851e374f4fe9804f1e5ea9e99f/
    http://autobuild.buildroot.net/results/c08/c08b7be40c8f208147a4f95ad897e4a1df7e108d/
    and probably some others as well...
---
 package/nfs-utils/0008-tirpc-with-pkgconfig.patch | 102 ++++++++++++++++++++++
 package/nfs-utils/nfs-utils.mk                    |   2 +-
 2 files changed, 103 insertions(+), 1 deletion(-)
 create mode 100644 package/nfs-utils/0008-tirpc-with-pkgconfig.patch
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +12 -0
new file mode 100644
index 0000000..62c820b
@@ -0,0 +1,102 @@
+From 1ecd1f2008bfab7bb3cd6ada135c980414a7f1ba Mon Sep 17 00:00:00 2001
+From: "Yann E. MORIN" <[email protected]>
+Date: Sun, 23 Nov 2014 15:53:56 +0100
+Subject: [PATCH] configure: use pkg-config to find libtirpc
+
+Currently, we use a custom function to find libtirpc's headers and
+libraries. This works fine for shared linking.
+
+But for static linking, this forgets to link with -lpthread, which is
+required by libtirpc.
+
+A recent patch was sent to libtirpc to add that missing -lpthread in its

package/nfs-utils/0008-tirpc-with-pkgconfig.patch line 22

Quoted 10 lines
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +10 -0
+Libs.private section of its .pc file. Thus, pkg-config will soon be able
+to return the appropriate libraries.
+
+So, use pkg-config to find libtirpc.
+
+And for older libtirpc versions, there is no change in behaviour: we're
+still missing the -lpthread. But once libtirpc has been fixed, we'll
+automatically get that missing library for free! :-)
+
+Remove the --with-libirpc flag as it is no longer needed: pkg-config

This should probably have been --with-tirpcinclude, right?

Other than that the series looks good - Committed, thanks.

Signature · 1 line
Bye, Peter Korsgaard
#6 lore raw

PATCH v2 4/4 package/nfs-utils: use pkg-config to find libtirpc

Peter, All,

On 2014-11-27 23:28 +0100, Peter Korsgaard spake thusly:

Quoted 36 lines
Quoted 36 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Yann" == Yann E MORIN <[email protected]> writes:

Fixes:

    http://autobuild.buildroot.net/results/17d/17d1d94e6f1617851e374f4fe9804f1e5ea9e99f/
    http://autobuild.buildroot.net/results/c08/c08b7be40c8f208147a4f95ad897e4a1df7e108d/
    and probably some others as well...
---
 package/nfs-utils/0008-tirpc-with-pkgconfig.patch | 102 ++++++++++++++++++++++
 package/nfs-utils/nfs-utils.mk                    |   2 +-
 2 files changed, 103 insertions(+), 1 deletion(-)
 create mode 100644 package/nfs-utils/0008-tirpc-with-pkgconfig.patch
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +16 -0
new file mode 100644
index 0000000..62c820b
@@ -0,0 +1,102 @@
+From 1ecd1f2008bfab7bb3cd6ada135c980414a7f1ba Mon Sep 17 00:00:00 2001
+From: "Yann E. MORIN" <[email protected]>
+Date: Sun, 23 Nov 2014 15:53:56 +0100
+Subject: [PATCH] configure: use pkg-config to find libtirpc
+
+Currently, we use a custom function to find libtirpc's headers and
+libraries. This works fine for shared linking.
+
+But for static linking, this forgets to link with -lpthread, which is
+required by libtirpc.
+
+A recent patch was sent to libtirpc to add that missing -lpthread in its
+Libs.private section of its .pc file. Thus, pkg-config will soon be able
+to return the appropriate libraries.
+
+So, use pkg-config to find libtirpc.
Quoted 8 lines

package/nfs-utils/0008-tirpc-with-pkgconfig.patch line 22

Quoted 6 lines
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +6 -0
+
+And for older libtirpc versions, there is no change in behaviour: we're
+still missing the -lpthread. But once libtirpc has been fixed, we'll
+automatically get that missing library for free! :-)
+
+Remove the --with-libirpc flag as it is no longer needed: pkg-config

This should probably have been --with-tirpcinclude, right?

Yes, probably, yes. I'll wait news from upstream to see if they choke on this typo. ;-)

Quoted 1 line

Other than that the series looks good - Committed, thanks.

Thanks!

Regards,
Yann E. MORIN.

Signature · 6 lines
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'