[Spice-devel] Require alsa only with --enable-client

Submitted by Christian Ruppert on Nov. 3, 2013, 5:38 p.m.

Details

Message ID 20131103173855.GB26430@tyr
State New
Headers show

Not browsing as part of any series.

Commit Message

Christian Ruppert Nov. 3, 2013, 5:38 p.m.
Hey guys,

the alsa libraries/header seem to be required only when configured with
--enable-client so I wrote a patch to make configure respect it.

Patch hide | download patch | download mbox

From 53683cc75ba092799f856f710cb45b2aacfb6123 Mon Sep 17 00:00:00 2001
From: Christian Ruppert <idl0r@gentoo.org>
Date: Sun, 3 Nov 2013 18:36:26 +0100
Subject: [PATCH] Require alsa only with --enable-client

---
 configure.ac | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/configure.ac b/configure.ac
index 7e81329..882bf1b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -246,12 +246,6 @@  fi
 AC_MSG_RESULT([found])
 fi
 
-if test "$os_linux" = yes; then
-	PKG_CHECK_MODULES(ALSA, alsa)
-	AC_SUBST(ALSA_CFLAGS)
-	AC_SUBST(ALSA_LIBS)
-fi
-
 PKG_CHECK_MODULES(SSL, openssl)
 AC_SUBST(SSL_CFLAGS)
 AC_SUBST(SSL_LIBS)
@@ -280,6 +274,12 @@  AC_SUBST(GL_LIBS)
 SPICE_NONPKGCONFIG_LIBS+=" $GL_LIBS"
 
 if test "x$red_target" = "xx11" && test "x$enable_client" = "xyes" ; then
+	if test "$os_linux" = yes; then
+		PKG_CHECK_MODULES(ALSA, alsa)
+		AC_SUBST(ALSA_CFLAGS)
+		AC_SUBST(ALSA_LIBS)
+	fi
+
 	PKG_CHECK_MODULES(XRANDR, xrandr)
 	PKG_CHECK_MODULES(XFIXES, xfixes)
 	PKG_CHECK_MODULES(MISC_X, x11 xext xrender)
-- 
1.8.1.5


Comments

On Sun, Nov 03, 2013 at 06:38:55PM +0100, Christian Ruppert wrote:
> Hey guys,
> 
> the alsa libraries/header seem to be required only when configured with
> --enable-client so I wrote a patch to make configure respect it.

ACK, thanks!

Christophe