build: fix linking virt-login-shell
build: fix linking virt-login-shell

After commit 3e2f27e1, I've noticed build failures of virt-login-shell
when libapparmor-devel is installed on the build host

CCLD     virt-login-shell
../src/.libs/libvirt-setuid-rpc-client.a(libvirt_setuid_rpc_client_la-vircommand.o):
In function `virExec':
/home/jfehlig/virt/upstream/libvirt/src/util/vircommand.c:653: undefined
reference to `aa_change_profile'
collect2: error: ld returned 1 exit status

I was about to commit an easy fix under the build-breaker rule
(build-fix-1.patch), but thought to extend the notion of SECDRIVER_LIBS
to SECDRIVER_CFLAGS, and use both throughout src/Makefile.am where it
makes sense (build-fix-2.patch).

Should I just stick with the simple fix, or is something along the lines
of patch 2 preferred?

Regards,
Jim

>From a0f35945f3127ab70d051101037e821b1759b4bb Mon Sep 17 00:00:00 2001
From: Jim Fehlig <39929b5b86d72d51fceac59b52303e3fe8a3083e@suse.com>
Date: Mon, 21 Oct 2013 15:30:02 -0600
Subject: [PATCH] build: fix virt-login-shell build with apparmor

With libapparmor-devel installed, virt-login-shell fails to link

CCLD     virt-login-shell
../src/.libs/libvirt-setuid-rpc-client.a(libvirt_setuid_rpc_client_la-vircommand.o): In function `virExec':
/home/jfehlig/virt/upstream/libvirt/src/util/vircommand.c:653: undefined reference to `aa_change_profile'
collect2: error: ld returned 1 exit status

Fix by linking libvirt_setuid_rpc_client with previously determined
SECDRIVER_LIBS in src/Makefile.am.  While at it, introduce SECDRIVER_CFLAGS
and use both throughout src/Makefile.am where it makes sense.

Signed-off-by: Jim Fehlig <39929b5b86d72d51fceac59b52303e3fe8a3083e@suse.com>

jardasgit/libvirt,libvirt/libvirt,VenkatDatta/libvirt,rlaager/libvirt,zippy2/libvirt,crobinso/libvirt,elmarco/libvirt,shugaoye/libvirt,taget/libvirt,rlaager/libvirt,andreabolognani/libvirt,fabianfreyer/libvirt,crobinso/libvirt,jardasgit/libvirt,andreabolognani/libvirt,andreabolognani/libvirt,cbosdo/libvirt,cbosdo/libvirt,shugaoye/libvirt,agx/libvirt,rlaager/libvirt,libvirt/libvirt,jardasgit/libvirt,zhlcindy/libvirt-1.1.4-maintain,cbosdo/libvirt,jfehlig/libvirt,zhlcindy/libvirt-1.1.4-maintain,rlaager/libvirt,fabianfreyer/libvirt,VenkatDatta/libvirt,eskultety/libvirt,olafhering/libvirt,agx/libvirt,agx/libvirt,fabianfreyer/libvirt,nertpinx/libvirt,zippy2/libvirt,agx/libvirt,shugaoye/libvirt,taget/libvirt,eskultety/libvirt,cbosdo/libvirt,jardasgit/libvirt,zhlcindy/libvirt-1.1.4-maintain,crobinso/libvirt,nertpinx/libvirt,jfehlig/libvirt,taget/libvirt,taget/libvirt,datto/libvirt,datto/libvirt,jfehlig/libvirt,VenkatDatta/libvirt,eskultety/libvirt,zippy2/libvirt,jfehlig/libvirt,taget/libvirt,olafhering/libvirt,nertpinx/libvirt,VenkatDatta/libvirt,zippy2/libvirt,eskultety/libvirt,zhlcindy/libvirt-1.1.4-maintain,libvirt/libvirt,fabianfreyer/libvirt,nertpinx/libvirt,elmarco/libvirt,crobinso/libvirt,cbosdo/libvirt,zhlcindy/libvirt-1.1.4-maintain,elmarco/libvirt,olafhering/libvirt,datto/libvirt,libvirt/libvirt,jardasgit/libvirt,datto/libvirt,agx/libvirt,fabianfreyer/libvirt,andreabolognani/libvirt,datto/libvirt,elmarco/libvirt,andreabolognani/libvirt,rlaager/libvirt,eskultety/libvirt,elmarco/libvirt,olafhering/libvirt,VenkatDatta/libvirt,shugaoye/libvirt,nertpinx/libvirt,shugaoye/libvirt