]> git.ipfire.org Git - thirdparty/util-linux.git/commit
build-sys: add --enable-usrdir-path
authorKarel Zak <kzak@redhat.com>
Tue, 3 Mar 2015 10:36:59 +0000 (11:36 +0100)
committerKarel Zak <kzak@redhat.com>
Tue, 3 Mar 2015 10:43:01 +0000 (11:43 +0100)
commitf71d1104df68e9ab7f06878c1c324566721acd66
treee5dbce365fc74af2a663e3f016f657b746319a93
parentb7c67e6414a68caaef133e978b3110d599f3d147
build-sys: add --enable-usrdir-path

The directories /{sbin,bin} are symliks to /usr/{sbin,bin} on many
systems. This patch add new ./configure option to remove the non-usr
paths from the default $PATH environment variable.

The default $PATH is hardcoded in login(1) and can be overwritten
by /etc/login.defs.

default:

./test_pathnames | grep DEFPATH
       _PATH_DEFPATH /usr/local/bin:/bin:/usr/bin
  _PATH_DEFPATH_ROOT /usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin

--enable-usrdir-path:

./test_pathnames | grep DEFPATH
       _PATH_DEFPATH /usr/local/bin:/usr/bin
  _PATH_DEFPATH_ROOT /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin

This patch does not modify install paths, you still have to care about
--{bin,lib}dir configure options.

Signed-off-by: Karel Zak <kzak@redhat.com>
configure.ac
include/pathnames.h