From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753651AbdEJUyk (ORCPT ); Wed, 10 May 2017 16:54:40 -0400 Received: from userp1040.oracle.com ([156.151.31.81]:25892 "EHLO userp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751096AbdEJUyi (ORCPT ); Wed, 10 May 2017 16:54:38 -0400 Date: Wed, 10 May 2017 23:53:57 +0300 From: Dan Carpenter To: Randy Dunlap Cc: linux-kbuild , LKML , smatch@vger.kernel.org Subject: Re: sparse on scripts/kconfig/*.c Message-ID: <20170510205357.xshdaack6mwku5np@mwanda> References: <20170510101838.c5nwzaraeybyypwj@mwanda> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170510101838.c5nwzaraeybyypwj@mwanda> User-Agent: NeoMutt/20170113 (1.7.2) X-Source-IP: userv0021.oracle.com [156.151.31.71] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org I have created some new tools to make this process easier. 1) First you still have to edit the Makefile: -HOSTCC = gcc +HOSTCC = ~/progs/smatch/devel/cgcc 2) Build the data with this command: ~/progs/smatch/devel/smatch_scripts/build_generic_data.sh --target scripts/ The --target scripts/ is because we want to run smatch on the scripts/ directory. 3) Run smatch: ~/progs/smatch/devel/smatch_scripts/test_generic.sh --target scripts/ I just wrote this code today so it might be a bit rough perhaps. Let me know if you have any issues. It doesn't find anything like I said before, but hopefully this can help other people who want to run Smatch on user space code. regards, dan carpenter