nfs-utils: fix static build (branch yem/for-release)
cover nfs-utils: fix static build (branch yem/for-release)
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.
Regards,
Yann E. MORIN.
The following changes since commit a5fc4225539a44eabf8b4ba9056a646ade14bf65:
infra: do not append an empty LD_LIBRARY_PATH (2014-11-23 14:14:58 +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 11a2fb7a110021c76aeee7d6ee193932d6c5b569:
package/nfs-utils: use pkg-config to find libtirpc (2014-11-23 14:16:24 +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 | 21 +++++++
...-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 | 71 ++++++++++++++++++++++
15 files changed, 92 insertions(+)
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.patchSignature · 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. | '------------------------------^-------^------------------^--------------------'
PATCH 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
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
package/libtirpc/0003-Make-IPv6-support-optional.patch renamed from package/libtirpc/libtirpc-0004-Make-IPv6-support-optional.patch +0 -0
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
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
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
Signature · 1 line
1.9.1
PATCH 2/4 package/libtirpc: add -pthread to the private libraries
In reply to Yann E. MORINFixes:
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 | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 package/libtirpc/0007-needs-pthread.patch
package/libtirpc/0007-needs-pthread.patch new file +21 -0
@@ -0,0 +1,21 @@ +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]> + +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
PATCH 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
package/nfs-utils/0002-Patch-taken-from-Gentoo.patch renamed from package/nfs-utils/nfs-utils-0002-Patch-taken-from-Gentoo.patch +0 -0
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
package/nfs-utils/0004-fix-build-with-uClibc.patch renamed from package/nfs-utils/nfs-utils-0004-fix-build-with-uClibc.patch +0 -0
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
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
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
Signature · 1 line
1.9.1
PATCH 4/4 package/nfs-utils: use pkg-config to find libtirpc
In reply to Yann E. MORINFixes:
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 | 71 +++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 package/nfs-utils/0008-tirpc-with-pkgconfig.patch
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +71 -0
@@ -0,0 +1,71 @@ +configure: use pkg-config to find libtirpc + +Signed-off-by: "Yann E. MORIN" <[email protected]> + +diff -durN nfs-utils-1.2.6.orig/aclocal/libtirpc.m4 nfs-utils-1.2.6/aclocal/libtirpc.m4 +--- nfs-utils-1.2.6.orig/aclocal/libtirpc.m4 2012-05-14 16:40:52.000000000 +0200 ++++ nfs-utils-1.2.6/aclocal/libtirpc.m4 2014-11-23 12:28:53.933717440 +0100 +@@ -11,40 +11,13 @@ + 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_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" != "no"], [AC_MSG_ERROR([libtirpc not found.])], ++ [LIBTIRPC=""])]) + + AC_SUBST(LIBTIRPC) + +diff -durN nfs-utils-1.2.6.orig/configure.ac nfs-utils-1.2.6/configure.ac +--- nfs-utils-1.2.6.orig/configure.ac 2014-11-23 13:48:42.636192256 +0100 ++++ nfs-utils-1.2.6/configure.ac 2014-11-23 13:53:15.695249004 +0100 +@@ -420,6 +420,12 @@ + AC_DEFINE_UNQUOTED(NFS_STATEDIR, "$statedir", [This defines the location of the NFS state files. Warning: this must match definitions in config.mk!]) + AC_DEFINE_UNQUOTED(NSM_DEFAULT_STATEDIR, "$statdpath", [Define this to the pathname where statd keeps its state file]) + ++dnl ************************************************************* ++dnl Aggregate all CFLAGS and CPPFLAGS ++dnl ************************************************************* ++CFLAGS="$CFLAGS $AM_CPPFLAGS" ++CPPFLAGS="$CPPFLAGS $AM_CPPFLAGS" ++ + if test "x$cross_compiling" = "xno"; then + CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-"$CFLAGS"} + CXXFLAGS_FOR_BUILD=${CXXFLAGS_FOR_BUILD-"$CXXFLAGS"}
Signature · 1 line
1.9.1
PATCH 4/4 package/nfs-utils: use pkg-config to find libtirpc
Peter, All,
On 2014-11-23 14:20 +0100, Yann E. MORIN spake thusly:
Quoted 17 lines
Fixes:
http://autobuild.buildroot.net/results/17d/17d1d94e6f1617851e374f4fe9804f1e5ea9e99f/ http://autobuild.buildroot.net/results/c08/c08b7be40c8f208147a4f95ad897e4a1df7e108d/ and probably some others as well...Signed-off-by "Yann E. MORIN" <[email protected]>--- package/nfs-utils/0008-tirpc-with-pkgconfig.patch | 71 +++++++++++++++++++++++ 1 file changed, 71 insertions(+) create mode 100644 package/nfs-utils/0008-tirpc-with-pkgconfig.patchpackage/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +0
-0
package/nfs-utils/0008-tirpc-with-pkgconfig.patch line 8
Quoted 8 lines
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +8
-0@@ -0,0 +1,71 @@ +configure: use pkg-config to find libtirpc + +Signed-off-by: "Yann E. MORIN" <[email protected]> + +diff -durN nfs-utils-1.2.6.orig/aclocal/libtirpc.m4 nfs-utils-1.2.6/aclocal/libtirpc.m4 +--- nfs-utils-1.2.6.orig/aclocal/libtirpc.m4 2012-05-14 16:40:52.000000000 +0200 ++++ nfs-utils-1.2.6/aclocal/libtirpc.m4 2014-11-23 12:28:53.933717440 +0100 +@@ -11,40 +11,13 @@
[--SNIP--]
package/nfs-utils/0008-tirpc-with-pkgconfig.patch line 52
Quoted 7 lines
package/nfs-utils/0008-tirpc-with-pkgconfig.patch new file +7
-0++ 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" != "no"], [AC_MSG_ERROR([libtirpc not found.])], ++ [LIBTIRPC=""])])
There's a latent bug hidiing in there (exercise: find it! ;-) ), and it's anyway not the patch I submitted upstream.
So I'll respin the series shortly.
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. | '------------------------------^-------^------------------^--------------------'
cover nfs-utils: fix static build (branch yem/for-release)
In reply to Yann E. MORINAll,
On 2014-11-23 14:19 +0100, Yann E. MORIN spake thusly:
Quoted 1 line
This small series fixes nfs-utils for static builds.
I forgot to say:
- I'm going to send the libtirpc upstream. That one is pretty trivial,
so I do not expect much reluctance from upstream to apply it;
- we're carrying nfs-utlis 1.2.6, while 1.3.1 has been out recently;
1.3.1 is not yet fixed anyway;- I'll send the nfs-utils patch upstream. On that one, I expect it might take some efforts to get it appplied; it might at least have to go through some iterations and so we might have a patch that is not exactly what upstream ends up applying, in which case I'll fix when we update to an nfs-utils that has been fixed.
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. | '------------------------------^-------^------------------^--------------------'