Comment 6 for bug 1849348

I've determined what is going on.

The linux headers from http://kernel.ubuntu.com/~kernel-ppa/mainline are built with a gcc 9 version. This causes CONFIG_CC_HAS_ASM_INLINE to be set to true.

However the gcc level that is installed by default on ubuntu 18.04.3 is still gcc 7.4. This level doesn't meet the criteria for supporting CONFIG_CC_HAS_ASM_INLINE, so the building with the linux headers will fail.

I manually set the CONFIG_CC_HAS_ASM_INLINE statements false in the linux 5.4 headers (deleted the line in include/generated/autoconf.h and set CONFIG_CC_HAS_ASM_INLINE=n in include/config/auto.conf).

With the above set, I was able to build using a gcc 7.4 compiler.

So.. either the dependency for the headers needs to include a compatible compiler level, or the headers need to be built to disable those features that are supplied by compilers higher then gcc 7.4.