From owner-svn-src-all@FreeBSD.ORG Wed Jan 19 21:19:23 2011 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BDE95106566B; Wed, 19 Jan 2011 21:19:23 +0000 (UTC) (envelope-from keramida@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A1B328FC15; Wed, 19 Jan 2011 21:19:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p0JLJNDg089415; Wed, 19 Jan 2011 21:19:23 GMT (envelope-from keramida@svn.freebsd.org) Received: (from keramida@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p0JLJN99089411; Wed, 19 Jan 2011 21:19:23 GMT (envelope-from keramida@svn.freebsd.org) Message-Id: <201101192119.p0JLJN99089411@svn.freebsd.org> From: Giorgos Keramidas Date: Wed, 19 Jan 2011 21:19:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217600 - stable/7/tools/regression/acct X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Jan 2011 21:19:23 -0000 Author: keramida (doc committer) Date: Wed Jan 19 21:19:23 2011 New Revision: 217600 URL: http://svn.freebsd.org/changeset/base/217600 Log: MFC r217064 - sort & fix includes, remove -include from CFLAGS of acct tests - Sort the includes of pack.c, moving sys/*.h files near the top. - Add a couple of missing #include lines, and remove the need for custom -include options in the CFLAGS of the test Makefile. - Remove the ad-hoc ’all’ target, but keep its ’regress’ bits for testing. - Convert the ad-hoc ’clean’ target to proper CLEANFILES stuff, so that the normal bsd.prog.mk machinery can clean up. - Use ‘make -V .OBJDIR’ to detect the place where ’pack’ lives, so that regress.t works both with and without ’make obj’. Modified: stable/7/tools/regression/acct/Makefile stable/7/tools/regression/acct/pack.c stable/7/tools/regression/acct/regress.t Directory Properties: stable/7/tools/regression/acct/ (props changed) Modified: stable/7/tools/regression/acct/Makefile ============================================================================== --- stable/7/tools/regression/acct/Makefile Wed Jan 19 21:09:39 2011 (r217599) +++ stable/7/tools/regression/acct/Makefile Wed Jan 19 21:19:23 2011 (r217600) @@ -1,22 +1,22 @@ # # $FreeBSD$ # -# "make" will compile what is needed and run the regression tests. +# "make" will compile the acct test programs # + PROG= pack +SRCS= pack.c NO_MAN= +CFLAGS+= -I${.OBJDIR} -all: regress - -pack: pack.c convert.c +pack.o: convert.c +CLEANFILES+= convert.c convert.c: ../../../sys/kern/kern_acct.c - sed -n '/FLOAT_CONVERSION_START/,/FLOAT_CONVERSION_END/p' $? >$@ + sed -n '/FLOAT_CONVERSION_START/,/FLOAT_CONVERSION_END/p' $? | \ + sed -e 's/log(/syslog(/' >$@ regress: pack regress.t - ./regress.t - -clean: - rm -f $(PROG) convert.c + sh ${.CURDIR}/regress.t .include Modified: stable/7/tools/regression/acct/pack.c ============================================================================== --- stable/7/tools/regression/acct/pack.c Wed Jan 19 21:09:39 2011 (r217599) +++ stable/7/tools/regression/acct/pack.c Wed Jan 19 21:19:23 2011 (r217600) @@ -25,15 +25,18 @@ #include __FBSDID("$FreeBSD$"); +#include + #include #include +#include #include #include +#include #include #include - -#include -#include +#include +#include #define KASSERT(val, msg) assert(val) Modified: stable/7/tools/regression/acct/regress.t ============================================================================== --- stable/7/tools/regression/acct/regress.t Wed Jan 19 21:09:39 2011 (r217599) +++ stable/7/tools/regression/acct/regress.t Wed Jan 19 21:19:23 2011 (r217600) @@ -3,7 +3,12 @@ # $FreeBSD$ # -DIR=`dirname $0` +if test -z "${DIR}" ; then + DIR=$( make -V .OBJDIR ) +fi +if test -z "${DIR}" ; then + DIR=$( dirname $0 ) +fi check() {