From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754936AbbJOH3f (ORCPT ); Thu, 15 Oct 2015 03:29:35 -0400 Received: from mail.kapsi.fi ([217.30.184.167]:44975 "EHLO mail.kapsi.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753311AbbJOH3e (ORCPT ); Thu, 15 Oct 2015 03:29:34 -0400 Date: Thu, 15 Oct 2015 10:29:33 +0300 From: Mikko Rapeli To: Alexander Stein Cc: linux-kernel@vger.kernel.org Subject: Re: [PATCH v4 02/79] scripts/headers_compile_test.sh: compile test script for exported headers Message-ID: <20151015072933.GV6104@lakka.kapsi.fi> References: <1444888618-4506-1-git-send-email-mikko.rapeli@iki.fi> <1444888618-4506-3-git-send-email-mikko.rapeli@iki.fi> <2701572.2qlRK3qY0P@ws-stein> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2701572.2qlRK3qY0P@ws-stein> X-SA-Exim-Connect-IP: 2001:1bc8:1004::1 X-SA-Exim-Mail-From: mikko.rapeli@iki.fi X-SA-Exim-Scanned: No (on mail.kapsi.fi); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Oct 15, 2015 at 09:17:18AM +0200, Alexander Stein wrote: > Hi Mikko, > > On Thursday 15 October 2015 07:55:40, Mikko Rapeli wrote: > > Users of kernel header files would be happier if they did not contain > > kernel specific parts and would contain #include statements for all > > other header files that they depend on, and in general would compile. > > > > For each header file exported to userspace, this script creates > > a simple .c file which just includes the header file. Then it > > tries to compile it together with minimal header files from GCC > > and libc, and reports results. > > Just an idea: Why not try to create a pre-compiled header (pch) instead. So you can get rid of creating temporary .c files for each header. Good idea. I'll explore this too. Currently the scripts abuse the headers_install target directory and leave cruft like these .c files and the hacked up libc headers around. I was planning to clean these up when actual headers are clean of compiler errors and when integrating this compile check to 'make headers_check'. -Mikko