From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:50887) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDG1e-0001Pm-4g for qemu-devel@nongnu.org; Sun, 16 Sep 2012 10:40:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TDG1d-0005Sc-0d for qemu-devel@nongnu.org; Sun, 16 Sep 2012 10:40:46 -0400 Received: from mail-ob0-f173.google.com ([209.85.214.173]:49788) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TDG1c-0005SW-Rh for qemu-devel@nongnu.org; Sun, 16 Sep 2012 10:40:44 -0400 Received: by obbta14 with SMTP id ta14so7592018obb.4 for ; Sun, 16 Sep 2012 07:40:44 -0700 (PDT) From: Anthony Liguori In-Reply-To: <505336E0.6010509@redhat.com> References: <50532E80.5060905@redhat.com> <505336E0.6010509@redhat.com> Date: Sun, 16 Sep 2012 09:40:40 -0500 Message-ID: <87r4q2ni8n.fsf@codemonkey.ws> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Subject: Re: [Qemu-devel] directory hierarchy List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini , Peter Maydell Cc: qemu-devel Paolo Bonzini writes: > Il 14/09/2012 15:36, Peter Maydell ha scritto: >> On 14 September 2012 14:17, Paolo Bonzini wrote: >>> here is a proposal for moving around 150 C files currently in the >>> toplevel directory to separate, well-delimited subdirectories. >> >> No general objection (though some specific comments below). However >> I think it would be helpful if you could provide some descriptions of >> how your new subdirectories are defined. Otherwise the "well-delimited" >> bit is largely in your head and future new files aren't likely to >> respect it except by accident :-) > > Good question. I just tried to use some taste, so well-delimited is a > bit of a lie. I mostly care that sysemu/, tools/, qga/ and user/ are > well-delimited, i.e. executables do not have sources from other > executables' directories, and similarly common/ is just for emulators. > >>> Header >>> files would be moved for now in include/, preparing for subsequent >>> reorganization of headers. >> >> Just in include/, or in include/qemu/ ? (IIRC Anthony was hoping >> to only move cleaned-up headers in there?) > > I dislike include/qemu, for the same reason I dislike qemu-*. :) It's good to put includes in a single direction such that you can do -Iinclude and then: #include "qemu/foo.h" Which is better than: #include "foo.h" Because the later can create confusion/conflict with system headers whereas the former is (hopefully) completely unambiguous. > Moving to include/ would be to clean up the top-level directory, withour > touching the source code. If something can be moved directly to one of > the new source directories, that's also fine but I don't have high > hopes. I actually thinking moving to -Iinclude is a Good Thing for now because it avoids touching a bunch of .c files. In the longer term, we should continue to clean up headers and move them into qemu/ though. Regards, Anthony Liguori