From: short <> Date: Wed, 19 Nov 2003 12:34:09 +0000 (+0000) Subject: Use lufsd(1) instead of lufsmount(1) - reduce static build package version size. X-Git-Tag: captive-1_1~15 X-Git-Url: https://git.jankratochvil.net/?a=commitdiff_plain;h=1ca2a035b4f19c173941930a8dd678afe0b11cc3;p=captive.git Use lufsd(1) instead of lufsmount(1) - reduce static build package version size. --- diff --git a/configure.in b/configure.in index 60e1e21..f4647b8 100644 --- a/configure.in +++ b/configure.in @@ -311,7 +311,10 @@ AC_SUBST(OPENSSL_LIBS) # AC_ARG_ENABLE(lufs,[--enable-lufs=[no/yes/auto]],,enable_lufs=auto) have_lufs_includes=false -PATH_LUFSMOUNT="" +# Although it would be more appropriate to use lufsmount(1) instead of lufsd(1) +# we use lufsd(1) as lufsmount(1) is just a dumb wrapper and it would cost us +# another big binary file for the static build package version. +PATH_LUFSD="" if test x$enable_lufs != no;then have_lufs_includes=true dnl If ACTION-IF-NOT-FOUND is given, it is executed when one of the header @@ -332,17 +335,17 @@ if test x$enable_lufs != no;then AC_MSG_WARN([Although LUFS include files were found they are too old. df(1) will not show available NTFS disk space.]) fi ],[#include ]) - AC_PATH_PROGS(PATH_LUFSMOUNT,lufsmount) - if test x$PATH_LUFSMOUNT = x;then + AC_PATH_PROGS(PATH_LUFSD,lufsd) + if test x$PATH_LUFSD = x;then if test x$enable_lufs = xyes;then - AC_MSG_ERROR([LUFS client was requested (--enable-lufs) but no lufsmount(1) binary was found. Install 'lufs-*-*captive*' package.]) + AC_MSG_ERROR([LUFS client was requested (--enable-lufs) but no lufsd(1) binary was found. Install 'lufs-*-*captive*' package.]) else - AC_MSG_WARN([LUFS client not being compiled as no lufsmount(1) binary was found. Install 'lufs-*-*captive*' package.]) + AC_MSG_WARN([LUFS client not being compiled as no lufsd(1) binary was found. Install 'lufs-*-*captive*' package.]) fi fi fi -AM_CONDITIONAL(ENABLE_LUFS,[ $have_lufs_includes && test x$PATH_LUFSMOUNT != x -a x$enable_lufs != no ]) -AC_SUBST(PATH_LUFSMOUNT) +AM_CONDITIONAL(ENABLE_LUFS,[ $have_lufs_includes && test x$PATH_LUFSD != x -a x$enable_lufs != no ]) +AC_SUBST(PATH_LUFSD) dnl for $(top_srcdir)/src/libcaptive/client/ dnl Do not use '[client server]' as $4 to prevent: configure: test: too many arguments diff --git a/src/client/lufs/lufs-captivefs.pod.pl.in b/src/client/lufs/lufs-captivefs.pod.pl.in index 33104ff..de68351 100644 --- a/src/client/lufs/lufs-captivefs.pod.pl.in +++ b/src/client/lufs/lufs-captivefs.pod.pl.in @@ -36,7 +36,7 @@ B(7) module for Linux Userland 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 +{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. @@ -47,7 +47,7 @@ require "../../libcaptive/client/options.pod.pl"; print <<'POD_EOF'; =head1 SEE ALSO -B(8), B(1), B<@PACKAGE@>(7) +B(8), B(1), B<@PACKAGE@>(7) =head1 AUTHOR diff --git a/src/client/lufs/mount.captive.in b/src/client/lufs/mount.captive.in index 5bf664e..209e27c 100755 --- a/src/client/lufs/mount.captive.in +++ b/src/client/lufs/mount.captive.in @@ -1,7 +1,7 @@ #! /usr/bin/perl -w # # $Id$ -# External mount command for mount(8) to interface lufsmount(1) +# External mount command for mount(8) to interface lufsd(1) # Copyright (C) 2003 Jan Kratochvil # # This program is free software; you can redistribute it and/or modify @@ -28,8 +28,8 @@ use Getopt::Long; my $vardir='@localstatedir@/lib/captive'; $vardir=~s#\$\Q{prefix}\E#'@prefix@';#ge; $vardir="/var/lib/captive" if $vardir=~/^@/; -my $lufsmount_bin='@PATH_LUFSMOUNT@'; -$lufsmount_bin="/usr/bin/lufsmount" if $lufsmount_bin=~/^@/; +my $lufsd_bin='@PATH_LUFSD@'; +$lufsd_bin="/usr/bin/lufsd" if $lufsd_bin=~/^@/; my $captive_sandbox_server_bin='@sbindir@/captive-sandbox-server'; $captive_sandbox_server_bin=~s#\$\Q{exec_prefix}\E#'@exec_prefix@';#ge; $captive_sandbox_server_bin=~s#\$\Q{prefix}\E#'@prefix@';#ge; @@ -112,6 +112,7 @@ if (!$opt_force) { } $oo="" + ."fs=captivefs," ."mntent.mnt_fsname=$image,mntent.mnt_type=captive-$fsname," # Double-dashes forbidden. ."dir_cache_entries=0," ."image=$image," @@ -127,8 +128,8 @@ $oo="" warn "$0: '-n' not supported - ignored" if $nomtab; # Use "'$oo'" to permit another expansion by bash(1) during lufsmnt(8) execution. -my @argv=($lufsmount_bin,"captivefs://",$dir,"-o","'$oo'"); +my @argv=($lufsd_bin,"none",$dir,"-o",$oo); print STDERR "$0: @argv\n" if $verbose; -exec $lufsmount_bin @argv; +exec $lufsd_bin @argv; die "Failed to execute: @argv"; diff --git a/src/client/lufs/mount.captive.pod.pl.in b/src/client/lufs/mount.captive.pod.pl.in index be3676d..3796168 100644 --- a/src/client/lufs/mount.captive.pod.pl.in +++ b/src/client/lufs/mount.captive.pod.pl.in @@ -43,7 +43,7 @@ B B<-t> B<@PACKAGE@-ntfs> =head1 DESCRIPTION B(8) provides B(8) interface to B(7) -by calling B(1) with appropriate arguments. You should never call +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 @@ -81,7 +81,7 @@ B is modified notwithstanding. =item B<-v> -Enable verbose mode. Command B(1) being called is shown. +Enable verbose mode. Command B(1) being called is shown. =item B<-o> B @@ -90,7 +90,7 @@ Custom options passed to B<@PACKAGE@>(7) separated by comma (B<,>). See the B<@PACKAGE@>(7) manpage for details on options prefixed by double-dashes (B<-->) will be used for B(7) / B(8). Options without double-dashes (B<-->) will be used for -B(1). You may be interested in these unprefixed options: +B(1). You may be interested in these unprefixed options: =over @@ -104,7 +104,7 @@ in read-only mode although you may encounter filesystem errors by the read-only filesystems in such case. This is the only option is interpreted by B itself; it is not -B(7) nor B(1) option. +B(7) nor B(1) option. =item B=B<500> @@ -130,7 +130,7 @@ permissions). =head1 SEE ALSO -B(7), B(1) +B(7), B(1) =head1 AUTHOR