Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 14 Jul 2024 16:43:19 GMT
From:      Mark Johnston <markj@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: a3e706fd422a - stable/14 - libc/tests: Fix installation without MK_TOOLCHAIN
Message-ID:  <202407141643.46EGhJoq039606@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/14 has been updated by markj:

URL: https://cgit.FreeBSD.org/src/commit/?id=a3e706fd422ae1b213bad5834b703cb48b07b691

commit a3e706fd422ae1b213bad5834b703cb48b07b691
Author:     Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2024-05-28 12:24:43 +0000
Commit:     Mark Johnston <markj@FreeBSD.org>
CommitDate: 2024-07-14 16:16:22 +0000

    libc/tests: Fix installation without MK_TOOLCHAIN
    
    There is some exotic conditional logic here to avoid building a
    particular test if a certain UBSAN library isn't present in the
    toolchain sysroot.  This causes build failures for me when doing an
    "installworld WITHOUT_TOOLCHAIN=", which I do frequently during tests.
    
    I believe the problem is that SYSROOT is unset during installworld, so
    the build sees the host's copy of libclang_rt.ubsan_standalone.a and
    then tries to install a binary that wasn't built during buildworld.  Try
    to make the check a bit less fragile.
    
    Reviewed by:    dim
    MFC after:      2 weeks
    Differential Revision:  https://reviews.freebsd.org/D45035
    
    (cherry picked from commit 8164d511d6a6053df82911e7d4ebb34fff3d765c)
---
 lib/libc/tests/ssp/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/libc/tests/ssp/Makefile b/lib/libc/tests/ssp/Makefile
index c6f850ec1a33..7c6f8d2ea0a7 100644
--- a/lib/libc/tests/ssp/Makefile
+++ b/lib/libc/tests/ssp/Makefile
@@ -29,7 +29,7 @@ PROGS+=		h_memset
 # now on amd64 when it trips the stack bounds specified in t_ssp.sh . This
 # probably needs to be fixed as it's currently hardcoded.
 .if ${COMPILER_TYPE} == "clang" && !defined(_SKIP_BUILD) && \
-    (!defined(_RECURSING_PROGS) || ${PROG} == "h_raw")
+    (!defined(_RECURSING_PROGS) || ${PROG} == "h_raw") && ${MK_TOOLCHAIN} == "yes"
 .include "${SRCTOP}/lib/libclang_rt/compiler-rt-vars.mk"
 _libclang_rt_ubsan=	${SYSROOT}${SANITIZER_LIBDIR}/libclang_rt.ubsan_standalone-${CRTARCH}.a
 .if exists(${_libclang_rt_ubsan})



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202407141643.46EGhJoq039606>