From: Larry Finger <Larry.Finger@lwfinger.net>
To: Joe Perches <joe@perches.com>, LKML <linux-kernel@vger.kernel.org>
Subject: Re: Build failures since 5.4-rc3
Date: Tue, 15 Oct 2019 15:27:23 -0500 [thread overview]
Message-ID: <bf0fbe49-65ec-e110-e937-b3b18df126c0@lwfinger.net> (raw)
In-Reply-To: <44f9a9bde7cf7885a8e55a52260b59240cb9a157.camel@perches.com>
On 10/15/19 2:32 PM, Joe Perches wrote:
>
> Hey Larry.
>
>
> Looks like this should be:
>
> #define FALL_THROUGH __attribute__((__fallthrough__))
>
> and there appear to be many of these #defines that
> use __attribute__((foo)) where foo does not use the
> double underscored prefix and suffix form
>
> I also downloaded and trivially attempted to build vbox
> without success, but I don't find this #define anywhere
> in the sources. Clues?
>
> $ git clone git://github.com/mirror/vbox.git
> $ cd vbox
>
> $ git grep FALL_THROUGH
> $
>
> $ ./configure
> Checking for environment: Determined build machine: linux.amd64, target machine: linux.amd64, OK.
> Checking for kBuild:
> ** kmk (variable KBUILDDIR) not found!
> Check /home/joe/vbox/configure.log for details
>
>
> $ cat configure.log
> # Log file generated by
> #
> # './configure '
> #
>
> ***** Checking environment *****
> Determined build machine: linux.amd64, target machine: linux.amd64
>
>
> ***** Checking kBuild *****
> ** kmk (variable KBUILDDIR) not found!
>
> $
I am the maintainer of VirtualBox for openSUSE, and it is their version that has
the problem.
The original code had the following macro definitions:
# define RT_FALL_THROUGH() __attribute__((fallthrough))
#define RT_FALL_THRU() RT_FALL_THROUGH()
The code uses both forms interchangeably. That failed - I think the () fooled
the compiler.
I replaced those with
#define FALL_THROUGH __attribute__((__fallthrough__))
#define RT_FALL_THRU() FALL_THROUGH
#define RT_FALL_THROUGH() FALL_THROUGH
My initial try was without the underscores around fallthrough, which caused a
conflict with the one in your changes. Putting them back resulted in code that
builds fine. Thanks for the help.
Larry
prev parent reply other threads:[~2019-10-15 20:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-15 19:09 Larry Finger
2019-10-15 19:32 ` Joe Perches
2019-10-15 20:27 ` Larry Finger [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bf0fbe49-65ec-e110-e937-b3b18df126c0@lwfinger.net \
--to=larry.finger@lwfinger.net \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®