diff mbox series

[3/3] ci/debian.sh: Make dependencies really minimal

Message ID 20240823114217.1261861-4-pvorel@suse.cz
State Accepted
Headers show
Series ci: Simplify and speedup minimal installation | expand

Commit Message

Petr Vorel Aug. 23, 2024, 11:42 a.m. UTC
Remove most of the optional library headers.

LTP should be compilable without linux-libc-dev, but we expect kernel
headers.

libc6-dev and libtirpc-dev are hard dependencies for gcc toolchain.
Removing libtirpc-dev removes build-essential and that in the end
removes libc6-dev, which has /usr/lib/x86_64-linux-gnu/crti.o and
/usr/lib/x86_64-linux-gnu/Scrt1.o. That would cause toolchain to fail:

    configure:4088: gcc -Wformat -Werror=format-security \
	-Werror=implicit-function-declaration -Werror=return-type \
	-fno-common   conftest.c  >&5
    /usr/bin/ld: cannot find Scrt1.o: No such file or directory
    /usr/bin/ld: cannot find crti.o: No such file or directory
    collect2: error: ld returned 1 exit status

Signed-off-by: Petr Vorel <pvorel@suse.cz>
---
 ci/debian.sh | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

Comments

Li Wang Aug. 26, 2024, 7:44 a.m. UTC | #1
For series:
Reviewed-by: Li Wang <liwang@redhat.com>
diff mbox series

Patch

diff --git a/ci/debian.sh b/ci/debian.sh
index 68cf1509fc..fc1c1b3ec6 100755
--- a/ci/debian.sh
+++ b/ci/debian.sh
@@ -14,8 +14,9 @@  export DEBIAN_FRONTEND="noninteractive"
 install="apt install -y --no-install-recommends"
 remove="apt remove -y"
 
+# libc6-dev and libtirpc-dev are hard dependencies for gcc toolchain
+# LTP should be compilable without linux-libc-dev, but we expect kernel headers.
 pkg_minimal="
-	acl-dev
 	autoconf
 	automake
 	build-essential
@@ -26,8 +27,6 @@  pkg_minimal="
 	git
 	iproute2
 	libc6-dev
-	libjson-perl
-	libmnl-dev
 	libtirpc-dev
 	linux-libc-dev
 	lsb-release
@@ -35,14 +34,17 @@  pkg_minimal="
 "
 
 pkg_nonessential="
+	acl-dev
 	asciidoc-base
 	asciidoc-dblatex
 	asciidoctor
 	libacl1-dev
 	libaio-dev
 	libcap-dev
+	libjson-perl
 	libkeyutils-dev
 	libnuma-dev
+	libmnl-dev
 	libselinux1-dev
 	libsepol-dev
 	libssl-dev