sp_state_shader.c:146: undefined reference to `nir_to_tgsi'
$ scons llvm=0 force_scons=1
[...]
Linking build/linux-x86_64-debug/gallium/targets/libgl-xlib/libGL.so.1.5 ...
/usr/bin/ld: build/linux-x86_64-debug/gallium/drivers/softpipe/libsoftpipe.a(sp_state_shader.os): in function `softpipe_create_shader_state':
src/gallium/drivers/softpipe/sp_state_shader.c:146: undefined reference to `nir_to_tgsi'
/usr/bin/ld: build/linux-x86_64-debug/gallium/drivers/softpipe/libsoftpipe.a(sp_state_shader.os): in function `softpipe_create_compute_state':
src/gallium/drivers/softpipe/sp_state_shader.c:435: undefined reference to `nir_to_tgsi'
collect2: error: ld returned 1 exit status
fa483d8cd1bc975c339082435a2e0f657959ea39 is the first bad commit
commit fa483d8cd1bc975c339082435a2e0f657959ea39
Author: Marijn Suijten <marijns95@gmail.com>
Date: Tue Oct 20 20:00:18 2020 +0200
android: gallium/auxiliary: Deduplicate nir_to_tgsi.c inclusion
Both commits add nir_to_tgsi.c to a different variable, causing a
build-time error when compiling in an AOSP tree:
build/make/core/binary.mk:970: error: overriding commands for target `..../obj/STATIC_LIBRARIES/libmesa_gallium_intermediates/nir/nir_to_tgsi.o', previously defined at build/make/core/binary.mk:970
Move all sources into NIR_SOURCES to resolve this issue.
Fixes: d0f8fe59091 ("softpipe: Switch to using NIR as the shader format from mesa/st.")
Fixes: 34cc6a804ec ("gallium: Add a nir-to-TGSI pass.")
Reviewed-by: Eric Anholt <eric@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7237>
src/gallium/auxiliary/Makefile.sources | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
bisect run success
cc: @MarijnS95 @anholt