[libdvbpsi-devel] [Git][videolan/libdvbpsi][master] Added a configure switch to enable/disable examples build
Jean-Paul Saman
gitlab at videolan.org
Fri Dec 7 13:04:18 CET 2018
Jean-Paul Saman pushed to branch master at VideoLAN / libdvbpsi
Commits:
5700ed2f by Konstantin Pavlov at 2018-11-30T17:29:05Z
Added a configure switch to enable/disable examples build
- - - - -
2 changed files:
- Makefile.am
- configure.ac
Changes:
=====================================
Makefile.am
=====================================
@@ -2,7 +2,12 @@
ACLOCAL_AMFLAGS=-I m4
-SUBDIRS = src examples misc
+SUBDIRS = src
+
+if BUILD_EXAMPLES
+SUBDIRS += examples misc
+endif
+
DIST_SUBDIRS = $(SUBDIRS) doc
EXTRA_DIST = libdvbpsi.spec libdvbpsi.spec.in libdvbpsi.pc.in bootstrap
@@ -15,9 +20,6 @@ doc-dummy:
doc: doc-dummy
$(MAKE) -C doc doc
-test_dr.c:
- $(MAKE) -C misc test_dr.c
-
changelog:
cvs2cl --utc --hide-filenames --no-wrap -w --stdout -g -z9 | \
sed -e 's/^[^0-9]/ /' -e 's/^ *$$//' -e 's/^ \* / /g' | \
@@ -30,5 +32,10 @@ dist-checksum: $(DIST_ARCHIVES)
sha256sum $$sum > $$sum.sha256; \
done
+if BUILD_EXAMPLES
+test_dr.c:
+ $(MAKE) -C misc test_dr.c
+
generate-header_dr:
misc/gen_dr_h.sh > src/descriptors/dr.h
+endif
=====================================
configure.ac
=====================================
@@ -145,6 +145,16 @@ if test "${ac_cv_asprintf}" != "no"; then
AC_DEFINE(HAVE_ASPRINTF, 1, [Support for asprintf() and vasprintf()])
fi
+# dnl Whether or not build examples
+AC_ARG_ENABLE([examples],
+ [AS_HELP_STRING([--enable-examples],
+ [build examples (default is yes)])],
+ [build_examples=$enableval],
+ [build_examples=yes])
+
+dnl use examples
+AM_CONDITIONAL([BUILD_EXAMPLES], [ test $build_examples = "yes" ])
+
dnl
dnl Generate Makefiles and other output files
dnl
@@ -166,4 +176,5 @@ release : ${release}
compatibility old api : ${compat}
compile flags : ${CFLAGS}
build for : ${SYS}
+build examples : ${build_examples}
"
View it on GitLab: https://code.videolan.org/videolan/libdvbpsi/commit/5700ed2f2311b3477706bac2fd030b2855720e68
--
View it on GitLab: https://code.videolan.org/videolan/libdvbpsi/commit/5700ed2f2311b3477706bac2fd030b2855720e68
You're receiving this email because of your account on code.videolan.org.
More information about the libdvbpsi-devel
mailing list