Skip to content

🐛 [Bug] Error on build with CMAKE, win11 #1245

@zsef123

Description

@zsef123

Bug Description

C2487 error on Input Constructor

Error	C2487
'torch_tensorrt::Input::{ctor}': member of dll interface class may not be declared with dll interface	D:\projects\tensorrt\CMakeLists.txt
D:\projects\tensorrt\cpp\include\torch_tensorrt\torch_tensorrt.h	511	

TORCHTRT_API Input(std::vector<int64_t> shape, TensorFormat format = TensorFormat::kContiguous);
like this codes

To Reproduce

Use Visual Studio 2019 with CMake, Build > Install tab

Expected behavior

Environment

Build information about Torch-TensorRT can be found by turning on debug messages

  • Torch-TensorRT Version (e.g. 1.0.0): master
  • PyTorch Version (e.g. 1.0): 1.12
  • CPU Architecture: Ryzen 2700
  • OS (e.g., Linux): Win 11
  • How you installed PyTorch (conda, pip, libtorch, source): libtorch
  • Build command you used (if compiling from source):
  • Are you using local sources or building from archives:
  • Python version: 3.8
  • CUDA version: 11.4
  • GPU models and configuration: RTX3070
  • Any other relevant information:

Additional context

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingchannel: windowsbugs, questions, & RFEs around Windows

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions