Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1337589
| From | Kees Cook <keescook@chromium.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] kbuild: disable Android-specific compiler features |
| Date | 2016-02-18 19:00 +0100 |
| Message-ID | <r3B1V-Ga-3@gated-at.bofh.it> (permalink) |
| References | <qYZey-7Oq-7@gated-at.bofh.it> <r3jol-4YQ-13@gated-at.bofh.it> <r3te2-3vZ-9@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Thu, Feb 18, 2016 at 1:36 AM, Michal Marek <mmarek@suse.com> wrote: > Dne 18.2.2016 v 00:03 Kees Cook napsal(a): >> On Fri, Feb 5, 2016 at 4:44 PM, Kees Cook <keescook@chromium.org> wrote: >>> The Android compilers enable some non-standard features by default. While >>> most Android build systems inject the needed "-mno-android" option via >>> KCFLAGS, it happens too late (at least on x86_64), since KBUILD_CFLAGS >>> gains KCFLAGS after running (and failing) many cc-option tests. (For >>> example, the stack-protector tests happen after arch-specific >>> KBUILD_CFLAGS are added but before the external KCFLAGS are added.) As >>> such, we should notice this option and immediately turn it on as the >>> first cc-option test we run. >>> >>> Signed-off-by: Kees Cook <keescook@chromium.org> >> >> Michal, is this okay? I'd like to get it into -next soon if possible. > > Is there a way to detect these compilers and are there some canonical > versions of these? I do not think it's a good idea to add workaround for > each random gcc fork. It's detectable by -mno-android being a valid option. It's not a random gcc fork, as it's part of the Android SDK gcc prebuilts that all Android vendors and hobbiests use to build their kernels. -Kees -- Kees Cook Chrome OS & Brillo Security
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: [PATCH] kbuild: disable Android-specific compiler features Kees Cook <keescook@chromium.org> - 2016-02-18 00:10 +0100
Re: [PATCH] kbuild: disable Android-specific compiler features Michal Marek <mmarek@suse.com> - 2016-02-18 10:40 +0100
Re: [PATCH] kbuild: disable Android-specific compiler features Kees Cook <keescook@chromium.org> - 2016-02-18 19:00 +0100
csiph-web