Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755265AbcLASNx (ORCPT ); Thu, 1 Dec 2016 13:13:53 -0500 Received: from mail-vk0-f52.google.com ([209.85.213.52]:33282 "EHLO mail-vk0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752151AbcLASNv (ORCPT ); Thu, 1 Dec 2016 13:13:51 -0500 MIME-Version: 1.0 In-Reply-To: References: <20161126182006.24815-1-pefoley2@pefoley.com> <20161128064446.4892-1-pefoley2@pefoley.com> From: Peter Foley Date: Thu, 1 Dec 2016 10:13:30 -0800 Message-ID: Subject: Re: [PATCH v4] Fixes for compiling with clang To: Michal Marek Cc: LKML , linux-kbuild@vger.kernel.org Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 835 Lines: 20 On Tue, Nov 29, 2016 at 6:22 AM, Michal Marek wrote: > Dne 28.11.2016 v 07:44 Peter Foley napsal(a): > This adds new -Wno-* options also for the gcc case, is there a reason > for this? Also, the -Wno-missing-field-initializers option is not > available in some old gccs, so we would need a HOSTCC equivalent of > cc-disable-warning. > > Michal It appeared that the conditional was simply reversed, as -fno-delete-null-pointer-checks is only supported by gcc, and explicitly not supported by clang. (see https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/Makefile?id=61163efae02040f66a95c8ed17f4407951ba58fa) It could be that the fno-delete-null-pointer-checks option was simply misplaced, and the Wno-options should still be guarded by if(clang), would that be a better approach? Thanks, Peter