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

Python version mismatch when building ANARI-USD on Windows 11 #17

Open
nnn911 opened this issue Oct 11, 2024 · 1 comment
Open

Python version mismatch when building ANARI-USD on Windows 11 #17

nnn911 opened this issue Oct 11, 2024 · 1 comment

Comments

@nnn911
Copy link

nnn911 commented Oct 11, 2024

I attempted to build ANARI-USD on Windows 11 using the dependencies built with the "Connect Sample" approach described here.

However, the Omniverse Launcher directed me to the connect-samples GitHub repository instead of downloading the files to the pkg directory (difference to the steps described in the Readme). From this repository, I was able to obtain the samples and successfully build them using the provided build.bat file.

When I tried to build ANARI-USD against this connect-samples directory, I used the following CMake command:

cmake .. `
    -DUSD_DEVICE_USE_OMNIVERSE=ON `
    -DANARI_ROOT_DIR="<root>\anari_install_Debug" `
    -DUSD_ROOT_DIR="<root>\connect-samples\_build\target-deps\usd" `
    -DOMNIUSDRESOLVER_ROOT_DIR="<root>\connect-samples\_build\target-deps\omni_usd_resolver" `
    -DOMNICLIENT_ROOT_DIR="<root>\connect-samples\_build\target-deps\omni_client_library" `
    -DPython_ROOT_DIR="<root>\connect-samples\_build\target-deps\python" `
    -DPython_FIND_STRATEGY_LOCATION=ON `
    -DCMAKE_POSITION_INDEPENDENT_CODE=ON
cmake --build . --config Debug

Unfortunately, I encountered the following error:

Found Python: <root>/connect-samples/_build/target-deps/python/python.exe (found version "3.10.14") found components: Interpreter Development Development.Module Development.Embed
-------------------- Begin UsdBridge CmakeLists.txt ----------------------------------------
-- Using cmake value of USD_ROOT_DIR: <root>\connect-samples\_build\target-deps\usd
CMake Error at D:/Work/ovito-pro-deps/CMake/share/cmake-3.29/Modules/FindPackageHandleStandardArgs.cmake:225 (set):
  Syntax error in cmake code at

    D:/Work/ovito-pro-deps/CMake/share/cmake-3.29/Modules/FindPackageHandleStandardArgs.cmake:225

  when parsing string

    Could NOT find Python3: Found unsuitable version "3.10", but required is exact version "3.10.13" (found W:\aed3087ace93e092\_build\target-deps\python\libs\python310.lib, )

It appears that this issue is caused by a version mismatch in the connect-samples repo. You recomment version "102.1.5" in the Readme, but the earliest version available in the GitHub repository is "205.0.0".

I tried to configure connect-samples to use Python version 3.10.13 instead of 3.10.14, but so far, I've been unsuccessful.

Do you have any ideas or suggestions on how to resolve this issue?

Alternative Approaches

I also attempted to manually compile OpenUSD, which was successful. However, I was unable to obtain the other dependencies (omni_usd_resolver, omni_client_library). I couldn't find these in the Omniverse Launcher or the Omniverse SDK.

@kvankooten
Copy link
Collaborator

Sorry for the late reply;

It appears that this issue is caused by a version mismatch in the connect-samples repo. You recomment version "102.1.5" in the Readme, but the earliest version available in the GitHub repository is "205.0.0".

Both the documentation and the cmake scripts were still based on the old Omniverse Launcher version of the connect sample using a somewhat older version of USD. I've updated the build system and the steps to obtain the Omniverse dependencies based on the connect samples repo instead, and it also describes how to make sure the USD version is matching. That should resolve everything.

I also attempted to manually compile OpenUSD, which was successful.

Self-built versions of USD are unlikely to be compatible with the NVIDIA-built omni resolver and omni client library; you'd at least would have to match the USD and python build quite specifically. So that would be quite an experimental approach.

Cheers,
Kees

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants