From patchwork Sun Dec 5 06:52:15 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnaud Lacombe X-Patchwork-Id: 380731 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oB56r7qj024282 for ; Sun, 5 Dec 2010 06:53:07 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753217Ab0LEGxH (ORCPT ); Sun, 5 Dec 2010 01:53:07 -0500 Received: from mail-gx0-f180.google.com ([209.85.161.180]:59894 "EHLO mail-gx0-f180.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752263Ab0LEGxG (ORCPT ); Sun, 5 Dec 2010 01:53:06 -0500 Received: by mail-gx0-f180.google.com with SMTP id 19so5956086gxk.11 for ; Sat, 04 Dec 2010 22:53:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:cc:subject:date :message-id:x-mailer:in-reply-to:references; bh=lWfGcanau9aaZbK5OQkwXlliFX/L8SffyIuusGXJ+DI=; b=uKLi4Jou+Lpl+A6rRNKk0jD3aRZie9o9ftgxbD92NznRoKgmeD5jIZcXMJKAdVjbg1 yVorr/96xzaxU2vS97LacyXyzd4c5e/+rf275b0J3SjwQL632AwRGnMoi2jO5dIl1Y/i tqwLpvKWKDGkXItpw4OebU3+f3fvcugFL8tNU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; b=WlYjK2Iu+l5uxNnGTcgpQTVgwZxzvoi9/wyMsyZFImkQ0V7hSpJ2lWN5x8YmeuRbNF T3ti5aAEY3g25Ge3zOrLRzRH3+IBnOofGSLtOkxsWZtUgvm0/tCJJF+BfdlBnylrbs5+ hvvvW+B2LAxpBDMk6ar6QiZtz3CmdqLh/+1mM= Received: by 10.150.12.14 with SMTP id 14mr3305914ybl.278.1291531986011; Sat, 04 Dec 2010 22:53:06 -0800 (PST) Received: from localhost.localdomain (75-119-248-218.dsl.teksavvy.com [75.119.248.218]) by mx.google.com with ESMTPS id r18sm2451094yba.3.2010.12.04.22.53.05 (version=SSLv3 cipher=RC4-MD5); Sat, 04 Dec 2010 22:53:05 -0800 (PST) From: Arnaud Lacombe To: linux-kbuild@vger.kernel.org Cc: Arnaud Lacombe Subject: [PATCH 2/2] kconfig/conf: add command line options' description Date: Sun, 5 Dec 2010 01:52:15 -0500 Message-Id: <1291531935-6183-2-git-send-email-lacombar@gmail.com> X-Mailer: git-send-email 1.7.2.30.gc37d7.dirty In-Reply-To: <1291531935-6183-1-git-send-email-lacombar@gmail.com> References: <1291531935-6183-1-git-send-email-lacombar@gmail.com> Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Sun, 05 Dec 2010 06:53:07 +0000 (UTC) diff --git a/scripts/kconfig/conf.c b/scripts/kconfig/conf.c index 057f49a..5297dbf 100644 --- a/scripts/kconfig/conf.c +++ b/scripts/kconfig/conf.c @@ -468,8 +468,28 @@ static struct option long_opts[] = { {NULL, 0, NULL, 0} }; +static void conf_usage(const char *progname) +{ + + printf("Usage: %s [option] \n", progname); + printf("Option is one of the following:\n"); + printf(" --listnewconfig List new options\n"); + printf(" --oldaskconfig Start a new configuration using a line-oriented program\n"); + printf(" --oldconfig Update a configuration using a provided .config as base\n"); + printf(" --silentoldconfig Same as oldconfig, but quietly, additionally update deps\n"); + printf(" --oldnoconfig Same as silentoldconfig but set new symbols to no\n"); + printf(" --defconfig [arg] New config with default defined in the kconfig-filedefconfig\n"); + printf(" --savedefconfig Save the minimal current configuration to \n"); + printf(" --allnoconfig New config where all options are answered with no\n"); + printf(" --allyesconfig New config where all options are answered with yes\n"); + printf(" --allmodconfig New config where all options are answered with mod\n"); + printf(" --alldefconfig New config with all symbols set to default\n"); + printf(" --randconfig New config with random answer to all options\n"); +} + int main(int ac, char **av) { + const char *progname = av[0]; int opt; const char *name; struct stat tmpstat; @@ -503,10 +523,23 @@ int main(int ac, char **av) srand(seed); break; } + case oldaskconfig: + case oldconfig: + case allnoconfig: + case allyesconfig: + case allmodconfig: + case alldefconfig: + case listnewconfig: + case oldnoconfig: + break; + default: + conf_usage(progname); + exit(1); } } if (ac == optind) { printf(_("%s: Kconfig file missing\n"), av[0]); + conf_usage(progname); exit(1); } name = av[optind];