cuda-target-environment: add nvcc/glibc 2.38 workaround

Update the CUDACXXARCHFLAGS environment variable to include
the same glibc 2.38 workaround to SDKs that was added to
cuda.bbclass with 52f994fbb3.

Signed-off-by: Matt Madison <matt@madison.systems>
This commit is contained in:
Matt Madison
2023-12-17 07:39:43 -08:00
committed by Matt Madison
parent 2ca310fff3
commit e36b91a179

View File

@@ -12,11 +12,12 @@ S = "${WORKDIR}"
COMPILER_CMD = "${@d.getVar('CXX_FOR_CUDA').split()[0]}"
CMAKE_CUDA_ARCHITECTURES = "${@d.getVar('CUDA_ARCHITECTURES') if d.getVar('CUDA_ARCHITECTURES') else 'OFF'}"
CUDA_EXTRA_CXXFLAGS ??= "-isystem=${includedir}/cuda-compat-workarounds"
def arch_flags(d):
archflags = d.getVar('TARGET_CC_ARCH')
archflags = (d.getVar('TARGET_CC_ARCH') or '').split() + (d.getVar('CUDA_EXTRA_CXXFLAGS') or '').split()
if archflags:
return "-Xcompiler " + ','.join(archflags.split())
return "-Xcompiler " + ','.join(archflags)
return ""
do_compile() {