Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Closed
zsef123 opened this issue Aug 9, 2022 · 8 comments
Closed

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

zsef123 opened this issue Aug 9, 2022 · 8 comments
Assignees
Labels
bug Something isn't working channel: windows bugs, questions, & RFEs around Windows

Comments

@zsef123
Copy link
Contributor

zsef123 commented Aug 9, 2022

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

@zsef123 zsef123 added the bug Something isn't working label Aug 9, 2022
@narendasan narendasan added the channel: windows bugs, questions, & RFEs around Windows label Aug 10, 2022
@narendasan
Copy link
Collaborator

@andi4191 Do you have access to a Windows machine to repro? I wont for a few weeks

@andi4191
Copy link
Contributor

I need to check.

@zsef123
Copy link
Contributor Author

zsef123 commented Aug 10, 2022

That error causes missing new file in CMakelists( fine in Bazel)
I thinks this srcs to handle with glob

And I still got other linking errors related the Compile spec or GraphInputs

I hope I fix that and upload PR

@narendasan
Copy link
Collaborator

The graph input fix for cmake was merged last night, so maybe try that out and see if it helps

@zsef123
Copy link
Contributor Author

zsef123 commented Aug 10, 2022

That error causes missing new file in CMakelists( fine in Bazel) I thinks this srcs to handle with glob

And I still got other linking errors related the Compile spec or GraphInputs

I fused problems.
missing file is related with GraphInputs ( above comments)

And still got error about Input or Compilepsecs

@centerzong
Copy link

I meet the same problem on windows10.i need help.

@andi4191
Copy link
Contributor

andi4191 commented Sep 1, 2022

@centerzong: Can you please try the master branch and confirm if it fixes your issue?

@zsef123
Copy link
Contributor Author

zsef123 commented Sep 6, 2022

@andi4191 working fine 👍

@zsef123 zsef123 closed this as completed Sep 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working channel: windows bugs, questions, & RFEs around Windows
Projects
None yet
Development

No branches or pull requests

4 participants