Linux From Scratch - Version 8.0-rc1

Chapter 6. Installing Basic System Software

6.21. Attr-2.4.47

The attr package contains utilities to administer the extended
attributes on filesystem objects.

Approximate build time:less than 0.1 SBU

Required disk space:3.3 MB

6.21.1. Installation of Attr

Modify the documentation directory so that it is a versioned
directory:

sed -i -e 's|/@pkg_name@|&-@pkg_version@|' include/builddefs.in

Prevent installation of manual pages that were already installed by
the man pages package:

sed -i -e "/SUBDIRS/s|man[25]||g" man/Makefile

Prepare Attr for compilation:

./configure --prefix=/usr \
--bindir=/bin \
--disable-static

Compile the package:

make

The tests need to be run on a filesystem that supports extended
attributes such as the ext2, ext3, or ext4 filesystems. The tests
are also known to fail if running multiple simultaneous tests (-j
option greater than 1). To test the results, issue:

make -j1 tests root-tests

Install the package:

make install install-dev install-lib
chmod -v 755 /usr/lib/libattr.so

The shared library needs to be moved to /lib, and as a result the .so file in /usr/lib will need to be recreated: