From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by sourceware.org (Postfix) with ESMTPS id 0B4E93858C74 for ; Mon, 15 Aug 2022 13:13:58 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 0B4E93858C74 Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-551-5hnSRrIKMxC-5qcj9bzAcg-1; Mon, 15 Aug 2022 09:13:55 -0400 X-MC-Unique: 5hnSRrIKMxC-5qcj9bzAcg-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 4E35C29AB445; Mon, 15 Aug 2022 13:13:55 +0000 (UTC) Received: from oldenburg.str.redhat.com (unknown [10.39.192.36]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A2A6F112131B; Mon, 15 Aug 2022 13:13:54 +0000 (UTC) From: Florian Weimer To: Samuel Thibault Cc: libc-alpha@sourceware.org, commit-hurd@gnu.org Subject: Re: [PATCH] netinet/in.h: Add ip_mreqn structure References: <20220813210353.3553836-1-samuel.thibault@ens-lyon.org> Date: Mon, 15 Aug 2022 15:13:53 +0200 In-Reply-To: <20220813210353.3553836-1-samuel.thibault@ens-lyon.org> (Samuel Thibault's message of "Sat, 13 Aug 2022 23:03:53 +0200") Message-ID: <87pmh1k5ta.fsf@oldenburg.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-11.6 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 15 Aug 2022 13:13:59 -0000 * Samuel Thibault: > This is following the BSD and Linux definition. > --- > inet/netinet/in.h | 13 +++++++++++++ > 1 file changed, 13 insertions(+) > > diff --git a/inet/netinet/in.h b/inet/netinet/in.h > index 1633bc64e4..362eb9e9e7 100644 > --- a/inet/netinet/in.h > +++ b/inet/netinet/in.h > @@ -278,6 +278,19 @@ struct ip_mreq > struct in_addr imr_interface; > }; > =20 > +/* IPv4 multicast request with interface index. */ > +struct ip_mreqn > + { > + /* IP multicast address of group. */ > + struct in_addr imr_multiaddr; > + > + /* Local IP address of interface. */ > + struct in_addr imr_address; > + > + /* Interface index. */ > + int imr_ifindex; > + }; > + > struct ip_mreq_source > { > /* IP multicast address of group. */ I think you'll have to remove the definition from sysdeps/unix/sysv/linux/bits/in.h. python3 -B ../scripts/gen-as-const.py --cc=3D"gcc -m32 -std=3Dgnu11 -fgnu89= -inline -g -O2 -Wall -Wwrite-strings -Wundef -Werror -fmerge-all-constants= -frounding-math -fno-stack-protector -fno-common -Wstrict-prototypes -Wold= -style-definition -fmath-errno -ftls-model=3Dinitial-exec -I../in= clude -I/build/csu -I/build -I../sysdeps/unix/sysv/linux/i386/i686 -I../= sysdeps/i386/i686/nptl -I../sysdeps/unix/sysv/linux/i386 -I../sysdeps/uni= x/sysv/linux/x86/include -I../sysdeps/unix/sysv/linux/x86 -I../sysdeps/x86= /nptl -I../sysdeps/i386/nptl -I../sysdeps/unix/sysv/linux/include -I../sy= sdeps/unix/sysv/linux -I../sysdeps/nptl -I../sysdeps/pthread -I../sysdep= s/gnu -I../sysdeps/unix/inet -I../sysdeps/unix/sysv -I../sysdeps/unix/i3= 86 -I../sysdeps/unix -I../sysdeps/posix -I../sysdeps/i386/i686/fpu/multi= arch -I../sysdeps/i386/i686/fpu -I../sysdeps/i386/i686/multiarch -I../sy= sdeps/i386/i686 -I../sysdeps/i386/fpu -I../sysdeps/x86/fpu -I../sysdeps/= i386 -I../sysdeps/x86/include -I../sysdeps/x86 -I../sysdeps/wordsize-32 = -I../sysdeps/ieee754/float128 -I../sysdeps/ieee754/ldbl-96/include -I../sy= sdeps/ieee754/ldbl-96 -I../sysdeps/ieee754/dbl-64 -I../sysdeps/ieee754/fl= t-32 -I../sysdeps/ieee754 -I../sysdeps/generic -I.. -I../libio -I. -D_L= IBC_REENTRANT -include /build/libc-modules.h -DMODULE_NAME=3Dlibc -include = ../include/libc-symbols.h -DTOP_NAMESPACE=3Dglibc -DGEN_AS_CONST_HEAD= ERS \ =09=09 -MD -MP -MF /build/rtld-sizes.h.dT \ =09=09 -MT '/build/rtld-sizes.h.d /build/rtld-sizes.h'" \ =09 rtld-sizes.sym > /build/rtld-sizes.hT In file included from ../include/netinet/in.h:3, from ../resolv/bits/types/res_state.h:5, from ../include/bits/types/res_state.h:1, from ../nptl/descr.h:34, from ../sysdeps/i386/nptl/tls.h:114, from ../sysdeps/i386/i686/nptl/tls.h:32, from ../include/link.h:51, from :1: ../inet/netinet/in.h:282:8: error: redefinition of =E2=80=98struct ip_mreqn= =E2=80=99 282 | struct ip_mreqn | ^~~~~~~~ In file included from ../inet/netinet/in.h:37: ../sysdeps/unix/sysv/linux/bits/in.h:150:8: note: originally defined here 150 | struct ip_mreqn | ^~~~~~~~ Thanks, Florian