mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2026-10-24 02:08:57 +03:00
build: support 'dist' and 'syntax-check' targets without libselinux
Following on from commit v9.8-60-g8ba47d09a ... Without libselinux installed, runcon and chcon stub binaries will not be built by default. We separate these utilities out to a separate "not built unless appropriate" class, so that we can add these to EXTRA_MANS so that the 'check-x-vs-1' target doesn't fail, and the 'dist' target includes these man pages. * build-aux/gen-lists-of-programs.sh: Separate out build_if_appropriate_progs, and propagate that through to no_install_progs_default which populates EXTRA_MANS. * src/local.mk: Separate out build_if_appropriate__progs for clarity and consistency.
This commit is contained in:
@@ -26,20 +26,26 @@ disabled_by_default_progs='
|
||||
# Programs that can be built only when certain requisite system
|
||||
# features are detected at configure time.
|
||||
build_if_possible_progs='
|
||||
chcon
|
||||
chroot
|
||||
df
|
||||
hostid
|
||||
libstdbuf.so
|
||||
nice
|
||||
pinky
|
||||
runcon
|
||||
stdbuf
|
||||
stty
|
||||
timeout
|
||||
users
|
||||
who
|
||||
'
|
||||
# Programs that are built only when certain requisite system
|
||||
# features are detected at configure time. I.e., they can
|
||||
# be built on all systems, but are only effective on some.
|
||||
# These will be built to create man pages for distribution.
|
||||
build_if_appropriate_progs='
|
||||
chcon
|
||||
runcon
|
||||
'
|
||||
|
||||
# All the other programs, to be built by default, and that should
|
||||
# be buildable without problems on any target system.
|
||||
@@ -149,7 +155,8 @@ case $#,$1 in
|
||||
echo "gl_ADD_PROG([optional_bin_progs], [$p])"
|
||||
done
|
||||
# Extra 'echo' to normalize whitespace.
|
||||
echo "no_install_progs_default='`echo $disabled_by_default_progs`'"
|
||||
echo "no_install_progs_default='`echo $disabled_by_default_progs \
|
||||
$build_if_appropriate_progs`'"
|
||||
sed 's/^ *//' <<END
|
||||
# Given the name of a variable containing a space-separated
|
||||
# list of install-by-default programs and the actual list of
|
||||
@@ -177,6 +184,10 @@ END
|
||||
for p in $build_if_possible_progs; do
|
||||
echo build_if_possible__progs += $progsdir/$p
|
||||
done
|
||||
echo build_if_appropriate__progs =
|
||||
for p in $build_if_appropriate_progs; do
|
||||
echo build_if_appropriate__progs += $progsdir/$p
|
||||
done
|
||||
echo default__progs =
|
||||
for p in $normal_progs; do
|
||||
echo default__progs += $progsdir/$p
|
||||
@@ -184,7 +195,7 @@ END
|
||||
;;
|
||||
1,--list-progs)
|
||||
for p in $disabled_by_default_progs $build_if_possible_progs \
|
||||
$normal_progs; do
|
||||
$build_if_appropriate_progs $normal_progs; do
|
||||
echo $p
|
||||
done
|
||||
;;
|
||||
|
||||
@@ -28,6 +28,7 @@ include $(srcdir)/src/cu-progs.mk
|
||||
EXTRA_PROGRAMS = \
|
||||
$(no_install__progs) \
|
||||
$(build_if_possible__progs) \
|
||||
$(build_if_appropriate__progs) \
|
||||
$(default__progs)
|
||||
|
||||
# The user can tweak these lists at configure time.
|
||||
|
||||
Reference in New Issue
Block a user