Skip to content

请问windows 下如何实现编译? #4

Description

@zhanghongyong123456

我使用cmake .. -DTensorRT_ROOT="I:\path to\TensorRT-8.6.1.6" -G "Visual Studio 17 2022" 得到:grid_sample_3d_plugin.sln 当在VS2022 编译时,出现这个错误: 请问该如何解决,谢谢
test.obj : error LNK2019: 无法解析的外部符号 "int __cdecl grid_sample_3d_cuda(struct __half const *,struct __half
const *,unsigned __int64,unsigned __int64,unsigned __int64,unsigned __int64,unsigned __int64,unsigned __int64,unsigned
__int64,unsigned __int64,bool,enum GridSample3DInterpolationMode,enum GridSample3DPaddingMode,struct __half *,struct C
Ustream_st *)" (??$grid_sample_3d_cuda@U__half@@@@YAHPEBU__half@@0_K1111111_NW4GridSample3DInterpolationMode@@W4GridSam
ple3DPaddingMode@@PEAU0@PEAUCUstream_st@@@z),函数 "void __cdecl testGridSample3dFloat16(void)" (?testGridSample3dFloat16@
@yaxxz) 中引用了该符号 [D:\2023project\project\0win_os\06Generative\FasterLivePortrait\grid-sample3d-trt-plugin\build\test\tes
t_grid_sample.vcxproj]
test.obj : error LNK2019: 无法解析的外部符号 "int __cdecl grid_sample_3d_cuda(float const *,float const *,unsigned __int6
4,unsigned __int64,unsigned __int64,unsigned __int64,unsigned __int64,unsigned __int64,unsigned __int64,unsigned __int6
4,bool,enum GridSample3DInterpolationMode,enum GridSample3DPaddingMode,float *,struct CUstream_st *)" (??$grid_sample_3
d_cuda@M@@YAHPEBM0_K1111111_NW4GridSample3DInterpolationMode@@W4GridSample3DPaddingMode@@PEAMPEAUCUstream_st@@@z),函数 "v
oid __cdecl testGridSample3dFloat32(void)" (?testGridSample3dFloat32@@yaxxz) 中引用了该符号 [D:\2023project\project\0win_os\06
Generative\FasterLivePortrait\grid-sample3d-trt-plugin\build\test\test_grid_sample.vcxproj]
D:\2023project\project\0win_os\06Generative\FasterLivePortrait\grid-sample3d-trt-plugin\build\test\Debug\test_grid_samp
le.exe : fatal error LNK1120: 2 个无法解析的外部命令 [D:\2023project\project\0win_os\06Generative\FasterLivePortrait\grid-sample3
d-trt-plugin\build\test\test_grid_sample.vcxproj]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions