From c2e7350f1fbe992a60538056a90cd7842a782429 Mon Sep 17 00:00:00 2001 From: short <> Date: Fri, 19 Sep 2003 09:55:51 +0000 Subject: [PATCH] Written man pages. --- Makefile-head.am | 16 ++ autogen.pl | 1 + captive.spec.in | 8 + configure.in | 35 +++- debian/captive-install.files | 2 + debian/captive-lufs.files | 2 + debian/captive.files | 9 +- debian/rules | 1 + src/client/cmdline/Makefile.am | 7 + src/client/cmdline/captive-cmdline.pod.pl.in | 71 ++++++++ src/client/lufs/Makefile.am | 14 ++ src/client/lufs/lufs-captivefs.pod.pl.in | 58 +++++++ src/client/lufs/mount.captive.pod.pl.in | 107 ++++++++++++ src/client/sandbox-server/Makefile.am | 6 + .../captive-sandbox-server.pod.pl.in | 65 ++++++++ src/install/acquire/Makefile.am | 9 + .../acquire/captive-install-acquire.pod.pl.in | 162 ++++++++++++++++++ src/install/fstab/Makefile.am | 9 + src/install/fstab/captive-install-fstab.pod.pl.in | 93 +++++++++++ src/libcaptive/Makefile.am | 7 + src/libcaptive/captive.pod.pl.in | 48 ++++++ src/libcaptive/client/Makefile.am | 3 + src/libcaptive/client/options.pod.pl.in | 181 +++++++++++++++++++++ 23 files changed, 908 insertions(+), 6 deletions(-) create mode 100644 src/client/cmdline/captive-cmdline.pod.pl.in create mode 100644 src/client/lufs/lufs-captivefs.pod.pl.in create mode 100644 src/client/lufs/mount.captive.pod.pl.in create mode 100644 src/client/sandbox-server/captive-sandbox-server.pod.pl.in create mode 100644 src/install/acquire/captive-install-acquire.pod.pl.in create mode 100644 src/install/fstab/captive-install-fstab.pod.pl.in create mode 100644 src/libcaptive/captive.pod.pl.in create mode 100644 src/libcaptive/client/options.pod.pl.in diff --git a/Makefile-head.am b/Makefile-head.am index 0634c6e..ebcd82a 100644 --- a/Makefile-head.am +++ b/Makefile-head.am @@ -133,3 +133,19 @@ endif .include_test_false.c: @touch $@ +if HAVE_PERL +%.pod: %.pod.pl + $(PERL) $< >$@ + +endif +if HAVE_POD2MAN +%.1: %.pod + $(POD2MAN) --section=1 $< >$@ + +%.7: %.pod + $(POD2MAN) --section=7 $< >$@ + +%.8: %.pod + $(POD2MAN) --section=8 $< >$@ + +endif diff --git a/autogen.pl b/autogen.pl index f71372f..e2611b9 100755 --- a/autogen.pl +++ b/autogen.pl @@ -38,6 +38,7 @@ AutoGen->run( "clean"=>[qw( .include_test_false.c .include_test_all.stamp + *.pod.pl *.pod *.[0-9] ./ChangeLog.bak ./doc/*-pod.* ./doc/apiref/gtk-doc.make diff --git a/captive.spec.in b/captive.spec.in index b31918e..7458181 100644 --- a/captive.spec.in +++ b/captive.spec.in @@ -122,6 +122,7 @@ CFLAGS="-O2" --enable-sandbox-setuid=@PACKAGE@ \ --enable-sandbox-setgid=@PACKAGE@ \ --enable-sandbox-chroot=%{_var}/lib/@PACKAGE@ \ + --enable-man-pages \ --enable-sbin-mountdir=/sbin \ --enable-sbin-mount-fs=ntfs:fastfat:cdfs:ext2fsd \ --disable-gtk-doc @@ -144,10 +145,13 @@ rm -rf $RPM_BUILD_ROOT %defattr(-,root,root) %doc README NEWS AUTHORS TODO %{_libdir}/lib@PACKAGE@-@VERSION@.so +%attr(644,root,root) %{_mandir}/man?/@PACKAGE@.* %{_libdir}/gnome-vfs-2.0/modules/lib@PACKAGE@-gnomevfs-@VERSION@.so %{_libdir}/gnome-vfs-2.0/modules/lib@PACKAGE@-gnomevfs.so %{_bindir}/@PACKAGE@-cmdline +%attr(644,root,root) %{_mandir}/man?/@PACKAGE@-cmdline.* %attr(4755,root,root) %{_sbindir}/@PACKAGE@-sandbox-server +%attr(644,root,root) %{_mandir}/man?/@PACKAGE@-sandbox-server.* %config %{_sysconfdir}/gnome-vfs-2.0/modules/@PACKAGE@.conf %{_datadir}/locale/*/LC_MESSAGES/@PACKAGE@.mo %attr(755,root,root) %{_var}/lib/@PACKAGE@ @@ -157,8 +161,10 @@ rm -rf $RPM_BUILD_ROOT %defattr(-,root,root) %{_libdir}/liblufs-@PACKAGE@fs-@VERSION@.so %{_libdir}/liblufs-@PACKAGE@fs.so +%attr(644,root,root) %{_mandir}/man?/lufs-@PACKAGE@fs.* /sbin/mount.@PACKAGE@ /sbin/mount.@PACKAGE@-* +%attr(644,root,root) %{_mandir}/man?/mount.@PACKAGE@.* %post install %{_sbindir}/captive-install-fstab --add @@ -171,7 +177,9 @@ rm -rf $RPM_BUILD_ROOT %defattr(-,root,root) %config %{_sysconfdir}/w32-mod-id.captivemodid.xml %{_sbindir}/captive-install-fstab +%attr(644,root,root) %{_mandir}/man?/captive-install-fstab.* %{_sbindir}/captive-install-acquire +%attr(644,root,root) %{_mandir}/man?/captive-install-acquire.* # %files devel # %defattr(-,root,root) diff --git a/configure.in b/configure.in index c06a44f..f3ffb91 100644 --- a/configure.in +++ b/configure.in @@ -64,6 +64,8 @@ dnl Some Makefiles use additional tests etc. AM_CONDITIONAL(MAINTAINER_MODE,[test "$USE_MAINTAINER_MODE" = "yes"]) +AC_ARG_ENABLE(man-pages, + [ --enable-man-pages=no/yes/auto pod2man(1) required for man pages (def.=yes)],,enable_man_pages=yes) AC_ARG_ENABLE(sbin-mountdir, [ --enable-sbin-mountdir=DIR mount(8) 'mount.captive' directory (def.=/sbin)],, [ enable_sbin_mountdir="/sbin" ]) @@ -107,7 +109,6 @@ AC_DEFINE_UNQUOTED(CAPTIVE_SANDBOX_CHROOT,"$CAPTIVE_SANDBOX_CHROOT", [root-owned directory for captive-sandbox-server]) AC_SUBST(CAPTIVE_SANDBOX_CHROOT) - dnl Permit 'if NEVER' for Makefile.am-s; symbol 'FALSE' forbidden by automake AM_CONDITIONAL(NEVER,false) @@ -118,6 +119,26 @@ if test '!' -f ./src/libcaptive/ke/exports.c -a -z "$PERL";then fi AM_CONDITIONAL(HAVE_PERL,test -n "$PERL") +POD2MAN= +AC_PATH_PROGS(POD2MAN,pod2man) +AM_CONDITIONAL(HAVE_POD2MAN,[ test -n "$POD2MAN" ]) +if test x$enable_man_pages = xyes;then + if test -z "$POD2MAN";then + AC_MSG_ERROR([captive requires pod2man(1) for man pages; try --disable-man-pages.]) + fi + if test -z "$PERL";then + AC_MSG_ERROR([captive requires perl(1) for man pages; try --disable-man-pages.]) + fi +elif test x$enable_man_pages != xno;then + if test -z "$POD2MAN";then + AC_MSG_WARN([captive requires pod2man(1) for man pages by --enable-man-pages; mans will not be installed.]) + fi + if test -z "$PERL";then + AC_MSG_WARN([captive requires perl(1) for man pages by --enable-man-pages; mans will not be installed.]) + fi +fi +AM_CONDITIONAL(ENABLE_MAN_PAGES,[ test x$enable_man_pages != xno -a -n "$POD2MAN" -a -n "$PERL" ]) + dnl Separate 'acconfig.h' is no longer recommended by autoconf AH_TOP([ #ifndef _CAPTIVE_CONFIG_H @@ -253,7 +274,7 @@ if $have_libxml_buffering;then else if test x$enable_bug_replay = xyes;then AC_MSG_ERROR([captive require libxml2 at least 2.5.9 for --enable-bug-replay feature.]) - elif test x$enable_bug_replay != no;then + elif test x$enable_bug_replay != xno;then AC_MSG_WARN([libxml2 at least 2.5.9 required --enable-bug-replay feature; disabled now.]) fi fi @@ -332,8 +353,16 @@ dnl "Makefile" output files MUST have pathnames incl./excl. "./" prefix as speci dnl FIXME: Why the rule above was written here? AC_OUTPUT([ captive.spec -./src/client/gnomevfs/captive.conf +./src/libcaptive/captive.pod.pl +./src/libcaptive/client/options.pod.pl +./src/client/cmdline/captive-cmdline.pod.pl +./src/client/lufs/lufs-captivefs.pod.pl +./src/client/lufs/mount.captive.pod.pl ./src/client/lufs/mount.captive +./src/client/sandbox-server/captive-sandbox-server.pod.pl +./src/install/fstab/captive-install-fstab.pod.pl +./src/install/acquire/captive-install-acquire.pod.pl +./src/client/gnomevfs/captive.conf ./po/Makefile.in ./macros/glade-w.sh Makefile diff --git a/debian/captive-install.files b/debian/captive-install.files index b64a9e3..45e333f 100644 --- a/debian/captive-install.files +++ b/debian/captive-install.files @@ -1,3 +1,5 @@ /etc/w32-mod-id.captivemodid.xml /usr/sbin/captive-install-fstab +/usr/man/man?/captive-install-fstab.* /usr/sbin/captive-install-acquire +/usr/man/man?/captive-install-acquire.* diff --git a/debian/captive-lufs.files b/debian/captive-lufs.files index 31b73b4..e2e3b01 100644 --- a/debian/captive-lufs.files +++ b/debian/captive-lufs.files @@ -1,3 +1,5 @@ /usr/lib/liblufs-captivefs*.so +/usr/man/man?/lufs-captivefs.* /sbin/mount.captive /sbin/mount.captive-* +/usr/man/man?/mount.captive.* diff --git a/debian/captive.files b/debian/captive.files index 1a86cd0..dd9aaf6 100644 --- a/debian/captive.files +++ b/debian/captive.files @@ -1,7 +1,10 @@ -/etc/gnome-vfs-2.0/modules/captive.conf -/usr/bin/captive-cmdline -/usr/lib/gnome-vfs-2.0/modules/libcaptive-gnomevfs*.so /usr/lib/libcaptive*.so +/usr/man/man?/captive.* +/usr/lib/gnome-vfs-2.0/modules/libcaptive-gnomevfs*.so +/usr/bin/captive-cmdline +/usr/man/man?/captive-cmdline.* /usr/sbin/captive-sandbox-server +/usr/man/man?/captive-sandbox-server.* +/etc/gnome-vfs-2.0/modules/captive.conf /usr/share/locale/*/LC_MESSAGES/captive.mo /var/lib/captive/*.sys diff --git a/debian/rules b/debian/rules index 2a31557..5906ede 100755 --- a/debian/rules +++ b/debian/rules @@ -49,6 +49,7 @@ config.status: configure --enable-sandbox-setuid=captive \ --enable-sandbox-setgid=captive \ --enable-sandbox-chroot=/var/lib/captive \ + --enable-man-pages \ --enable-sbin-mountdir=/sbin \ --enable-sbin-mount-fs=ntfs:fastfat:cdfs:ext2fsd \ --disable-gtk-doc diff --git a/src/client/cmdline/Makefile.am b/src/client/cmdline/Makefile.am index 5712f68..e246f67 100644 --- a/src/client/cmdline/Makefile.am +++ b/src/client/cmdline/Makefile.am @@ -57,3 +57,10 @@ captive_cmdline_CFLAGS= $(GNOME_VFS_CFLAGS) captive_cmdline_LDADD =$(captive_library) $(GNOME_VFS_LIBS) $(READLINE_LIBS) $(INTLLIBS) captive_cmdline_LDFLAGS=$(READLINE_LDFLAGS) bin_PROGRAMS+=captive-cmdline + +EXTRA_DIST+=captive-cmdline.pod.pl.in +CLEANFILES+=captive-cmdline.pod captive-cmdline.1 +if ENABLE_MAN_PAGES +captive_cmdline_man_cond=captive-cmdline.1 +endif +man_MANS=$(captive_cmdline_man_cond) diff --git a/src/client/cmdline/captive-cmdline.pod.pl.in b/src/client/cmdline/captive-cmdline.pod.pl.in new file mode 100644 index 0000000..a1de663 --- /dev/null +++ b/src/client/cmdline/captive-cmdline.pod.pl.in @@ -0,0 +1,71 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for captive-cmdline(1) man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +my $sbindir='@sbindir@'; +$sbindir=~s#\$\Q{exec_prefix}\E#'@exec_prefix@';#ge; +$sbindir=~s#\$\Q{prefix}\E#'@prefix@';#ge; +$sbindir="/usr/sbin" if $sbindir=~/^@/; + +print <<'POD_EOF'; +=head1 NAME + +@PACKAGE@-cmdline - Command-line client for B<@PACKAGE@>(7) NTFS disk access + + +=head1 SYNOPSIS + +=for man +\fB@PACKAGE@-cmdline\fP \fB--load-module\fP=\fB/tmp/ntoskrnl.exe\fP +.br + \fB--filesystem\fP=\fB/tmp/ntfs.sys\fP +.br +POD_EOF +print "\t\t".'[\fB--sandbox-server\fP=\fB'.$sbindir.'/@PACKAGE@-sandbox-server\fP]'."\n"; +print <<'POD_EOF'; + [\fB--bug-pathname\fP=\fB/tmp/captive-bug-%FT%T.captivebug.xml.gz\fP] + [\fB--disk\fP|\fB--cdrom\fP] [\fB--ro\fP|\fB--blind\fP|\fB--rw\fP] {\fBimage-file\fP|\fBdevice\fP} + + +=head1 DESCRIPTION + +Simple B(1)-like client to access disks by Microsoft Windows drivers. +Use if B(7) not available; also useful during debugging. + + +POD_EOF +require "../../libcaptive/client/options.pod.pl"; +print <<'POD_EOF'; +=head1 SEE ALSO + +B<@PACKAGE@>(7), B(7) + + +=head1 AUTHOR + +Jan Kratochvil >, + I +POD_EOF +1; diff --git a/src/client/lufs/Makefile.am b/src/client/lufs/Makefile.am index ee8e3c4..d8be577 100644 --- a/src/client/lufs/Makefile.am +++ b/src/client/lufs/Makefile.am @@ -54,3 +54,17 @@ install-exec-hook: endif endif enable_sbin_mount_SCRIPTS=$(sbin_mount_captive_cond) + +EXTRA_DIST+=lufs-captivefs.pod.pl.in +CLEANFILES+=lufs-captivefs.pod lufs-captivefs.1 +EXTRA_DIST+=mount.captive.pod.pl.in +CLEANFILES+=mount.captive.pod mount.captive.1 +if ENABLE_MAN_PAGES +if ENABLE_LUFS +lufs_captivefs_man_cond=lufs-captivefs.7 +if ENABLE_SBIN_MOUNT +mount_captive_man_cond=mount.captive.8 +endif +endif +endif +man_MANS=$(lufs_captivefs_man_cond) $(mount_captive_man_cond) diff --git a/src/client/lufs/lufs-captivefs.pod.pl.in b/src/client/lufs/lufs-captivefs.pod.pl.in new file mode 100644 index 0000000..bef24e0 --- /dev/null +++ b/src/client/lufs/lufs-captivefs.pod.pl.in @@ -0,0 +1,58 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for lufs-captivefs(7) man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +print <<'POD_EOF'; +=head1 NAME + +lufs-@PACKAGE@fs - Linux User File System module for NTFS as filesystem + + +=head1 DESCRIPTION + +B(7) module for Linux User File System (LUFS) enables +B system to access NTFS drives by Microsoft Windows drivers in +the most common way of kernel-level filesystem implementation. + +{B<-c CHAN>|B<--channels>=B} option of B(1) is respected +although the final filesystem operations are always processed in single-channel +mode. Do not set B to B<1> as it would invoke errors by LUFS kernel +driver. + + +POD_EOF +require "../../libcaptive/client/options.pod.pl"; +print <<'POD_EOF'; +=head1 SEE ALSO + +B(8), B(1), B<@PACKAGE@>(7) + + +=head1 AUTHOR + +Jan Kratochvil >, + I +POD_EOF +1; diff --git a/src/client/lufs/mount.captive.pod.pl.in b/src/client/lufs/mount.captive.pod.pl.in new file mode 100644 index 0000000..02e01db --- /dev/null +++ b/src/client/lufs/mount.captive.pod.pl.in @@ -0,0 +1,107 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for captive(7) man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +print <<'POD_EOF'; +=head1 NAME + +mount.@PACKAGE@ - B(8) interface for NTFS disk access + + +=head1 SYNOPSIS + +B {B|B} B +[B<-n>] [B<-v>] [B<-o> B] + +B B<-t> B<@PACKAGE@-ntfs> +[B<-n>] [B<-v>] [B<-o> B] +{B|B} B + + +=head1 DESCRIPTION + +B(8) provides B(8) interface to B(7) +by calling B(1) with appropriate arguments. You should never call +this command directly - use B(8) instead. + +B(8) (B<@PACKAGE@> filesystem type) is never used - this command +is provided just as a base mount(8) interface to B<@PACKAGE@>(7). You must always +use @PACKAGE@-B filesystem type such as B<@PACKAGE@-ntfs>. Other supported +filesystem types are: +POD_EOF +print join ", ",map("B<$_>",(split /:/,'@enable_sbin_mount_fs@')); +print <<'POD_EOF'; + + +=head1 OPTIONS + +=over + +=item {B|B} + +Pathname such as B or B. You should refer to the +partition name, not the whole device (B is forbidden). +B may correspond to B +on your system. + + +=item B + +Existing empty target directory where {B|B} will be +mounted. + + +=item B<-n> + +Do not modify B. This option is currently not supported (ignored), +B is modified notwithstanding. + + +=item B<-v> + +Enable verbose mode. Command B(1) being called is shown. + + +=item B<-o> B + +Custom options passed to B<@PACKAGE@>(7). See its manpage for details. Options +double-dashes (B<-->) can be omitted for B(7) or +B(8). + + +=back + + +=head1 SEE ALSO + +B(7), B(1) + + +=head1 AUTHOR + +Jan Kratochvil >, + I +POD_EOF +1; diff --git a/src/client/sandbox-server/Makefile.am b/src/client/sandbox-server/Makefile.am index 3a286c1..0d6500a 100644 --- a/src/client/sandbox-server/Makefile.am +++ b/src/client/sandbox-server/Makefile.am @@ -28,3 +28,9 @@ EXTRA_DIST+=.gdbinit install-data-hook: $(mkinstalldirs) $(DESTDIR)$(CAPTIVE_SANDBOX_CHROOT) +EXTRA_DIST+=captive-sandbox-server.pod.pl.in +CLEANFILES+=captive-sandbox-server.pod captive-sandbox-server.1 +if ENABLE_MAN_PAGES +captive_sandbox_server_man_cond=captive-sandbox-server.1 +endif +man_MANS=$(captive_sandbox_server_man_cond) diff --git a/src/client/sandbox-server/captive-sandbox-server.pod.pl.in b/src/client/sandbox-server/captive-sandbox-server.pod.pl.in new file mode 100644 index 0000000..d0d8012 --- /dev/null +++ b/src/client/sandbox-server/captive-sandbox-server.pod.pl.in @@ -0,0 +1,65 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for captive-cmdline(1) man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +print <<'POD_EOF'; +=head1 NAME + +@PACKAGE@-sandbox-server - Security+safety wrapper for NTFS disk access + + +=head1 SYNOPSIS + +B<@PACKAGE@-sandbox-server> + + +=head1 DESCRIPTION + +Program implementing separation of emulated I kernel +environment from the rest of I system. Your system gets protected by +B(2), B(2), B(2) and B(2) UNIX security +features against malicious Microsoft Windows drivers. + +Use this program as argument of B<--sandbox-server> option of B<@PACKAGE@>(7). +Do not use this option/program during B<@PACKAGE@>(7) debugging. + + +=head1 OPTIONS + +No options are permitted for this command - it will display its I +connection properties on its standard output. + + +=head1 SEE ALSO + +B<@PACKAGE@>(7), B<@PACKAGE@-cmdline>(1), B(7) + + +=head1 AUTHOR + +Jan Kratochvil >, + I +POD_EOF +1; diff --git a/src/install/acquire/Makefile.am b/src/install/acquire/Makefile.am index 5132674..fe7e81d 100644 --- a/src/install/acquire/Makefile.am +++ b/src/install/acquire/Makefile.am @@ -99,3 +99,12 @@ if ENABLE_INSTALL_PKG captive_install_acquire_cond=captive-install-acquire endif sbin_PROGRAMS+=$(captive_install_acquire_cond) + +EXTRA_DIST+=captive-install-acquire.pod.pl.in +CLEANFILES+=captive-install-acquire.pod captive-install-acquire.1 +if ENABLE_MAN_PAGES +if ENABLE_INSTALL_PKG +captive_install_acquire_man_cond=captive-install-acquire.1 +endif +endif +man_MANS=$(captive_install_acquire_man_cond) diff --git a/src/install/acquire/captive-install-acquire.pod.pl.in b/src/install/acquire/captive-install-acquire.pod.pl.in new file mode 100644 index 0000000..2e2e38e --- /dev/null +++ b/src/install/acquire/captive-install-acquire.pod.pl.in @@ -0,0 +1,162 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for captive-install-acquire(1) man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +my $vardir='@localstatedir@/lib/@PACKAGE@'; +$vardir=~s#\$\Q{prefix}\E#'@prefix@';#ge; +$vardir="/var/lib/@PACKAGE@" if $vardir=~/^@/; +my $sysconfdir='@sysconfdir@'; +$sysconfdir=~s#\$\Q{prefix}\E#'@prefix@';#ge; +$sysconfdir="/etc" if $sysconfdir=~/^@/; + +print <<'POD_EOF'; +=head1 NAME + +@PACKAGE@-install-acquire - Find MS Windows XP driver files for B + + +=head1 SYNOPSIS + +=for man +\fB@PACKAGE@-install-acquire\fP [\fB--text] +[\fB-v\fP|\fB--verbose\fP] [\fB-n\fP|\fB--dry\fP] +.br + [\fB--modid-path\fP=\fBpath\fP] [\fB--scan-disks\fP] [\fB--scan-disks-quick\fP] +.br + [\fB--scan-path\fP=\fBpath/URI\fP] [\fB--microsoft-com\fP] + + +=head1 DESCRIPTION + +Program acquires the needed I driver files. Multiple +methods of getting the driver files are supported. All the driver files are +stored to the directory +POD_EOF +print "B<$vardir/>\n"; +print <<'POD_EOF'; +where they are +expected by B(8). + + +=head1 OPTIONS + +Program will run interactively if no action options (B<--scan-disks>, +B<--scan-disks-quick>, B<--scan-path> or B<--microsoft-com>) are specified. +Otherwise the requested action(s) is proceeded in silent batch mode. + +=over + +=item B<--text> + +Disable I user interface even if I is available. +You must specify this option as the first one. This option has effect only for +interactive mode (no action options specified). + + +=item B<-v>|B<--verbose> + +Display additional information during disks scanning. + + +=item B<-n>|B<--dry> + +Perform all the operations but do not modify anything (no drivers are +stored to +POD_EOF +print "B<$vardir/>\n"; +print <<'POD_EOF'; +directory). + + +=item B<--modid-path>=B + +Path to B<.captivemodid.xml> database (default: +POD_EOF +print "B<$sysconfdir/w32-mod-id.captivemodid.xml>"; +print <<'POD_EOF'; +). This file contains +identifications (B(1)) of known compatible I +driver files. B<@PACKAGE@-install-acquire>(1) will ignore any files not +identified by this file although you may try to copy them to +POD_EOF +print "B<$vardir/>\n"; +print <<'POD_EOF'; +manually for B<@PACKAGE@>(7) clients. + + +=item B<--scan-disks> + +Scan all files on any local hard drive (mounted or unmounted) B or +(mounted) B partitions. This scanning includes I (B<.cab>) +archives. This scanning can last for very long time. + + +=item B<--scan-disks-quick> + +Reduced version of B<--scan-disks>. Only B subdirectory in +the root of any local hard drive (mounted or unmounted) B or (mounted) +B partition is investigated. This scan should find existing driver files +in already existing I installations. + + +=item B<--scan-path>=B + +Scan the specified B for device driver files. You may use either +filename (B), directory (B), B +disk file/directory (B) or remote +I filename (B). Remote I directory +(such as B) is not supported. + +Possibly specified directory is always scanned recursively. + + +=item B<--microsoft-com> + +You can download the best available version of needed drivers from +I. They can be found in I (URL +B) + +Legal: In some countries you need to have valid I license +to use it. + +Program will need to download approx 29MB of data (the cabinet file is 151MB; +1MB=1e6B here). + + +=back + + +=head1 SEE ALSO + +B<@PACKAGE@-install-fstab>(1), B<@PACKAGE@>(7), B(7) + + +=head1 AUTHOR + +Jan Kratochvil >, + I +POD_EOF +1; diff --git a/src/install/fstab/Makefile.am b/src/install/fstab/Makefile.am index 5b6b711..be07c68 100644 --- a/src/install/fstab/Makefile.am +++ b/src/install/fstab/Makefile.am @@ -27,3 +27,12 @@ if ENABLE_INSTALL_PKG captive_install_fstab_cond=captive-install-fstab endif sbin_PROGRAMS+=$(captive_install_fstab_cond) + +EXTRA_DIST+=captive-install-fstab.pod.pl.in +CLEANFILES+=captive-install-fstab.pod captive-install-fstab.1 +if ENABLE_MAN_PAGES +if ENABLE_INSTALL_PKG +captive_install_fstab_man_cond=captive-install-fstab.1 +endif +endif +man_MANS=$(captive_install_fstab_man_cond) diff --git a/src/install/fstab/captive-install-fstab.pod.pl.in b/src/install/fstab/captive-install-fstab.pod.pl.in new file mode 100644 index 0000000..1057f13 --- /dev/null +++ b/src/install/fstab/captive-install-fstab.pod.pl.in @@ -0,0 +1,93 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for captive-install-fstab(1) man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +print <<'POD_EOF'; +=head1 NAME + +@PACKAGE@-install-fstab - Manage B<@PACKAGE@-ntfs> B entries + + +=head1 SYNOPSIS + +=for man +\fB@PACKAGE@-install-fstab\fP [\fB-v\fP|\fB--verbose\fP] [\fB-n\fP|\fB--dry\fP] +{\fB--add\fP|\fB--remove\fP} + + +=head1 DESCRIPTION + +Program will scan your local disk drive partitions (from B) +and it will add/remove appropriate file-system type B entries +in B. + +Destination directory is chosen automatically as BLABEL_NAME +where B is the label used for the B partition. Directory +B may be used if no volume label is set. Different (numbered) +directory name is used if multiple disks have the same volume label set. + + +=head1 OPTIONS + +=over + +=item B<-v>|B<--verbose> + +Display additional information during disks scanning. + + +=item B<-n>|B<--dry> + +Perform all the operations but do not modify anything (file B). +You will probably use this option together with [B<-v>|B<--verbose>]. + + +=item B<--add> + +Add all the found B disk drive partitions to B. +Any previous B entries will be deleted as described in +B<--remove> option. + + +=item B<--remove> + +Remove all lines of filesystem type B<@PACKAGE@-ntfs> and device name in +B directory. + + +=back + + +=head1 SEE ALSO + +B<@PACKAGE@-install-acquire>(1), B<@PACKAGE@>(7), B(7) + + +=head1 AUTHOR + +Jan Kratochvil >, + I +POD_EOF +1; diff --git a/src/libcaptive/Makefile.am b/src/libcaptive/Makefile.am index d9356c4..cfb77d8 100644 --- a/src/libcaptive/Makefile.am +++ b/src/libcaptive/Makefile.am @@ -48,3 +48,10 @@ libcaptive_la_LIBADD= \ client/libclient.la libcaptive_la_LDFLAGS=-release $(VERSION) libcaptive_la_SOURCES= + +EXTRA_DIST+=captive.pod.pl.in +CLEANFILES+=captive.pod captive.7 +if ENABLE_MAN_PAGES +captive_man_cond=captive.7 +endif +man_MANS=$(captive_man_cond) diff --git a/src/libcaptive/captive.pod.pl.in b/src/libcaptive/captive.pod.pl.in new file mode 100644 index 0000000..abfe6ce --- /dev/null +++ b/src/libcaptive/captive.pod.pl.in @@ -0,0 +1,48 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for captive(7) man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +print <<'POD_EOF'; +=head1 NAME + +@PACKAGE@ - Microsoft Windows NT kernel emulation for NTFS disk access + + +=head1 DESCRIPTION + +B<@PACKAGE@>(7) library allows applications running under the B +operating system to access B drives. File system driver compatibility +with B, B and B is also provided. + + +POD_EOF +require "./client/options.pod.pl"; +print <<'POD_EOF'; +=head1 AUTHOR + +Jan Kratochvil >, + I +POD_EOF +1; diff --git a/src/libcaptive/client/Makefile.am b/src/libcaptive/client/Makefile.am index 256be0c..4616f22 100644 --- a/src/libcaptive/client/Makefile.am +++ b/src/libcaptive/client/Makefile.am @@ -76,3 +76,6 @@ CLEANFILES+= \ # FIXME: Prevent: libtool: link: `libclient_la-parent-connector.lo' is not a valid libtool object # dependency: libclient_la-parent-connector.lo: marshallers.h + +EXTRA_DIST +=options.pod.pl.in +noinst_DATA+=options.pod.pl diff --git a/src/libcaptive/client/options.pod.pl.in b/src/libcaptive/client/options.pod.pl.in new file mode 100644 index 0000000..a7e62bb --- /dev/null +++ b/src/libcaptive/client/options.pod.pl.in @@ -0,0 +1,181 @@ +#! /usr/bin/perl +# +# $Id$ +# perlpod(1) source for captive(7) options part of man page +# Copyright (C) 2003 Jan Kratochvil +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; exactly version 2 of June 1991 is required +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +use vars qw($VERSION); +$VERSION=do { my @r=(q$Revision$=~/\d+/g); sprintf "%d.".("%03d"x$#r),@r; }; +use strict; +use warnings; + + +my $vardir='@localstatedir@/lib/@PACKAGE@'; +$vardir=~s#\$\Q{prefix}\E#'@prefix@';#ge; +$vardir="/var/lib/@PACKAGE@" if $vardir=~/^@/; +my $sbindir='@sbindir@'; +$sbindir=~s#\$\Q{exec_prefix}\E#'@exec_prefix@';#ge; +$sbindir=~s#\$\Q{prefix}\E#'@prefix@';#ge; +$sbindir="/usr/sbin" if $sbindir=~/^@/; + +print <<'POD_EOF'; +=head1 OPTIONS + +All programs using B<@PACKAGE@>(7) library share the common set of configuration +options: + +=over + +=item B<--filesystem>=B + +Pathname to B<.sys> or B<.so> filesystem module file. You will use exactly +once this option. Possible choices are +POD_EOF +print "B<$vardir/ntfs.sys>\n"; +print <<'POD_EOF'; +etc. + + +=item B<--load-module>=B + +Pathname to any W32 module to load w/o initialization. Multiple modules can be +loaded although in common case you will use just +POD_EOF +print "B<$vardir/ntoskrnl.exe>\n"; +print <<'POD_EOF'; +here. + + +=item B<--ro> + +Read/write mode: Any write access will be forbidden. You should set this mode +for B (I filesystem). This option is mutually exclusive with +B<--blind> and B<--rw>. + + +=item B<--blind> + +Read/write mode: All writes are just simulated in memory (default). Microsoft +Windows filesystem driver will see no difference between B<--blind> and B<--rw> +although the UNIX image file/device will be open read/only as for B<--ro>. +All the changes get 'written' as long as B(7) program runs - all the +changes will be lost afterwards. This mode is the most suitable for debugging. +This option is mutually exclusive with B<--ro> and B<--rw>. + + +=item B<--rw> + +Read/write mode: Write directly to the image file/device. Standard read/write +disk mode. You should use B<--sandbox-server> option in this case to have the +disk protected against Microsoft Windows filesystem driver crashes. Modified +disk image blocks are in B<--sandbox-server> B<--rw> mode buffered in the +memory and they get reflected to the disk only after successful completion +of all filesystem operations including filesystem unmount. +This option is mutually exclusive with B<--ro> and B<--blind>. + + +=item B<--cdrom> + +Media type: CD-ROM. You must set this media type for B. +Virtual Microsoft Windows block device driver used by Captive maps to +B<\Device\CdRom0>. This option is mutually exclusive with B<--disk>. + + +=item B<--disk> + +Media type: Disk (default). You must set this media type for all the Microsoft +Windows filesystem drivers except B. Virtual Microsoft Windows block +device driver used by Captive maps to B<\Device\CaptiveHarddisk0>. +This option is mutually exclusive with B<--cdrom>. + + +=item B<--debug-messages> + +Turn on debugging messages. Be prepared for substation debug output. +Use of B<--syslog> feature is not recommended in this case. + + +=item B<--sandbox-server>=B + +Pathname to +POD_EOF +print "B<$sbindir/captive-sandbox-server>\n"; +print <<'POD_EOF'; +program, turns on sandboxing. +You should always use this option in conjunction with B<--rw>, see it for +details. Although this program is I and it drops it privileges +to B<@CAPTIVE_SANDBOX_SETUID@> user. Your system gets protected by +B(2), B(2), B(2) and B(2) UNIX security +features against malicious Microsoft Windows drivers. You should never use this +option during debugging. + + +=item B<--sandbox-server-ior>=B + +Specify I of +POD_EOF +print "B<$sbindir/captive-sandbox-server>\n"; +print <<'POD_EOF'; +program, turns on +sandboxing. Specified I should be the string starting by "B" +text. This option is useful only for debugging. No sandbox restarting is +possible in this case. + + +=item B<--no-sandbox> + +Turn off sandboxing feature (default). No +POD_EOF +print "B<$sbindir/captive-sandbox-server>\n"; +print <<'POD_EOF'; +is run. Microsoft Windows filesystem driver is run in native UNIX environment +without any I separation. This option is recommended only for debugging. +It is dangerous to use B<--rw> together, see its description for the details. + + +=item B<--bug-pathname>=B + +Pathname to B(3) for B<.captivebug.xml.gz> bugreports. Every crash of +sandbox child gets bugreported to the specified file. You should attempt to +minimize the number of operations from the mount operation till the expected +crash to minimize the snapshot file size. B<--sandbox-server> option is +required for B<--bug-pathname>. + +B + + +=item B<--syslog> + +Messages sent to B(3) instead of I. This option gets handy +for B(8) operation as the messages would be lost otherway. +Watch our for possible "B" messages where +some written filesystem data got lost in the case of Microsoft Windows +filesystem driver crash. + + +=item B<--syslog-facility>=B + +B(3) facility for B<--syslog>. See B section of +B(3) man page for details. Lowercased values such as B or +B are supported. + + +=back + + +POD_EOF +1; -- 1.8.3.1