From owner-freebsd-questions@FreeBSD.ORG Tue Sep 11 00:30:25 2012 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 1D05E106564A for ; Tue, 11 Sep 2012 00:30:25 +0000 (UTC) (envelope-from bonomi@mail.r-bonomi.com) Received: from mail.r-bonomi.com (mx-out.r-bonomi.com [204.87.227.120]) by mx1.freebsd.org (Postfix) with ESMTP id C3D398FC16 for ; Tue, 11 Sep 2012 00:30:24 +0000 (UTC) Received: (from bonomi@localhost) by mail.r-bonomi.com (8.14.4/rdb1) id q8B0Ub0G083363 for freebsd-questions@freebsd.org; Mon, 10 Sep 2012 19:30:37 -0500 (CDT) Date: Mon, 10 Sep 2012 19:30:37 -0500 (CDT) From: Robert Bonomi Message-Id: <201209110030.q8B0Ub0G083363@mail.r-bonomi.com> To: freebsd-questions@freebsd.org Subject: Where are the mechancs of config(8) descibed X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Sep 2012 00:30:25 -0000 (This is probably a bit techical for 'questions' -- I'd welcome a suggesstion of a more appopriae forum.) Is there a detailed description anywhere of the mechanics of *how* config(8) does what it doess? I'm looking fo the gory detail of how, sayi, 'device bpf' causes the creation of the file 'opt_bpf.h' containing '#define DEV_BPF 1" _Part_ of the magic is the sys/conf/files* and sys/conf/options* files, but their format/content isn't defined anywhee I've found. rerason for asking -- I want to addd a cutom device driver into the kernel. I have sources, and can build the .o, if i convert it to a .ko, it loads and run. *BUT* I want to embed it in the kernel at build time. "Somewhere", I have do define 'device foo', specify that that name adds 'myfoo_sys.o' to the kernel object-files list, and that myfoo_sys.o depends on a list of source files, and requires a particular sequence of commands to build from those shources. I know the 'what', just not the 'where' or 'how'. Any pointers appreciated.