From owner-svn-src-head@FreeBSD.ORG Wed Aug 7 20:35:27 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 7BEAE374; Wed, 7 Aug 2013 20:35:27 +0000 (UTC) (envelope-from obrien@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 68AB6279B; Wed, 7 Aug 2013 20:35:27 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r77KZRa8084552; Wed, 7 Aug 2013 20:35:27 GMT (envelope-from obrien@svn.freebsd.org) Received: (from obrien@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r77KZRlJ084551; Wed, 7 Aug 2013 20:35:27 GMT (envelope-from obrien@svn.freebsd.org) Message-Id: <201308072035.r77KZRlJ084551@svn.freebsd.org> From: "David E. O'Brien" Date: Wed, 7 Aug 2013 20:35:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r254073 - head/tools/tools/sysdoc X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Aug 2013 20:35:27 -0000 Author: obrien Date: Wed Aug 7 20:35:26 2013 New Revision: 254073 URL: http://svnweb.freebsd.org/changeset/base/254073 Log: Improve the sysctl symbol extraction from the kernel so that it find more (all?) sysctl's. Previously some where missed, depending on how they were defined. Modified: head/tools/tools/sysdoc/sysdoc.sh Modified: head/tools/tools/sysdoc/sysdoc.sh ============================================================================== --- head/tools/tools/sysdoc/sysdoc.sh Wed Aug 7 19:56:35 2013 (r254072) +++ head/tools/tools/sysdoc/sysdoc.sh Wed Aug 7 20:35:26 2013 (r254073) @@ -88,7 +88,7 @@ EOF # tunables in our tunables.mdoc file and generate # the final 'inner circle' of our manual page. markup_create() { - sort < _names | \ + sort -u < _names | \ xargs -n 1 /bin/sh ./sysctl.sh \ > markup.file \ 2> tunables.TODO @@ -238,9 +238,13 @@ if [ -z "$LOCATION" ] ; && for x in `find $LOCATION -name '*.kld'` \ $LOCATION/kernel; \ do nm $x | \ - grep ' sysctl___' | uniq | \ - sed 's/sysctl___//g' | sed 's/_/./g' | \ - awk {'print $3'} > _names; + sed -n '/sysctl___/ { + 's/[\.a-z_]*sysctl___//g' + 's/_/./g' + p + }' | \ + awk {'print $3'} | \ + sort -u > _names; done; markup_create page_create