From fddfd4e08b72aa39d577696ce0dc1b20f973bc29 Mon Sep 17 00:00:00 2001 From: Georg Schiesser Date: Tue, 5 May 2015 13:19:51 +0200 Subject: build-sys: support unshare.static This patch adds support for building a static version of unshare. We need to add unshare to the list of possible static programs, and provide build flags for the compiler and linker, which are equivalent to the flags of the non-static program, except additional static linking. See also: commit 2fa60c5 build-sys: support nsenter.static Signed-off-by: Georg Schiesser --- sys-utils/Makemodule.am | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'sys-utils/Makemodule.am') diff --git a/sys-utils/Makemodule.am b/sys-utils/Makemodule.am index 08bb6cea0..fcc5c53ef 100644 --- a/sys-utils/Makemodule.am +++ b/sys-utils/Makemodule.am @@ -357,6 +357,14 @@ dist_man_MANS += sys-utils/unshare.1 unshare_SOURCES = sys-utils/unshare.c unshare_LDADD = $(LDADD) libcommon.la unshare_CFLAGS = $(AM_CFLAGS) -I$(ul_libmount_incdir) + +if HAVE_STATIC_UNSHARE +usrbin_exec_PROGRAMS += unshare.static +unshare_static_SOURCES = $(unshare_SOURCES) +unshare_static_LDFLAGS = -all-static +unshare_static_LDADD = $(unshare_LDADD) +unshare_static_CFLAGS = $(unshare_CFLAGS) +endif endif if BUILD_NSENTER -- cgit v1.2.3-55-g7522