From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 31 14:29:04 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D851616A41F for ; Sat, 31 Dec 2005 14:29:04 +0000 (GMT) (envelope-from gilbert.fernandes@spamcop.net) Received: from mailgate.cesmail.net (mailgate.cesmail.net [216.154.195.36]) by mx1.FreeBSD.org (Postfix) with SMTP id 4287843D45 for ; Sat, 31 Dec 2005 14:29:04 +0000 (GMT) (envelope-from gilbert.fernandes@spamcop.net) Received: (qmail 4990 invoked from network); 31 Dec 2005 14:29:03 -0000 Received: from unknown (HELO delta.cesmail.net) (192.168.1.30) by mailgate.cesmail.net with SMTP; 31 Dec 2005 14:29:03 -0000 Received: (qmail 11260 invoked by uid 99); 31 Dec 2005 14:29:03 -0000 Received: from interne-05-23.anon.t-online.fr (interne-05-23.anon.t-online.fr [213.44.125.23]) by webmail.spamcop.net (Horde) with HTTP for ; Sat, 31 Dec 2005 15:29:03 +0100 Message-ID: <20051231152903.e6dmhg00c0g4oow8@webmail.spamcop.net> Date: Sat, 31 Dec 2005 15:29:03 +0100 From: Gilbert Fernandes To: prime References: <1fa17f810512301341w5b98d554g6dcf950ab26f31bd@mail.gmail.com> <20051231133853.pyq2hfoow4sgcsw8@webmail.spamcop.net> <1fa17f810512310455l3146b840w12a1a53361029608@mail.gmail.com> In-Reply-To: <1fa17f810512310455l3146b840w12a1a53361029608@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Disposition: inline Content-Transfer-Encoding: 7bit User-Agent: Internet Messaging Program (IMP) 4.0-cvs X-Mailman-Approved-At: Sat, 31 Dec 2005 15:34:00 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: Problem about libnet on FreeBSD 6.0 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: Sat, 31 Dec 2005 14:29:05 -0000 > ----- Message from guomingyan@gmail.com --------- > Date: Sat, 31 Dec 2005 20:55:38 +0800 > From: prime > Reply-To: prime > Subject: Re: Problem about libnet on FreeBSD 6.0 > To: Gilbert Fernandes > > On 12/31/05, Gilbert Fernandes wrote: > > > > > I find that I can't include when I programming > > > with libnet,because $(CC) complains that "struct ether_addr > redefined". > > > But I need some definitions in ,struct ether_header > etc. > > > Currently,I just copy the definitions I need from > ,but > > > it seems very ugly.Any one has some good ideas? > > > > Could you show us the include line you use ? > > > > #include "blabla" and > > #include > > > > will produce very different results as you know :) > > > > You do use #include ? > > > > -- > > unzip ; strip ; touch ; grep ; finger ; mount ; fsck ; more ; yes ; > > fsck ; umount ; sleep > > > Here is my include lines, > #include ...... > #include > #include > #include > ........... > and this is the error, > $(CC) said "/usr/local/include/./libnet/libnet-headers.h:393: error: > redefinition of `struct ether_addr'" > > > Thanks. > -- > Three passions, simple but overwhelmingly strong, have governed my life: > the longing for love, the search for knowledge, and unbearable pity for > the suffering of mankind. > ---------Bertrand Russell > > > ----- End message from guomingyan@gmail.com ----- Redefinition means that you have two declarations of the same function. One of the files you are including IS already including net/ethernet probably. Can you check ? :) -- unzip ; strip ; touch ; grep ; finger ; mount ; fsck ; more ; yes ; fsck ; umount ; sleep