From owner-freebsd-hackers@FreeBSD.ORG Sun Jul 15 19:42:15 2007 Return-Path: X-Original-To: freebsd-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 90B2716A400 for ; Sun, 15 Jul 2007 19:42:15 +0000 (UTC) (envelope-from soc@hbar.us) Received: from ug-out-1314.google.com (ug-out-1314.google.com [66.249.92.169]) by mx1.freebsd.org (Postfix) with ESMTP id 3040413C46B for ; Sun, 15 Jul 2007 19:42:13 +0000 (UTC) (envelope-from soc@hbar.us) Received: by ug-out-1314.google.com with SMTP id o4so960405uge for ; Sun, 15 Jul 2007 12:42:13 -0700 (PDT) Received: by 10.78.171.20 with SMTP id t20mr997206hue.1184526944134; Sun, 15 Jul 2007 12:15:44 -0700 (PDT) Received: by 10.78.138.5 with HTTP; Sun, 15 Jul 2007 12:15:44 -0700 (PDT) Message-ID: <47a4f3080707151215t42ed03adp3eab92984e8b670a@mail.gmail.com> Date: Sun, 15 Jul 2007 15:15:44 -0400 From: "Brian Chu" To: "=?ISO-8859-1?Q?Dag-Erling_Sm=F8rgrav?=" In-Reply-To: <86abvm3k89.fsf@dwp.des.no> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <43801.64.117.137.69.1180473436.squirrel@webmail.ifxnw.cl> <86abvm3k89.fsf@dwp.des.no> Cc: freebsd-hackers@freebsd.org, dmw@unete.cl Subject: Re: Setting up development environment 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: Sun, 15 Jul 2007 19:42:15 -0000 I have a question about indentation. In the previously supplied .emacs hook, tabs are represented by 8 spaces. Most of the kernel code, however, actually uses the tab character. Are both forms acceptable? If not, anyone willing to share their tab-character-tabs .emacs c hook? Thanks, Brian On 5/30/07, Dag-Erling Sm=F8rgrav wrote: > "Daniel Molina Wegener" writes: > > Is there any official way to setup a development environment for > > FreeBSD. I mean, I want to contribute with FreeBSD development. All > > I know that there is a Developer's Handbook, but what about setting a > > development environment for FreeBSD-CURRENT and -STABLE including > > from official c-mode-hooks and c++-mode-hooks for emacs to environment > > variables for cross-compiling the FreeBSD source. > > Emacs setup (for both C and C++): > > (defun des-knf () > (interactive) > > ;; Basic indent is 8 spaces > (make-local-variable 'c-basic-offset) > (setq c-basic-offset 8) > > ;; Continuation lines are indented 4 spaces > (make-local-variable 'c-offsets-alist) > (c-set-offset 'arglist-cont 4) > (c-set-offset 'arglist-cont-nonempty 4) > (c-set-offset 'statement-cont 4) > > ;; Labels are flush to the left > (c-set-offset 'label [0]) > > ;; Fill column > (make-local-variable 'fill-column) > (setq fill-column 74)) > > (add-hook 'c-mode-common-hook 'des-knf) > > As for how to cross-build, read build(7). > > DES > -- > Dag-Erling Sm=F8rgrav - des@des.no