From owner-freebsd-hackers@FreeBSD.ORG Thu Feb 8 21:29:14 2007 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EEB9B16A400 for ; Thu, 8 Feb 2007 21:29:14 +0000 (UTC) (envelope-from rizzo@icir.org) Received: from xorpc.icir.org (xorpc.icir.org [192.150.187.68]) by mx1.freebsd.org (Postfix) with ESMTP id DF58813C474 for ; Thu, 8 Feb 2007 21:29:14 +0000 (UTC) (envelope-from rizzo@icir.org) Received: from xorpc.icir.org (localhost [127.0.0.1]) by xorpc.icir.org (8.12.11/8.13.6) with ESMTP id l18KxAp6087851; Thu, 8 Feb 2007 12:59:10 -0800 (PST) (envelope-from rizzo@xorpc.icir.org) Received: (from rizzo@localhost) by xorpc.icir.org (8.12.11/8.12.3/Submit) id l18KxArS087850; Thu, 8 Feb 2007 12:59:10 -0800 (PST) (envelope-from rizzo) Date: Thu, 8 Feb 2007 12:59:10 -0800 From: Luigi Rizzo To: hackers@freebsd.org Message-ID: <20070208125910.A87229@xorpc.icir.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i Cc: Subject: kernel headers dependency graph ? (systm.h tangle) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Feb 2007 21:29:15 -0000 Hi, Is there a tool to produce a dependency graph for C headers ? If that matters (i.e. someone has already studied it), i am interested in the header situation in the FreeBSD kernel. It may be a well known thing, but i just realized that is entagled with and both bring in a lot of other headers, and you cannot bring in simply the string.h functions, or printf, because there is no leaf header for them. I don't know if this is the only case, or there are other 'classes' which are intermixed with lots of other stuff. I suppose the problem has been already discussed and it is just the result of historical reasons, but is there any reason other than ENOTIME why (to cite things that are trivial to fix while preserving compatibility): - we don't have sys/string.h with all the memcpy/bcopy and friends that are currently spread between systm.h and libkern.h - printf/scanf and strto*() are not in their own header; and so on ? cheers luigi