Add support for mounting from /etc/fstab

Fixes: #92.
This commit is contained in:
Nikolaus Rath 2017-09-20 14:24:22 +01:00
parent 848ff30d90
commit 949d76d1a2
4 changed files with 32 additions and 0 deletions

View File

@ -1,6 +1,7 @@
Unreleased Changes
------------------
* Add support for mounting from /etc/fstab
* Dropped support for building with autotools.
* Added missing options to man page.

View File

@ -63,6 +63,10 @@ else
message('rst2man not found, not building manual page.')
endif
meson.add_install_script('utils/install_helper.sh',
get_option('sbindir'),
get_option('bindir'))
subdir('test')

View File

@ -253,6 +253,14 @@ without SSHFS being informed about that. As a workaround, you can try
to mount with ``-o ServerAliveInterval=15``. This will force the SSH
connection to stay alive even if you have no activity.
Mounting from /etc/fstab
========================
To mount an SSHFS filesystem from ``/etc/fstab``, simply use ``sshfs`
as the file system type. (For backwards compatibility, you may also
use ``fuse.sshfs``).
See also
========

19
utils/install_helper.sh Executable file
View File

@ -0,0 +1,19 @@
#!/bin/sh
#
# Don't call this script. It is used internally by the Meson
# build system. Thank you for your cooperation.
#
set -e
bindir="$2"
sbindir="$1"
prefix="${MESON_INSTALL_DESTDIR_PREFIX}"
mkdir -p "${prefix}/${sbindir}"
ln -svf --relative "${prefix}/${bindir}/sshfs" \
"${prefix}/${sbindir}/mount.sshfs"
ln -svf --relative "${prefix}/${bindir}/sshfs" \
"${prefix}/${sbindir}/mount.fuse.sshfs"