[vlc-commits] jack: simplify build rules

Rémi Denis-Courmont git at videolan.org
Sun Sep 15 19:37:23 CEST 2013


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sun Sep 15 11:25:28 2013 +0300| [a0721c13f2ca2badb9b79701e47333156bcbb58b] | committer: Rémi Denis-Courmont

jack: simplify build rules

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=a0721c13f2ca2badb9b79701e47333156bcbb58b
---

 configure.ac                    |   11 ++++-------
 modules/access/Modules.am       |    8 +++++++-
 modules/audio_output/Modules.am |    5 +++--
 3 files changed, 14 insertions(+), 10 deletions(-)

diff --git a/configure.ac b/configure.ac
index 05593cd..c74ca35 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3636,7 +3636,8 @@ dnl
 AC_ARG_ENABLE(jack,
   [AS_HELP_STRING([--disable-jack],
     [do not use jack (default auto)])])
-if test "${enable_jack}" != "no" ; then
+have_jack="no"
+AS_IF([test "${enable_jack}" != "no"], [
     PKG_CHECK_MODULES(JACK, jack >= 1.9.7,
       [ have_jack=yes ],
       [
@@ -3650,12 +3651,8 @@ if test "${enable_jack}" != "no" ; then
          [AC_MSG_WARN([${JACK_PKG_ERRORS}.])])
       ])
     ])
-    if test "x${have_jack}" = "xyes" ;  then
-      VLC_ADD_PLUGIN([jack access_jack])
-      VLC_ADD_LIBS([jack access_jack],[$JACK_LIBS])
-      VLC_ADD_CFLAGS([jack access_jack],[$JACK_CFLAGS])
-    fi
-fi
+])
+AM_CONDITIONAL([HAVE_JACK], [test "${have_jack}" != "no"])
 
 dnl
 dnl  OpenSLES Android
diff --git a/modules/access/Modules.am b/modules/access/Modules.am
index 4e82ca6..3340876 100644
--- a/modules/access/Modules.am
+++ b/modules/access/Modules.am
@@ -65,7 +65,6 @@ SOURCES_linsys_hdsdi = \
 	linsys/linsys_sdiaudio.h \
 	linsys/linsys_sdivideo.h \
 	$(NULL)
-SOURCES_access_jack = jack.c
 SOURCES_access_mtp = mtp.c
 SOURCES_access_imem = imem.c
 SOURCES_access_attachment = attachment.c
@@ -143,6 +142,13 @@ if HAVE_ALSA
 libvlc_LTLIBRARIES += libaccess_alsa_plugin.la
 endif
 
+libaccess_jack_plugin_la_SOURCES = jack.c
+libaccess_jack_plugin_la_CFLAGS = $(AM_CFLAGS) $(JACK_CFLAGS)
+libaccess_jack_plugin_la_LIBADD = $(AM_LIBADD) $(JACK_LIBS)
+if HAVE_JACK
+libvlc_LTLIBRARIES += libaccess_jack_plugin.la
+endif
+
 libpulsesrc_plugin_la_SOURCES = pulse.c
 libpulsesrc_plugin_la_CFLAGS= $(AM_CFLAGS) $(PULSE_CFLAGS)
 libpulsesrc_plugin_la_LIBADD = ../libvlc_pulse.la \
diff --git a/modules/audio_output/Modules.am b/modules/audio_output/Modules.am
index 3af36c7..677a7d8 100644
--- a/modules/audio_output/Modules.am
+++ b/modules/audio_output/Modules.am
@@ -66,8 +66,9 @@ endif
 libjack_plugin_la_SOURCES = jack.c volume.h
 libjack_plugin_la_CFLAGS = $(AM_CFLAGS) $(JACK_CFLAGS)
 libjack_plugin_la_LIBADD = $(AM_LIBADD) $(JACK_LIBS) $(LIBM)
-EXTRA_LTLIBRARIES += libjack_plugin.la
-libvlc_LTLIBRARIES += $(LTLIBjack)
+if HAVE_JACK
+libvlc_LTLIBRARIES += libjack_plugin.la
+endif
 
 libmmdevice_plugin_la_SOURCES = mmdevice.c mmdevice.h wasapi.c
 libmmdevice_plugin_la_CFLAGS = $(AM_CFLAGS)



More information about the vlc-commits mailing list