Build test deps separately to avoid LD_LIBRARY_PATH interference
Otherwise invocations of host clang will use the newly built libraries, which will use a non-existent resource directory, and thus cause headers like stddef.h not to be found.
This commit is contained in:
parent
abec3da8de
commit
71aa74debd
@ -469,6 +469,10 @@ ln -s %{_datadir}/clang/clang-format-diff.py %{buildroot}%{_bindir}/clang-format
|
|||||||
%check
|
%check
|
||||||
%if %{without compat_build}
|
%if %{without compat_build}
|
||||||
%if %{with check}
|
%if %{with check}
|
||||||
|
# Build test dependencies separately, to prevent invocations of host clang from being affected
|
||||||
|
# by LD_LIBRARY_PATH below.
|
||||||
|
%cmake_build --target clang-test-depends \
|
||||||
|
ExtraToolsUnitTests ClangdUnitTests ClangIncludeCleanerUnitTests ClangPseudoUnitTests
|
||||||
# requires lit.py from LLVM utilities
|
# requires lit.py from LLVM utilities
|
||||||
# FIXME: Fix failing ARM tests
|
# FIXME: Fix failing ARM tests
|
||||||
LD_LIBRARY_PATH=%{buildroot}/%{_libdir} %{__ninja} check-all -C %{__cmake_builddir} || \
|
LD_LIBRARY_PATH=%{buildroot}/%{_libdir} %{__ninja} check-all -C %{__cmake_builddir} || \
|
||||||
|
Loading…
Reference in New Issue
Block a user