From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10156 invoked by alias); 23 Oct 2002 10:45:03 -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 10133 invoked from network); 23 Oct 2002 10:45:00 -0000 Received: from unknown (HELO postino.fi.infn.it) (192.84.145.9) by sources.redhat.com with SMTP; 23 Oct 2002 10:45:00 -0000 Received: from pc213-02.inwind.it (pc213-02.fi.infn.it [193.206.190.187]) by postino.fi.infn.it (8.12.6/8.12.6) with ESMTP id g9NAeuwc016338; Wed, 23 Oct 2002 12:41:11 +0200 (CEST) Message-Id: <5.1.1.6.2.20021023123957.00b58208@popmail.libero.it> X-Sender: fwyzard-gcc@libero.it@popmail.libero.it Date: Wed, 23 Oct 2002 03:45:00 -0000 To: Nagu From: Andrea Bocci Subject: RE: Use +z or +Z to recompile... Cc: law@redhat.com, "'Venkatakrishnan, V'" , gcc-help@gcc.gnu.org In-Reply-To: <000501c27965$4b1c0320$f70b7d80@drb324> References: <200210211803.g9LI3LSF032715@porcupine.cygnus.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-RAVMilter-Version: 8.3.1(snapshot 20020109) (postino.fi.infn.it) X-Spam-Status: No, hits=-3.4 required=6.5 tests=IN_REP_TO version=2.31 X-SW-Source: 2002-10/txt/msg00283.txt.bz2 At 17.52 21/10/2002 -0700, Nagu wrote: >Hi all, >I have this problem of linking error using gcc, I have 4 simple files >first.c (where main function is defined), and myfunc1, myfunc2 and >incl.h (which defines another function called basefunc). When I compile, >I get fatal error saying that multiply defined "basefunc". How to get >rid of this? >Thanks >Best >nagu put #ifndef INCL_H #define INCL_H at the top of incl.h and #endif // ifndef INCL_H ad the end