aboutsummaryrefslogtreecommitdiff
path: root/package/elfutils/elfutils-01-disable-progs.patch
diff options
context:
space:
mode:
authorGravatar Thomas Petazzoni <thomas.petazzoni@free-electrons.com>2013-01-06 05:22:44 +0000
committerGravatar Peter Korsgaard <jacmet@sunsite.dk>2013-01-07 21:37:52 +0100
commit871846cad435ba3331a9f57c8939889ec86df887 (patch)
tree39b9534733d4e462e953e4ebe1eda76f80bb3c7d /package/elfutils/elfutils-01-disable-progs.patch
parent75bd7d13b2a772786df2b77be9af91ddda450174 (diff)
downloadbuildroot-871846cad435ba3331a9f57c8939889ec86df887.tar.gz
buildroot-871846cad435ba3331a9f57c8939889ec86df887.tar.bz2
elfutils: make it possible to only install the libraries
Add and use a --{enable,disable}-progs configuration option to selectively enable or disable the elfutils programs. Generally, on an embedded system, the libraries are more useful than the programs, and being able to not build the programs will make it easier to build the elfutils libraries on uClibc. Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Diffstat (limited to 'package/elfutils/elfutils-01-disable-progs.patch')
-rw-r--r--package/elfutils/elfutils-01-disable-progs.patch47
1 files changed, 47 insertions, 0 deletions
diff --git a/package/elfutils/elfutils-01-disable-progs.patch b/package/elfutils/elfutils-01-disable-progs.patch
new file mode 100644
index 0000000000..462de89e37
--- /dev/null
+++ b/package/elfutils/elfutils-01-disable-progs.patch
@@ -0,0 +1,47 @@
+Add a --{enable,disable}-progs configure option
+
+Add a --{enable,disable}-progs configuration option to elfutils. This
+allows to selectively disable the compilation of the elfutils programs
+(in which case only the libraries are built and installed). This is
+useful because the programs are often not needed, and also because
+building the programs against uClibc causes several issues (lack of
+obstack_printf() in uClibc for example).
+
+Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
+
+Index: b/Makefile.am
+===================================================================
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -22,9 +22,13 @@
+
+ pkginclude_HEADERS = version.h
+
++if ENABLE_PROGS
++PROGS_SUBDIR = src
++endif
++
+ # Add doc back when we have some real content.
+ SUBDIRS = config m4 lib libelf libebl libdwfl libdw libcpu libasm backends \
+- src po tests
++ $(PROGS_SUBDIR) po tests
+
+ EXTRA_DIST = elfutils.spec GPG-KEY NOTES CONTRIBUTING \
+ COPYING COPYING-GPLV2 COPYING-LGPLV3
+Index: b/configure.ac
+===================================================================
+--- a/configure.ac
++++ b/configure.ac
+@@ -263,6 +263,12 @@
+ AC_DEFINE_UNQUOTED(LIBEBL_SUBDIR, "$LIBEBL_SUBDIR")
+ AH_TEMPLATE([LIBEBL_SUBDIR], [$libdir subdirectory containing libebl modules.])
+
++AC_ARG_ENABLE([progs],
++ AS_HELP_STRING([--enable-progs], [enable progs]),
++ enable_progs=$enableval,
++ enable_progs=yes)
++AM_CONDITIONAL(ENABLE_PROGS, test "$enable_progs" = yes)
++
+ dnl Test for zlib and bzlib, gives ZLIB/BZLIB .am
+ dnl conditional and config.h USE_ZLIB/USE_BZLIB #define.
+ save_LIBS="$LIBS"