From owner-freebsd-current@FreeBSD.ORG Tue Jul 9 21:03:13 2013 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 2C78455A for ; Tue, 9 Jul 2013 21:03:13 +0000 (UTC) (envelope-from andreast-list@fgznet.ch) Received: from smtp.fgznet.ch (mail.fgznet.ch [81.92.96.47]) by mx1.freebsd.org (Postfix) with ESMTP id BF0EB1C57 for ; Tue, 9 Jul 2013 21:03:12 +0000 (UTC) Received: from deuterium.andreas.nets (dhclient-91-190-14-19.flashcable.ch [91.190.14.19]) by smtp.fgznet.ch (8.13.8/8.13.8/Submit_SMTPAUTH) with ESMTP id r69Kde82033942; Tue, 9 Jul 2013 22:40:53 +0200 (CEST) (envelope-from andreast-list@fgznet.ch) Message-ID: <51DC750C.6090707@fgznet.ch> Date: Tue, 09 Jul 2013 22:39:40 +0200 From: Andreas Tobler User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:17.0) Gecko/20130620 Thunderbird/17.0.7 MIME-Version: 1.0 To: Alexander Leidinger Subject: Re: kernel compile broken in latest HEAD References: <20130709173233.275469b4@ernst.home> <20130709223356.000005ad@unknown> In-Reply-To: <20130709223356.000005ad@unknown> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.64 on 81.92.96.47 Cc: FreeBSD Current X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Jul 2013 21:03:13 -0000 On 09.07.13 22:33, Alexander Leidinger wrote: > On Tue, 9 Jul 2013 17:32:33 +0200 > Gary Jennejohn wrote: > >> I just saw this breakage while compiling a kernel on HEAD updated >> minutes ago: So did I. > Is your cc a gcc or clang? My one is clang and I didn't get build > errors when I tested the commit. I was told there are those errors with > gcc. My question in the corresponding thread is so far unanswered. My cc is gcc, stock. > Here's what I wrote as a reference: > ---snip--- > Does someone know what this is supposed to result in? > > I would assume as the unions are unnamed and no variable is declared > inside the struct with it, that the size of the struct is the same as > not having those unions inside the structs. > > If this is correct I would assume the correct fix would be to #if-0 > them out. > ---snip--- I did so and my kernelbuild is happy now. Yes, I do not use this header at all. >> These line numbers all point at nameless unions. >> >> Seems to me that a union needs a name, otherwise one cannot >> access its contents. >> >> I simply named them all x to get the kernel to compile, which >> succeeded. > > Did you name it x ("union x {...};"), or did you declare a variable > x with it ("union {...} x;")?