-e 's|[@]sysconfdir[@]|$(sysconfdir)|g' \
$(NULL)
+# Set these variables before we include any of the subdirs as libvirt-admin.la
+# has to be installed after libvirt.la.
+lib_LTLIBRARIES += libvirt.la libvirt-qemu.la libvirt-lxc.la
+
include util/Makefile.inc.am
include conf/Makefile.inc.am
include cpu/Makefile.inc.am
endif WITH_SECDRIVER_APPARMOR
-lib_LTLIBRARIES += libvirt.la libvirt-qemu.la libvirt-lxc.la
-
moddir = $(libdir)/libvirt/connection-driver
confdir = $(sysconfdir)/libvirt