From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9727 invoked by alias); 21 Oct 2002 11:29:42 -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 9719 invoked from network); 21 Oct 2002 11:29:40 -0000 Received: from unknown (HELO sophia.inria.fr) (138.96.64.20) by sources.redhat.com with SMTP; 21 Oct 2002 11:29:40 -0000 Received: from sophia.inria.fr (norma.inria.fr [138.96.106.5]) by sophia.inria.fr (8.12.5/8.12.5) with ESMTP id g9LBTXnb006390; Mon, 21 Oct 2002 13:29:33 +0200 X-Authentication-Warning: sophia.inria.fr: Host norma.inria.fr [138.96.106.5] claimed to be sophia.inria.fr Message-ID: <3DB3E51D.C6C0AE3C@sophia.inria.fr> Date: Mon, 21 Oct 2002 04:29:00 -0000 From: Bui Ngoc Huy Binh Organization: Institut National de Recherche en Informatique et en Automatique (I.N.R.I.A) Sophia Antipolis - France X-Accept-Language: fr, fr-FR, en MIME-Version: 1.0 To: Claudio Bley CC: gcc-help@gcc.gnu.org Subject: Re: warnings when compiling References: <3DB3D179.36355A6B@sophia.inria.fr> <15795.57215.649515.876285@wh2-19.st.uni-magdeburg.de> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SW-Source: 2002-10/txt/msg00235.txt.bz2 that's ok now. thanks. :) Claudio Bley wrote: > > >>>>> "Bui" == Bui Ngoc Huy Binh writes: > > Bui> Hi, I use gcc release 3.2 to compile my programe. That's ok > Bui> but I got the warnings as: > > Bui> cc1: warning: changing search order for system directory > Bui> "/usr/local/include" cc1: warning: as it has already been > Bui> specified as a non-system directory ignoring duplicate > Bui> directory "/usr/local/include" cc1: warning: changing search > Bui> order for system directory "/usr/include" cc1: warning: as it > Bui> has already been specified as a non-system directory > > Bui> I don't understand and i don't know how to fix them ? Can you > Bui> help me ? > > I suppose you installed gcc in /usr/local. GCC then regards > /usr/local/include as a system include directory which implicitly is > searched for header files after any other non-system include > directories. > > If you specify -I/usr/local/include (what you don't need to) GCC > denotes this directory now as a non-system directory and thus changes > the search order for header files which it was just kind enough > informing you about. > > Just don't specify /usr/local/include as non-system include directory > if it already is a system directory. > > >From 'man cpp': > > -I directory > Add the directory directory to the end of the list of directories > to be searched for header files. This can be used to override a > system header file, substituting your own version, since these > directories are searched before the system header file > directories. If you use more than one `-I' option, the > directories are scanned in left-to-right order; the standard > system directories come after. > > -- > Claudio Bley ASCII ribbon campaign (") > Debian GNU/Linux advocate - against HTML email X > http://www.cs.uni-magdeburg.de/~bley/ & vCards / \