From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5244 invoked by alias); 2 Sep 2004 11:48:13 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 5223 invoked from network); 2 Sep 2004 11:48:12 -0000 Received: from unknown (HELO psmtp.com) (12.158.35.212) by sourceware.org with SMTP; 2 Sep 2004 11:48:12 -0000 Received: from source ([192.150.22.8]) by exprod6ob2.obsmtp.com ([12.158.35.250]) with SMTP; Thu, 02 Sep 2004 04:48:11 PDT Received: from inner-relay-1.corp.adobe.com (inner-relay-1 [153.32.1.51]) by smtp-relay-8.adobe.com (8.12.10/8.12.10) with ESMTP id i82BltbA004081; Thu, 2 Sep 2004 04:48:00 -0700 (PDT) Received: from iplan-mn (iplan-mn.corp.adobe.com [130.248.25.5]) by inner-relay-1.corp.adobe.com (8.12.9/8.12.9) with ESMTP id i82BltTk029592; Thu, 2 Sep 2004 04:47:55 -0700 (PDT) Received: from mn-eljay-a51m.adobe.com ([130.248.178.74]) by iplan-mn.corp.adobe.com (iPlanet Messaging Server 5.2 HotFix 1.21 (built Sep 8 2003)) with ESMTP id <0I3E00KCVWRTVW@iplan-mn.corp.adobe.com>; Thu, 02 Sep 2004 06:47:55 -0500 (CDT) Date: Thu, 02 Sep 2004 11:48:00 -0000 From: Eljay Love-Jensen Subject: Re: Compiling on MacOSX is too long In-reply-to: <20040902083230.53248.qmail@web50102.mail.yahoo.com> X-Sender: eljay@iplan-mn.corp.adobe.com To: Exxos Sir , gcc-help@gcc.gnu.org Message-id: <6.1.2.0.2.20040902063922.01e9a0d8@iplan-mn.corp.adobe.com> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii; format=flowed Content-transfer-encoding: 7BIT References: <20040902083230.53248.qmail@web50102.mail.yahoo.com> X-SW-Source: 2004-09/txt/msg00014.txt.bz2 Hi, >The builds are too long. Some builds take a long time. There are several techniques you can employ to reduce build times. +) In your header files, try to use forward references where possible, instead of including the header files. +) To improve on #1, make "header-header" files. These files contain the forward references, and maybe a smattering of other public facilities (such as enums). Use the header-headers in your header files. The header that that the header-header represents should be the first thing included by the actual header file. +) Put guards in all your header files. +) Include all the headers (or header-headers) that your header or source file requires. Do not include anything beyond that! +) Do not make "kitchen sink header files", which include everything. +) Used the "pointer-to-implementation" technique (the "pimpl pattern"), to reduce rebuild time. +) Follow Lako's suggestions, Large-Scale C++ Software Design . +) Follow Peter Miller's suggestions, Recursive Make Considered Harmful . HTH, --Eljay