]> git.sesse.net Git - vlc/commitdiff
Add a --disable-vlc configure flag to not build VLC.
authorSam Hocevar <sam@zoy.org>
Wed, 19 Mar 2008 13:18:09 +0000 (13:18 +0000)
committerSam Hocevar <sam@zoy.org>
Wed, 19 Mar 2008 13:25:34 +0000 (13:25 +0000)
In some cases (eg. when building binary packages) one only needs libvlc
and libvlc-control and does not wish to build or install VLC binaries.
This --disable-vlc flag saves us from manually removing the unwanted
binaries after "make install".

Makefile.am
configure.ac
src/Makefile.am

index 498d5cd776bff64b8d422229877d5c74c0c77525..870250f3f57ccdf12d57f60ef246a7fd0f917521 100644 (file)
@@ -289,7 +289,9 @@ endif
 ALL_ALIASES = cvlc rvlc svlc wxvlc qvlc nvlc
 bin_SCRIPTS += $(ALIASES)
 CLEANFILES += $(ALIASES)
+if BUILD_VLC
 EXTRA_SCRIPTS = $(ALL_ALIASES)
+endif
 
 dist_noinst_SCRIPTS += make-alias
 
@@ -313,7 +315,9 @@ qvlc: make-alias
 nvlc: make-alias
        $(MKALIAS) ncurses
 
+if BUILD_VLC
 noinst_SCRIPTS = vlc$(EXEEXT)
+endif
 
 vlc$(EXEEXT): core
        rm -f vlc$(EXEEXT)
@@ -326,7 +330,9 @@ vlc$(EXEEXT): core
 
 if HAVE_DARWIN
 # Create the MacOS X app
+if BUILD_VLC
 noinst_DATA = VLC.app
+endif
 # VLC-release.app is the old VLC.app target
 VLC-release.app: vlc
        ( cd src && make install )
index 9c495a8516d36effdf93477ecc6348ecfe94034c..d62ff27c865bfd677c7f2724ab9ea9aeb73951d8 100644 (file)
@@ -5721,6 +5721,15 @@ AS_IF([test "${enable_loader}" = "yes"],
     VLC_ADD_LIBS([realaudio],[../../libs/loader/libloader.la])
   ])
 
+AC_ARG_WITH(,[Components:])
+
+dnl
+dnl  the VLC binary
+dnl
+AC_ARG_ENABLE(vlc,
+  [  --enable-vlc            build the VLC media player (default enabled)])
+AM_CONDITIONAL(BUILD_VLC, [test "${enable_vlc}" != "no"])
+
 dnl
 dnl  Microsoft ActiveX support
 dnl
@@ -6300,9 +6309,9 @@ echo exit \$ERROR >>compile
 chmod a+x compile
 
 printf "
-vlc configuration
+libvlc configuration
 --------------------
-vlc version           : ${VERSION}
+version               : ${VERSION}
 system                : ${SYS}
 architecture          : ${ARCH}
 build flavour         : "
@@ -6311,9 +6320,13 @@ test "${enable_cprof}" = "yes" && printf "cprof "
 test "${enable_gprof}" = "yes" && printf "gprof "
 test "${enable_optimizations}" = "yes" && printf "optim "
 test "${enable_release}" = "yes" && printf "release " || printf "devel "
-echo "
-vlc aliases           :${ALIASES}
-plugins/bindings      :${PLUGINS_BINDINGS}
+echo ""
+if test "${enable_vlc}" != "no"; then
+echo "vlc aliases           :${ALIASES}"
+else
+echo "build vlc executable  : no"
+fi
+echo "plugins/bindings      :${PLUGINS_BINDINGS}
 
 You can check which modules have been enabled 
 with \`./vlc-config --list plugin'.
index dae043efb6aff4fcb2097320f8713b7822c05e1b..f6402771a5dbdb1fcd32bc040bbe3830db191524 100644 (file)
@@ -388,8 +388,10 @@ misc/revision.c:
 # Building vlc
 ###############################################################################
 
+if BUILD_VLC
 bin_PROGRAMS = vlc
-# 
+endif
+
 vlc_SOURCES = vlc.c
 vlc_DEPENDENCIES = $(DATA_win32_rc) libvlc.la
 
@@ -397,6 +399,7 @@ vlc_CFLAGS = `$(VLC_CONFIG) --cflags vlc`
 vlc_LDFLAGS = `$(VLC_CONFIG) --ldflags vlc`
 vlc_LDADD = $(DATA_win32_rc) libvlc.la $(LTLIBINTL) `$(VLC_CONFIG) -libs vlc`
 
+if BUILD_VLC
 vlc$(EXEEXT): $(vlc_OBJECTS) $(vlc_DEPENDENCIES)
        @rm -f vlc$(EXEEXT)
        @case `$(VLC_CONFIG) --linkage vlc builtin` in \
@@ -415,6 +418,7 @@ noinst_DATA = vlc_win32_rc.$(OBJEXT)
 vlc_win32_rc.$(OBJEXT): $(top_srcdir)/share/vlc_win32_rc.rc
        $(WINDRES) -DVERSION=$(VERSION) -DVERSION_NUMBER=`echo $(VERSION).0.0.0 | sed 's/\([0-9]*\)[^.]*\.*\([0-9]*\)[^.]*\.*\([0-9]*\)[^.]*\.*\([0-9]*\).*/\1,\2,\3,\4/'` --include-dir $(top_srcdir)/share -i $< -o $@
 endif
+endif
 
 ###############################################################################
 # Unit/regression test