From mboxrd@z Thu Jan 1 00:00:00 1970 From: Goffredo Baroncelli Subject: [PATCH 2/7][V2] btrfs-progs: Update the makefile for generating the man page. Date: Tue, 08 Nov 2011 23:12:09 +0100 Message-ID: <1484654.ljxEAWTeQE@venice> Reply-To: Goffredo Baroncelli Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="nextPart1620264.r3aLitudVo" To: linux-btrfs@vger.kernel.org Return-path: List-ID: --nextPart1620264.r3aLitudVo Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" The makefile is update in order to generate the man/btrfs.8.in by the helpextract tool on the basis of the sources comments. The old man page is renamed as btrfs.8.in.old. Signed off by: Goffredo Baroncelli --- Makefile | 11 ++- man/btrfs.8.in | 322 ---------------------------------------------------- man/btrfs.8.in.old | 322 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 332 insertions(+), 323 deletions(-) delete mode 100644 man/btrfs.8.in create mode 100644 man/btrfs.8.in.old diff --git a/Makefile b/Makefile index 96e2002..413f5d5 100644 --- a/Makefile +++ b/Makefile @@ -19,6 +19,8 @@ RESTORE_LIBS=-lz progs = btrfsctl mkfs.btrfs btrfs-debug-tree btrfs-show btrfs-vol btrfsck \ btrfs btrfs-map-logical restore find-root calc-size btrfs-corrupt-block +btrfs_man_page_source = btrfs.c btrfs_cmds.c scrub.c + # make C=1 to enable sparse ifdef C check = sparse $(CHECKFLAGS) @@ -97,13 +99,20 @@ convert: $(objects) convert.o ioctl-test: $(objects) ioctl-test.o $(CC) $(CFLAGS) -o ioctl-test $(objects) ioctl-test.o $(LDFLAGS) $(LIBS) -manpages: +helpextract: helpextract.o + $(CC) $(CFLAGS) -o $@ helpextract.o + +man/btrfs.8.in: helpextract $(btrfs_man_page_source) + ./helpextract --man-page $(btrfs_man_page_source) >$@ + +manpages: man/btrfs.8.in cd man; make install-man: cd man; make install clean : + rm -f man/btrfs.8.in rm -f $(progs) cscope.out *.o .*.d btrfs-convert btrfs-image btrfs-select- super \ btrfs-zero-log btrfstune dir-test ioctl-test quick-test version.h cd man; make clean diff --git a/man/btrfs.8.in b/man/btrfs.8.in deleted file mode 100644 index be478e0..0000000 --- a/man/btrfs.8.in +++ /dev/null @@ -1,322 +0,0 @@ -.TH BTRFS 8 "" "btrfs" "btrfs" -.\" -.\" Man page written by Goffredo Baroncelli (Feb 2010) -.\" -.SH NAME -btrfs \- control a btrfs filesystem -.SH SYNOPSIS -\fBbtrfs\fP \fBsubvolume snapshot\fP\fI [-r] [/]\fP -.PP -\fBbtrfs\fP \fBsubvolume delete\fP\fI \fP -.PP -\fBbtrfs\fP \fBsubvolume create\fP\fI [/]\fP -.PP -\fBbtrfs\fP \fBsubvolume list\fP\fI [-p] \fP -.PP -\fBbtrfs\fP \fBsubvolume set-default\fP\fI \fP -.PP -\fBbtrfs\fP \fBsubvolume get-default\fP\fI \fP -.PP -\fBbtrfs\fP \fBfilesystem sync\fP\fI \fP -.PP -\fBbtrfs\fP \fBfilesystem resize\fP\fI [+/\-][gkm]|max \fP -.PP -\fBbtrfs\fP \fBfilesystem label\fP\fI [newlabel]\fP -.PP -\fBbtrfs\fP \fBfilesystem defrag\fP\fI [options] | [| ...]\fP -.PP -\fBbtrfs\fP \fBsubvolume find-new\fP\fI \fP -.PP -\fBbtrfs\fP \fBfilesystem balance\fP\fI \fP -.PP -\fBbtrfs\fP \fBfilesystem defragment\fP\fI | [|...]\fP -.PP -\fBbtrfs\fP \fBdevice scan\fP\fI [--all-devices| [...]]\fP -.PP -\fBbtrfs\fP \fBdevice show\fP\fI [--all-devices||