2019-11-11 23:00:08 +03:00
|
|
|
-- Getting started --
|
2016-08-29 05:00:50 +03:00
|
|
|
|
|
|
|
Dependencies:
|
|
|
|
|
2019-01-14 11:04:11 +03:00
|
|
|
* libaio
|
2016-08-29 05:00:50 +03:00
|
|
|
* libblkid
|
2019-01-14 11:04:11 +03:00
|
|
|
* libkeyutils
|
|
|
|
* liblz4
|
2016-08-29 05:00:50 +03:00
|
|
|
* libsodium
|
2017-03-10 23:48:39 +03:00
|
|
|
* liburcu
|
2019-01-14 11:04:11 +03:00
|
|
|
* libuuid
|
|
|
|
* libzstd
|
2017-03-10 23:48:39 +03:00
|
|
|
* pkg-config
|
|
|
|
* zlib1g
|
2019-10-05 00:18:33 +03:00
|
|
|
* valgrind
|
2016-08-29 05:00:50 +03:00
|
|
|
|
2019-12-06 08:51:10 +03:00
|
|
|
Debian (Bullseye or later) and Ubuntu (20.04 or later): you can install these with
|
2019-01-14 11:04:11 +03:00
|
|
|
apt install -y pkg-config libaio-dev libblkid-dev libkeyutils-dev \
|
2021-10-23 18:49:25 +03:00
|
|
|
liblz4-dev libsodium-dev liburcu-dev libzstd-dev \
|
2021-07-25 13:25:31 +03:00
|
|
|
uuid-dev zlib1g-dev valgrind libudev-dev git build-essential \
|
|
|
|
python3 python3-docutils
|
2016-08-29 05:00:50 +03:00
|
|
|
|
2019-12-06 08:51:10 +03:00
|
|
|
Fedora: install the "Development tools" group along with:
|
|
|
|
dnf install -y libaio-devel libsodium-devel \
|
|
|
|
libblkid-devel libzstd-devel zlib-devel userspace-rcu-devel \
|
|
|
|
lz4-devel libuuid-devel valgrind-devel keyutils-libs-devel \
|
2021-10-23 18:49:25 +03:00
|
|
|
findutils
|
2019-12-06 08:51:10 +03:00
|
|
|
|
|
|
|
Arch: install bcachefs-tools-git from the AUR.
|
2021-10-23 18:49:25 +03:00
|
|
|
Or to build from source, install build dependencies with
|
2019-12-06 08:51:10 +03:00
|
|
|
pacman -S base-devel libaio keyutils libsodium liburcu zstd valgrind
|
|
|
|
|
2016-08-29 05:00:50 +03:00
|
|
|
Then, just make && make install
|
2019-11-11 23:00:08 +03:00
|
|
|
|
|
|
|
|
|
|
|
-- Experimental features --
|
|
|
|
|
|
|
|
Experimental fuse support is currently disabled by default. Fuse support is at
|
|
|
|
an early stage and may corrupt your filesystem, so it should only be used for
|
|
|
|
testing. To enable, you'll also need to add:
|
|
|
|
|
2019-12-06 08:51:10 +03:00
|
|
|
* libfuse3 >= 3.7
|
2019-11-11 23:00:08 +03:00
|
|
|
|
2019-12-06 08:51:10 +03:00
|
|
|
On Debian/Ubuntu (Bullseye/20.04 or later needed for libfuse >= 3.7):
|
2019-11-11 23:00:08 +03:00
|
|
|
apt install -y libfuse3-dev
|
|
|
|
|
2019-12-06 08:51:10 +03:00
|
|
|
On Fedora (32 or later needed for lbifuse >= 3.7):
|
|
|
|
dnf install -y fuse3-devel
|
|
|
|
|
|
|
|
Arch:
|
|
|
|
pacman -S fuse3
|
|
|
|
|
2019-12-06 19:22:19 +03:00
|
|
|
Then, make using the BCACHEFS_FUSE environment variable (make clean first if
|
|
|
|
previously built without fuse support):
|
2019-11-11 23:00:08 +03:00
|
|
|
|
2019-12-06 08:51:10 +03:00
|
|
|
BCACHEFS_FUSE=1 make && make install
|
2019-11-11 23:00:08 +03:00
|
|
|
|
|
|
|
|
|
|
|
-- Tests --
|
|
|
|
|
|
|
|
Some tests are available to validate the "bcachefs" binary. The tests depend
|
|
|
|
on python3 pytest.
|
|
|
|
|
|
|
|
On debian:
|
2019-11-19 00:51:31 +03:00
|
|
|
apt install -u python3-pytest
|
2019-11-11 23:00:08 +03:00
|
|
|
|
|
|
|
Then, you can run the tests via:
|
|
|
|
|
2019-11-19 00:51:31 +03:00
|
|
|
make check
|
2019-12-06 08:51:10 +03:00
|
|
|
# or if pytest has a different name
|
|
|
|
make check PYTEST=pytest
|
2019-11-19 00:51:31 +03:00
|
|
|
|
|
|
|
Optionally, you may wish to run tests in parallel using python3-pytest-xdist:
|
|
|
|
|
|
|
|
cd tests; pytest-3 -n4
|