diff options
author | Lionel Landwerlin <llandwerlin@gmail.com> | 2012-06-07 11:30:48 +0100 |
---|---|---|
committer | Tim-Philipp Müller <tim.muller@collabora.co.uk> | 2012-06-26 23:17:54 +0100 |
commit | c3ec4870981af82e3a1bde5e1612968ad01cf328 (patch) | |
tree | f869e424a2763f91ab9558a7e4afd3d27cf763de | |
parent | 36c61df29724eb2b2732eb0efb49ba897d0bb64a (diff) | |
download | gstreamer-c3ec4870981af82e3a1bde5e1612968ad01cf328.tar.gz |
configure: add --disable-tools and --disable-benchmarks options
Add option to avoid build binaries. When building for platforms like
android, you might want to not link any "final" binary, mostly because
it requires special link flags or other parts of code that aren't
in the C library.
https://bugzilla.gnome.org/show_bug.cgi?id=677621
-rw-r--r-- | Makefile.am | 6 | ||||
-rw-r--r-- | configure.ac | 28 | ||||
-rw-r--r-- | tests/Makefile.am | 8 |
3 files changed, 40 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am index 383dfc7669..9dcfd51f16 100644 --- a/Makefile.am +++ b/Makefile.am @@ -7,12 +7,16 @@ aclocaldir = $(datadir)/aclocal aclocal_DATA = gst-element-check-@GST_MAJORMINOR@.m4 SUBDIRS = pkgconfig \ - gst libs plugins tools tests \ + gst libs plugins tests \ docs \ po \ m4 \ common +if BUILD_TOOLS +SUBDIRS += tools +endif + # These are all the possible subdirs DIST_SUBDIRS = pkgconfig \ gst libs plugins tools tests \ diff --git a/configure.ac b/configure.ac index b1d831b7ac..0c95416995 100644 --- a/configure.ac +++ b/configure.ac @@ -170,6 +170,32 @@ else AC_MSG_WARN([Sissy ! By asking to not build the tests known to fail, you hereby waive your right to customer support. If you do not agree with this EULA, please press Ctrl-C before the next line is printed. By allowing the next line to be printed, you expressly acknowledge your acceptance of this EULA.]) fi +dnl building of benchmarks +AC_ARG_ENABLE(benchmarks, + AC_HELP_STRING([--disable-benchmarks], [disable building benchmarks apps]), + [ + case "${enableval}" in + yes) BUILD_BENCHMARKS=yes ;; + no) BUILD_BENCHMARKS=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --disable-benchmarks) ;; + esac + ], +[BUILD_BENCHMARKS=yes]) dnl Default value +AM_CONDITIONAL(BUILD_BENCHMARKS, test "x$BUILD_BENCHMARKS" = "xyes") + +dnl building of tools +AC_ARG_ENABLE(tools, + AC_HELP_STRING([--disable-tools], [disable building tools]), + [ + case "${enableval}" in + yes) BUILD_TOOLS=yes ;; + no) BUILD_TOOLS=no ;; + *) AC_MSG_ERROR(bad value ${enableval} for --disable-tools) ;; + esac + ], +[BUILD_TOOLS=yes]) dnl Default value +AM_CONDITIONAL(BUILD_TOOLS, test "x$BUILD_TOOLS" = "xyes") + dnl poison destroyed objects AC_ARG_ENABLE(poisoning, AC_HELP_STRING([--enable-poisoning], @@ -894,7 +920,9 @@ Configuration Debug : ${USE_DEBUG} Profiling : ${USE_PROFILING} + Building benchmarks : ${BUILD_BENCHMARKS} Building examples : ${BUILD_EXAMPLES} Building test apps : ${BUILD_TESTS} Building tests that fail : ${BUILD_FAILING_TESTS} + Building tools : ${BUILD_TOOLS} " diff --git a/tests/Makefile.am b/tests/Makefile.am index 23ff192b73..e5909fd97f 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -1,5 +1,11 @@ EXTRA_DIST = README +if BUILD_BENCHMARKS +SUBDIRS_BENCHMARKS = benchmarks +else +SUBDIRS_BENCHMARKS = +endif + if BUILD_TESTS ## SUBDIRS_TESTS = tests testsuite ## FIXME: write tests from scratch @@ -21,7 +27,7 @@ SUBDIRS_EXAMPLES = endif SUBDIRS = \ - benchmarks \ + $(SUBDIRS_BENCHMARKS) \ $(SUBDIRS_CHECK) \ misc \ $(SUBDIRS_TESTS) \ |