blob: 6ba482c2997ed750a5ce651f618d505280c5797c [file] [log] [blame]
Andrew Morgan2c9c0532007-07-10 20:50:21 -07001This is a library for getting and setting POSIX.1e (formerly POSIX 6)
2draft 15 capabilities.
3
Andrew G. Morgand7dce562020-01-05 08:55:50 -08004Natively supported languages are C/C++ and Go.
5
Andrew Morgan2c9c0532007-07-10 20:50:21 -07006This library would not have been possible without the help of
7
8 Aleph1, Roland Buresund and Andrew Main, Alexander Kjeldaas.
9
Andrew G. Morgand7dce562020-01-05 08:55:50 -080010More information on capabilities in the Linux kernel, links to the
11official git repostitory for libcap, release notes and how to report
12bugs can be found at:
Andrew Morgan2c9c0532007-07-10 20:50:21 -070013
Andrew G. Morgan1b5fb7e2008-11-10 18:00:28 -080014 http://sites.google.com/site/fullycapable/
Andrew Morgan2c9c0532007-07-10 20:50:21 -070015
Andrew G. Morgand7dce562020-01-05 08:55:50 -080016# BUILDING AND INSTALLATION
Andrew Morgan2c9c0532007-07-10 20:50:21 -070017
Andrew G. Morgand7dce562020-01-05 08:55:50 -080018 $ make
Andrew Morgan2c9c0532007-07-10 20:50:21 -070019
Andrew G. Morgand7dce562020-01-05 08:55:50 -080020 builds the library and the programs that are expected
21 to work on your system. For example, if you have
22 Linux-PAM installed, pam_cap is built. A golang
23 installation is required to build the Go packages.
Andrew Morgan2c9c0532007-07-10 20:50:21 -070024
Andrew G. Morgand7dce562020-01-05 08:55:50 -080025 $ make test
Andrew Morgan2c9c0532007-07-10 20:50:21 -070026
Andrew G. Morgand7dce562020-01-05 08:55:50 -080027 runs all of the tests not requiring privilege
Andrew Morgan2c9c0532007-07-10 20:50:21 -070028
Andrew G. Morgand7dce562020-01-05 08:55:50 -080029 $ make sudotest
30
31 runs all of the tests including those that require privilege.
32
33 $ sudo make install
34
Andrew G. Morgan19eebc52020-07-05 14:07:52 -070035 default installs the library libcap.XX.Y in /lib[64]/
Andrew G. Morgand7dce562020-01-05 08:55:50 -080036 the binaries in /sbin/
37 the header files in /usr/include
38 the {libcap,libpsx}.pc files in /usr/lib[64]/pkgconfig
Andrew G. Morgan19eebc52020-07-05 14:07:52 -070039 the Go packages (if built) under /usr/share/gocode/src
Andrew G. Morgand7dce562020-01-05 08:55:50 -080040
Andrew G. Morgan19eebc52020-07-05 14:07:52 -070041For some example C programs look in the progs/ directory. Specifically,
42capsh, getpcaps, setcap and getcap.
43
44Go example programs are to be found in the goapps/ directory. There
45are also some more complicated integration tests in the go/ directory.
Andrew Morgan2c9c0532007-07-10 20:50:21 -070046
47Cheers
48
Andrew Morgan5216fff2007-07-10 22:38:22 -070049Andrew G. Morgan <morgan@kernel.org>