RE: [PATCH 05/45] C++: Set compilation as C++ for .c files
> > Hi David, > > On Tue, Apr 10, 2018 at 09:44:14AM +0100, David Howells wrote: > >Hi Fengguang, > > > >There's another kbuild test that's probably worth adding if you don't do it > >already: create a c++ source file that just #includes all the exported UAPI > >headers and then try to build it. This should catch words like "private" > >cropping up in structs. > > That's a good idea! And it looks straightforward to do. > CC Philip (current LKP maintainer) for possible plans. Thanks David, we will look into this and planned with other priorities. We will share estimation for possible target date next week. > > Thanks, > Fengguang
RE: [PATCH 05/45] C++: Set compilation as C++ for .c files
> > Hi David, > > On Tue, Apr 10, 2018 at 09:44:14AM +0100, David Howells wrote: > >Hi Fengguang, > > > >There's another kbuild test that's probably worth adding if you don't do it > >already: create a c++ source file that just #includes all the exported UAPI > >headers and then try to build it. This should catch words like "private" > >cropping up in structs. > > That's a good idea! And it looks straightforward to do. > CC Philip (current LKP maintainer) for possible plans. Thanks David, we will look into this and planned with other priorities. We will share estimation for possible target date next week. > > Thanks, > Fengguang
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi David, On Tue, Apr 10, 2018 at 09:44:14AM +0100, David Howells wrote: Hi Fengguang, There's another kbuild test that's probably worth adding if you don't do it already: create a c++ source file that just #includes all the exported UAPI headers and then try to build it. This should catch words like "private" cropping up in structs. That's a good idea! And it looks straightforward to do. CC Philip (current LKP maintainer) for possible plans. Thanks, Fengguang
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi David, On Tue, Apr 10, 2018 at 09:44:14AM +0100, David Howells wrote: Hi Fengguang, There's another kbuild test that's probably worth adding if you don't do it already: create a c++ source file that just #includes all the exported UAPI headers and then try to build it. This should catch words like "private" cropping up in structs. That's a good idea! And it looks straightforward to do. CC Philip (current LKP maintainer) for possible plans. Thanks, Fengguang
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi Fengguang, There's another kbuild test that's probably worth adding if you don't do it already: create a c++ source file that just #includes all the exported UAPI headers and then try to build it. This should catch words like "private" cropping up in structs. Thanks, David
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi Fengguang, There's another kbuild test that's probably worth adding if you don't do it already: create a c++ source file that just #includes all the exported UAPI headers and then try to build it. This should catch words like "private" cropping up in structs. Thanks, David
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
On Tue, Apr 03, 2018 at 02:16:50PM +0100, David Howells wrote: kbuild test robotwrote: scripts/Makefile.kasan:17: Cannot use CONFIG_KASAN: -fsanitize=kernel-address is not supported by compiler cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but not for C cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ but not for C It would need to use g++-8 to compile it ;-) Awesome! :) Cheers, Fengguang
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
On Tue, Apr 03, 2018 at 02:16:50PM +0100, David Howells wrote: kbuild test robot wrote: scripts/Makefile.kasan:17: Cannot use CONFIG_KASAN: -fsanitize=kernel-address is not supported by compiler cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but not for C cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ but not for C It would need to use g++-8 to compile it ;-) Awesome! :) Cheers, Fengguang
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
kbuild test robotwrote: >scripts/Makefile.kasan:17: Cannot use CONFIG_KASAN: > -fsanitize=kernel-address is not supported by compiler >cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but > not for C >cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ > but not for C It would need to use g++-8 to compile it ;-) David
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
kbuild test robot wrote: >scripts/Makefile.kasan:17: Cannot use CONFIG_KASAN: > -fsanitize=kernel-address is not supported by compiler >cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but > not for C >cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ > but not for C It would need to use g++-8 to compile it ;-) David
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi David, I love your patch! Yet something to improve: [auto build test ERROR on v4.16-rc7] [cannot apply to linus/master tip/x86/core tip/locking/core v4.16 next-20180329] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/David-Howells/C-Convert-the-kernel-to-C/20180402-120344 config: x86_64-randconfig-x014-201813 (attached as .config) compiler: gcc-7 (Debian 7.3.0-1) 7.3.0 reproduce: # save the attached .config to linux build tree make ARCH=x86_64 All errors (new ones prefixed by >>): scripts/Makefile.kasan:17: Cannot use CONFIG_KASAN: -fsanitize=kernel-address is not supported by compiler cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but not for C cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ but not for C In file included from include/linux/page-flags.h:9:0, from kernel/bounds.c:10: >> include/linux/types.h:6:2: error: #error not c++ #error not c++ ^ make[2]: *** [kernel/bounds.s] Error 1 make[2]: Target '__build' not remade because of errors. make[1]: *** [prepare0] Error 2 make[1]: Target 'prepare' not remade because of errors. make: *** [sub-make] Error 2 vim +6 include/linux/types.h 4 5 #ifndef __cplusplus > 6 #error not c++ 7 #endif 8 --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: application/gzip
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi David, I love your patch! Yet something to improve: [auto build test ERROR on v4.16-rc7] [cannot apply to linus/master tip/x86/core tip/locking/core v4.16 next-20180329] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/David-Howells/C-Convert-the-kernel-to-C/20180402-120344 config: x86_64-randconfig-x014-201813 (attached as .config) compiler: gcc-7 (Debian 7.3.0-1) 7.3.0 reproduce: # save the attached .config to linux build tree make ARCH=x86_64 All errors (new ones prefixed by >>): scripts/Makefile.kasan:17: Cannot use CONFIG_KASAN: -fsanitize=kernel-address is not supported by compiler cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but not for C cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ but not for C In file included from include/linux/page-flags.h:9:0, from kernel/bounds.c:10: >> include/linux/types.h:6:2: error: #error not c++ #error not c++ ^ make[2]: *** [kernel/bounds.s] Error 1 make[2]: Target '__build' not remade because of errors. make[1]: *** [prepare0] Error 2 make[1]: Target 'prepare' not remade because of errors. make: *** [sub-make] Error 2 vim +6 include/linux/types.h 4 5 #ifndef __cplusplus > 6 #error not c++ 7 #endif 8 --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: application/gzip
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi David, I love your patch! Yet something to improve: [auto build test ERROR on v4.16-rc7] [cannot apply to linus/master tip/x86/core tip/locking/core v4.16 next-20180329] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/David-Howells/C-Convert-the-kernel-to-C/20180402-120344 config: i386-randconfig-x073-201813 (attached as .config) compiler: gcc-7 (Debian 7.3.0-1) 7.3.0 reproduce: # save the attached .config to linux build tree make ARCH=i386 All error/warnings (new ones prefixed by >>): CONFIG_CC_STACKPROTECTOR_AUTO: Compiler does not support any known stack-protector >> cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but >> not for C >> cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ but >> not for C >> cc1: error: CPU you selected does not support x86-64 instruction set make[2]: *** [kernel/bounds.s] Error 1 make[2]: Target '__build' not remade because of errors. make[1]: *** [prepare0] Error 2 make[1]: Target 'prepare' not remade because of errors. make: *** [sub-make] Error 2 --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: application/gzip
Re: [PATCH 05/45] C++: Set compilation as C++ for .c files
Hi David, I love your patch! Yet something to improve: [auto build test ERROR on v4.16-rc7] [cannot apply to linus/master tip/x86/core tip/locking/core v4.16 next-20180329] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/David-Howells/C-Convert-the-kernel-to-C/20180402-120344 config: i386-randconfig-x073-201813 (attached as .config) compiler: gcc-7 (Debian 7.3.0-1) 7.3.0 reproduce: # save the attached .config to linux build tree make ARCH=i386 All error/warnings (new ones prefixed by >>): CONFIG_CC_STACKPROTECTOR_AUTO: Compiler does not support any known stack-protector >> cc1: warning: command line option '-fno-rtti' is valid for C++/ObjC++ but >> not for C >> cc1: warning: command line option '-fpermissive' is valid for C++/ObjC++ but >> not for C >> cc1: error: CPU you selected does not support x86-64 instruction set make[2]: *** [kernel/bounds.s] Error 1 make[2]: Target '__build' not remade because of errors. make[1]: *** [prepare0] Error 2 make[1]: Target 'prepare' not remade because of errors. make: *** [sub-make] Error 2 --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation .config.gz Description: application/gzip