From 1109843d017e0320f0d18bfc398e27ff25592dfb Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Thu, 4 Apr 2024 15:17:38 -0400 Subject: build: Don't use libattr We only rely on interfaces like listxattr() which are provided by the C library itself. --- .github/workflows/ci.yml | 3 --- .github/workflows/codecov.yml | 1 - .github/workflows/codeql.yml | 1 - GNUmakefile | 7 ------- README.md | 6 +++--- docs/BUILDING.md | 4 +--- 6 files changed, 4 insertions(+), 18 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 4c1c89c..8e688fe 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,8 +23,6 @@ jobs: libacl1-dev \ libacl1:i386 \ attr \ - libattr1-dev \ - libattr1:i386 \ libcap2-bin \ libcap-dev \ libcap2:i386 \ @@ -34,7 +32,6 @@ jobs: # Ubuntu doesn't let you install the -dev packages for both amd64 and # i386 at once, so we make our own symlinks to fix -m32 -lacl -l... sudo ln -s libacl.so.1 /lib/i386-linux-gnu/libacl.so - sudo ln -s libattr.so.1 /lib/i386-linux-gnu/libattr.so sudo ln -s libcap.so.2 /lib/i386-linux-gnu/libcap.so sudo ln -s libonig.so.5 /lib/i386-linux-gnu/libonig.so # Work around https://github.com/actions/runner-images/issues/9491 diff --git a/.github/workflows/codecov.yml b/.github/workflows/codecov.yml index 9c2119b..d1dc351 100644 --- a/.github/workflows/codecov.yml +++ b/.github/workflows/codecov.yml @@ -18,7 +18,6 @@ jobs: acl \ libacl1-dev \ attr \ - libattr1-dev \ libcap2-bin \ libcap-dev \ libonig-dev \ diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 71073c6..c50b266 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -34,7 +34,6 @@ jobs: acl \ libacl1-dev \ attr \ - libattr1-dev \ libcap2-bin \ libcap-dev \ libonig-dev \ diff --git a/GNUmakefile b/GNUmakefile index 080fb17..8685ca3 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -125,7 +125,6 @@ endif # USE_ONIGURUMA ifeq ($(OS),Linux) ifndef NOLIBS USE_ACL := y -USE_ATTR := y USE_LIBCAP := y USE_LIBURING := y endif @@ -136,12 +135,6 @@ else LOCAL_CPPFLAGS += -DBFS_USE_SYS_ACL_H=0 endif -ifdef USE_ATTR -LOCAL_LDLIBS += -lattr -else -LOCAL_CPPFLAGS += -DBFS_USE_SYS_XATTR_H=0 -endif - ifdef USE_LIBCAP LOCAL_LDLIBS += -lcap else diff --git a/README.md b/README.md index 9992938..17226fd 100644 --- a/README.md +++ b/README.md @@ -293,7 +293,7 @@ Here's how to install them on some common platforms:
 Alpine Linux
-# apk add acl{,-dev} attr{,-dev} libcap{,-dev} liburing-dev oniguruma-dev
+# apk add acl{,-dev} attr libcap{,-dev} liburing-dev oniguruma-dev
 
 Arch Linux
 # pacman -S acl attr libcap liburing oniguruma
@@ -302,13 +302,13 @@ Here's how to install them on some common platforms:
 # apt install acl libacl1-dev attr libattr1-dev libcap2-bin libcap-dev liburing-dev libonig-dev
 
 Fedora
-# dnf install acl libacl-devel libattr-devel libcap-devel liburing-devel oniguruma-devel
+# dnf install acl libacl-devel attr libcap-devel liburing-devel oniguruma-devel
 
 NixOS
 # nix-env -i acl attr libcap liburing oniguruma
 
 Void Linux
-# xbps-install -S acl-{devel,progs} attr-{devel,progs} libcap-{devel,progs} liburing-devel oniguruma-devel
+# xbps-install -S acl-{devel,progs} attr-progs libcap-{devel,progs} liburing-devel oniguruma-devel
 
 Homebrew
 $ brew install oniguruma
diff --git a/docs/BUILDING.md b/docs/BUILDING.md
index 02f9756..7eb3a37 100644
--- a/docs/BUILDING.md
+++ b/docs/BUILDING.md
@@ -56,7 +56,7 @@ Here are some of the common ones; check the [`GNUmakefile`](/GNUmakefile) for mo
 | `CC`                             | The C compiler to use, e.g. `make CC=clang` |
 | `CFLAGS`
`EXTRA_CFLAGS` | Override/add to the default compiler flags | | `LDFLAGS`
`EXTRA_LDFLAGS` | Override/add to the linker flags | -| `USE_ACL`
`USE_ATTR`
... | Enable/disable [optional dependencies] | +| `USE_ACL`
`USE_LIBCAP`
... | Enable/disable [optional dependencies] | | `TEST_FLAGS` | `tests.sh` flags for `make check` | | `BUILDDIR` | The build output directory (default: `.`) | | `DESTDIR` | The root directory for `make install` | @@ -73,13 +73,11 @@ These dependencies are optional, and can be turned off at build time if necessar | Dependency | Platforms | `make` flag | |-------------|------------|-----------------| | [acl] | Linux only | `USE_ACL` | -| [attr] | Linux only | `USE_ATTR` | | [libcap] | Linux only | `USE_LIBCAP` | | [liburing] | Linux only | `USE_LIBURING` | | [Oniguruma] | All | `USE_ONIGURUMA` | [acl]: https://savannah.nongnu.org/projects/acl -[attr]: https://savannah.nongnu.org/projects/attr [libcap]: https://sites.google.com/site/fullycapable/ [liburing]: https://github.com/axboe/liburing [Oniguruma]: https://github.com/kkos/oniguruma -- cgit v1.2.3