package/util-linux: fix build with headers < 3.14

Fix the following build failure raised since bump to version 2.37.2 in
commit 27a46793b1 and the addition of
uclampset in
https://git.kernel.org/pub/scm/utils/util-linux/util-linux.git/commit/?id=9dd95bea42a3b467c1f773fd2e781cc9f0d88847:

checking for syscall sched_setattr... no
configure: WARNING: Unable to detect syscall sched_setattr.
checking for syscall sched_setattr... (cached) no
configure: WARNING: Unable to detect syscall sched_setattr.
configure: error: uclampset selected but sched_setattr syscall not found

Fix this build failure by adding a dependency on headers >= 3.14 for
scheduling utilities:
e6cfc0295c

Fixes:
 - http://autobuild.buildroot.org/results/9fe26ab98c93b67f937293f28625843da7ccb77f

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
This commit is contained in:
Fabrice Fontaine 2021-10-22 23:53:37 +02:00 committed by Thomas Petazzoni
parent 1d1a17083b
commit 2033992ac0
2 changed files with 9 additions and 3 deletions

View File

@ -105,6 +105,7 @@ config BR2_PACKAGE_LINUX_TOOLS_SELFTESTS
depends on BR2_PACKAGE_BUSYBOX_SHOW_OTHERS # bash
depends on BR2_USE_MMU # bash
depends on !BR2_STATIC_LIBS
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14 # util-linux schedutils
select BR2_PACKAGE_LINUX_TOOLS
select BR2_PACKAGE_BASH # runtime
select BR2_PACKAGE_NCURSES
@ -126,9 +127,10 @@ config BR2_PACKAGE_LINUX_TOOLS_SELFTESTS
This is very much a use at your risk option and may not work
for every setup or every architecture.
comment "selftests needs BR2_PACKAGE_BUSYBOX_SHOW_OTHERS and a toolchain w/ dynamic library"
comment "selftests needs BR2_PACKAGE_BUSYBOX_SHOW_OTHERS and a toolchain w/ dynamic library and headers >= 3.14"
depends on BR2_USE_MMU
depends on !BR2_PACKAGE_BUSYBOX_SHOW_OTHERS || BR2_STATIC_LIBS
depends on !BR2_PACKAGE_BUSYBOX_SHOW_OTHERS || \
BR2_STATIC_LIBS || !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14
config BR2_PACKAGE_LINUX_TOOLS_TMON
bool "tmon"

View File

@ -330,8 +330,12 @@ comment "runuser needs a uClibc or glibc toolchain w/ wchar, locale, dynamic lib
config BR2_PACKAGE_UTIL_LINUX_SCHEDUTILS
bool "scheduling utilities"
depends on BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14
help
Scheduling utilities (chrt, ionice, taskset)
Scheduling utilities (chrt, ionice, taskset, uclampset)
comment "scheduling utilities need a toolchain w/ headers >= 3.14"
depends on !BR2_TOOLCHAIN_HEADERS_AT_LEAST_3_14
config BR2_PACKAGE_UTIL_LINUX_SETPRIV
bool "setpriv"