From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:35741) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aJgpx-0007vZ-Or for qemu-devel@nongnu.org; Thu, 14 Jan 2016 07:17:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aJgpw-0002pU-Mf for qemu-devel@nongnu.org; Thu, 14 Jan 2016 07:17:09 -0500 Date: Thu, 14 Jan 2016 12:17:02 +0000 From: "Daniel P. Berrange" Message-ID: <20160114121702.GN910@redhat.com> References: <1452624982-19332-1-git-send-email-berrange@redhat.com> <1452624982-19332-3-git-send-email-berrange@redhat.com> <20160113055327.GE25517@ad.usersys.redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20160113055327.GE25517@ad.usersys.redhat.com> Subject: Re: [Qemu-devel] [PATCH v1 02/15] crypto: add support for PBKDF2 algorithm Reply-To: "Daniel P. Berrange" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fam Zheng Cc: qemu-devel@nongnu.org, qemu-block@nongnu.org On Wed, Jan 13, 2016 at 01:53:27PM +0800, Fam Zheng wrote: > On Tue, 01/12 18:56, Daniel P. Berrange wrote: > > +#if defined CONFIG_NETTLE > > +#include "crypto/pbkdf-nettle.c" > > +#elif defined CONFIG_GCRYPT > > +#include "crypto/pbkdf-gcrypt.c" > > +#else /* ! CONFIG_GCRYPT */ > > +#include "crypto/pbkdf-stub.c" > > +#endif /* ! CONFIG_GCRYPT */ > > I think the convention in QEMU is in crypto/Makefile.objs: > > crypto-obj-$(CONFIG_NETTLE) += pbkdf-nettle.o > crypto-obj-$(if $(CONFIG_NETTLE),n,$(CONFIG_GCRYPT)) += pbkdf-gcrypt.o Ok, that's fine. > And move pbkdf-stub.c to stub/pbkdf.c. I'd rather key the source in the crypto/ directory since it matches up with MAINTAINER file rules. I can still add it to stub-obj-y in the makefile though, so that has same end effect on the build. Regards, Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|