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] Cannot built in vcpkg - MSVS2022 + Cuda 12.6 #161

Open
Apotrox opened this issue Aug 11, 2024 · 4 comments · May be fixed by #162
Open

[bug] Cannot built in vcpkg - MSVS2022 + Cuda 12.6 #161

Apotrox opened this issue Aug 11, 2024 · 4 comments · May be fixed by #162
Assignees
Labels
bugfix cuda issues related to cuda versions in progress prio:blocker

Comments

@Apotrox
Copy link

Apotrox commented Aug 11, 2024

Describe the bug
Trying to build AliceVision following the guide (for Windows), i am unable to build popsift.

To Reproduce
Steps to reproduce the behavior:

  1. Follow the guide on AliceVision framework to built dependencies (run .\vcpkg.exe install popsift in the vcpkg directory)
  2. wait
  3. see install-x64-windows-dbg-out.log

Expected behavior
Popsift builds without issues

Log
install-x64-windows-dbg-out.log

Desktop (please complete the following and other pertinent information):

  • OS: Win 11
  • PopSift version: popsift:x64-windows@0.9#5 (?)

Additional context
Previously had an error describing unsupported visual studio version/compiler. Updated Cuda from 12.3 to 12.6 as well as my VS2022 installation with the latest MSVC (17.9), fixing the compiler issue but presenting me with this :)

@griwodz griwodz self-assigned this Aug 12, 2024
@griwodz griwodz linked a pull request Aug 12, 2024 that will close this issue
@griwodz griwodz added prio:blocker in progress cuda issues related to cuda versions bugfix labels Aug 12, 2024
@Apotrox
Copy link
Author

Apotrox commented Aug 12, 2024

Hey @griwodz, i've been trying to build your mentioned branch and run into the issue of DevIL not being found. I have installed vcpkg by cloning the vcpkg repo into popsift folder, bootstrapped it from there. Installed all the necessary dependencies as listed in the README, including DevIL, still it can't seem to find it. Can you tell me what i am doing wrong here? Am i missing an argument that points to the DevIL library?

@griwodz
Copy link
Member

griwodz commented Aug 12, 2024

Hi @Apotrox , I don't actually know anything useful about Windows and vcpkg, I rely on the continuous integration on Github to see if Windows compiles. So I googled for something that may help.

"vcpkg install popsift" works by downloading its portfile.cmake
I believe the current portfile is here: https://github.com/microsoft/vcpkg/tree/6146b482ec13d1d33524e9708ffaaf5b7da5af41/ports/popsift

Section 2 on this web page "https://learn.microsoft.com/en-us/vcpkg/get_started/get-started-packaging?pivots=shell-cmd" explains how you can use portfiles in the local filesystem instead of downloading them from github if you set VCPKG_ROOT.

If that works, you can probably get the right branch.

Google gave a page with some hints: microsoft/vcpkg#1081

This looks as if you can update the portfile:

  • Maybe by changing "HEAD_REF develop" to "HEAD_REF dev/cmake-lang-cuda"
  • More likely by removing the HEAD_REF line and changing "REF 0.9" to "REF 5c37b81". This string is the last Github commit for the branch dev/cmake-lang-cuda.

I interpret the "issues/1801" page as: You try running vcpck once and it fails, but tells you the SHA512 hash you should be using. The "Getting started" web page says the same thing in section 6: try installing, fail, copy the right hash.
Update the hash, try again, and it should try to compile the PR.

@griwodz
Copy link
Member

griwodz commented Aug 12, 2024

One more ... I cannot see that the vcpkg portfile installs DevIL. See here:
https://github.com/microsoft/vcpkg/blob/6146b482ec13d1d33524e9708ffaaf5b7da5af41/ports/popsift/vcpkg.json
But there is a port of DevIL, it's in the long list of ports on the left side of this page.

Maybe the only thing needed is to add devil to vcpkg.json below the 4 boost dependencies?

@Apotrox
Copy link
Author

Apotrox commented Aug 12, 2024

@griwodz Holy! Thanks! It built!
Note that i went back to the vcpkg installation in AliceVision Framework and set that one as root again (just how it is described in the installation guide).
For future reference, try to build popsift with vcpkg first and have it fail. Then navigate to .\vcpkg\ports\popsift\ and edit the following files:

  • portfile.cmake => remove all patches, the HEAD_REF and set REF to the commit desired (as you described).
  • vcpkg.json => add devil to dependencies. Maybe increase the port-version, i did that so i can't say if it holds any relevance.
    Then try to build again. It will fail but will give you the new SHA512 hash. Edit the portfile.cmake once again and replace the hash. Done!

@griwodz griwodz linked a pull request Aug 12, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix cuda issues related to cuda versions in progress prio:blocker
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants