diff options
author | Thomas Haller <thaller@redhat.com> | 2017-02-08 16:18:11 +0100 |
---|---|---|
committer | Thomas Haller <thaller@redhat.com> | 2017-02-08 16:52:23 +0100 |
commit | 8bc88bcc7cc6e60abfabacd00591e01aaab9eac3 (patch) | |
tree | ea3cb0e25ed4c3414e325f5768e2cbcb5a623e0c | |
parent | a347962831ed127338a13b7a0939302d42bcfe60 (diff) | |
download | NetworkManager-8bc88bcc7cc6e60abfabacd00591e01aaab9eac3.tar.gz |
build: allow configuring path to binutils's nm tool during build
`nm` is used by "tools/create-exports-NetworkManager.sh" script.
Alloc configuring an explicit path during configure.
BINUTILS_NM=/usr/bin/nm ./configure
-rw-r--r-- | Makefile.am | 2 | ||||
-rw-r--r-- | configure.ac | 2 | ||||
-rwxr-xr-x | tools/create-exports-NetworkManager.sh | 2 |
3 files changed, 4 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am index b65e37cb37..268c02c3df 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1478,7 +1478,7 @@ src_libNetworkManagerTest_la_LIBADD = \ ############################################################################### src/NetworkManager.ver: src/libNetworkManager.la $(core_plugins) - $(AM_V_GEN) "$(srcdir)/tools/create-exports-NetworkManager.sh" --called-from-make "$(srcdir)" + $(AM_V_GEN) BINUTILS_NM="$(BINUTILS_NM)" "$(srcdir)/tools/create-exports-NetworkManager.sh" --called-from-make "$(srcdir)" CLEANFILES += src/NetworkManager.ver diff --git a/configure.ac b/configure.ac index ce36b2baa1..0ec4229f81 100644 --- a/configure.ac +++ b/configure.ac @@ -1121,6 +1121,8 @@ AM_PATH_PYTHON([], [], [PYTHON=python]) AC_SUBST(PYTHON, [$PYTHON]) AC_DEFINE_UNQUOTED(TEST_NM_PYTHON, "$PYTHON", [Define python path for test binary]) +AC_PATH_TOOL(BINUTILS_NM, nm, nm) + # check if we can build setting property documentation build_setting_docs=no if test -n "$INTROSPECTION_MAKEFILE"; then diff --git a/tools/create-exports-NetworkManager.sh b/tools/create-exports-NetworkManager.sh index 3a4619a46f..c1010f7229 100755 --- a/tools/create-exports-NetworkManager.sh +++ b/tools/create-exports-NetworkManager.sh @@ -29,7 +29,7 @@ _sort() { } call_nm() { - nm "$1" | + "${BINUTILS_NM:-${NM:-nm}}" "$1" | sed -n 's/.* \([^ ]\) \([^ ]*\)$/\1 \2/p' } |