From owner-svn-src-all@freebsd.org Sat Oct 22 20:54:55 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 86EF8C1DC67; Sat, 22 Oct 2016 20:54:55 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 3AF87177; Sat, 22 Oct 2016 20:54:55 +0000 (UTC) (envelope-from bapt@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u9MKsswr014390; Sat, 22 Oct 2016 20:54:54 GMT (envelope-from bapt@FreeBSD.org) Received: (from bapt@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u9MKssRl014388; Sat, 22 Oct 2016 20:54:54 GMT (envelope-from bapt@FreeBSD.org) Message-Id: <201610222054.u9MKssRl014388@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: bapt set sender to bapt@FreeBSD.org using -f From: Baptiste Daroussin Date: Sat, 22 Oct 2016 20:54:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r307794 - stable/11/usr.bin/mkcsmapper X-SVN-Group: stable-11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 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: Sat, 22 Oct 2016 20:54:55 -0000 Author: bapt Date: Sat Oct 22 20:54:54 2016 New Revision: 307794 URL: https://svnweb.freebsd.org/changeset/base/307794 Log: MFC r302471, r302473: r302471: Add RCS Id. Sort options in SYNOPSIS. Fix macro usage. Fix Dd. Submitted by: wiz@NetBSD.org Obtained from: NetBSD r302473: Sync usage between program and man page. Increase column width. [1] Simplifay the usage() function Replace errx/strerror with errc Submitted by: wiz@NetBSD.org [1] Obtained from: NetBSD Modified: stable/11/usr.bin/mkcsmapper/mkcsmapper.1 stable/11/usr.bin/mkcsmapper/yacc.y Directory Properties: stable/11/ (props changed) Modified: stable/11/usr.bin/mkcsmapper/mkcsmapper.1 ============================================================================== --- stable/11/usr.bin/mkcsmapper/mkcsmapper.1 Sat Oct 22 20:52:58 2016 (r307793) +++ stable/11/usr.bin/mkcsmapper/mkcsmapper.1 Sat Oct 22 20:54:54 2016 (r307794) @@ -34,7 +34,7 @@ .\" .\" $FreeBSD$ .\" -.Dd Sep 6, 2009 +.Dd July 9, 2016 .Dt MKCSMAPPER 1 .Os .Sh NAME @@ -43,10 +43,10 @@ .Xr iconv 3 .Sh SYNOPSIS .Nm -.Op Fl mpd -.Fl o -.Ar outfile -.Ar infile +.Op Fl d +.Op Fl m | Fl p +.Op Fl o Ar outfile +.Op Ar infile .Sh DESCRIPTION The .Nm @@ -60,7 +60,7 @@ A pivot file, which the possible source pairs or the set of mappings to use for a compound encoding. .Pp The following options are available: -.Bl -tag -width 0123 +.Bl -tag -width XoXoutfileXX .It Fl d Turns on debug mode. .It Fl m @@ -82,7 +82,8 @@ Generate pivot data from .Sh HISTORY .Nm first appeared in -.Nx 2.0 , and made its appearance in +.Nx 2.0 , +and made its appearance in .Fx 9.0 . .Sh AUTHORS This manual page was written by Modified: stable/11/usr.bin/mkcsmapper/yacc.y ============================================================================== --- stable/11/usr.bin/mkcsmapper/yacc.y Sat Oct 22 20:52:58 2016 (r307793) +++ stable/11/usr.bin/mkcsmapper/yacc.y Sat Oct 22 20:54:54 2016 (r307794) @@ -1,5 +1,5 @@ /* $FreeBSD$ */ -/* $NetBSD: yacc.y,v 1.7 2006/09/09 14:35:17 tnozaki Exp $ */ +/* $NetBSD: yacc.y,v 1.11 2016/06/28 09:22:16 wiz Exp $ */ %{ /*- @@ -664,18 +664,15 @@ do_mkpv(FILE *in) if (ret && output) unlink(output); /* dump failure */ if (ret) - errx(EXIT_FAILURE, "%s\n", strerror(ret)); + errc(EXIT_FAILURE, ret, ""); } static void usage(void) { - warnx("usage: \n" - "\t%s [-d] [-o outfile] [infile]\n" - "\t%s -m [-d] [-o outfile] [infile]\n" - "\t%s -p [-d] [-o outfile] [infile]\n", - getprogname(), getprogname(), getprogname()); - exit(1); + fprintf(stderr, "Usage: %s [-d] [-m|-p] [-o outfile] [infile]\n", + getprogname()); + exit(EXIT_FAILURE); } int