From 89a0efca819a721ed4d96c3f2625d3c6fbceeb93 Mon Sep 17 00:00:00 2001 From: David Lanier <122012029+lanierd-adsk@users.noreply.github.com> Date: Thu, 16 Jan 2025 17:21:57 +0100 Subject: [PATCH] Apply suggestions from code review Co-authored-by: ppt-adsk --- ...uildingWithLatestOpenUSDAndPreviousMaya.md | 20 +++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/doc/rebuildingWithLatestOpenUSDAndPreviousMaya.md b/doc/rebuildingWithLatestOpenUSDAndPreviousMaya.md index b8fd199eb..d22ad3800 100644 --- a/doc/rebuildingWithLatestOpenUSDAndPreviousMaya.md +++ b/doc/rebuildingWithLatestOpenUSDAndPreviousMaya.md @@ -1,6 +1,6 @@ # Building with the latest version of OpenUSD and with a previous version of Maya such as 2024 -Let's take as an example, you want to rebuild MayaHydra in Maya 2024 and OpenUSD 24.11 under Windows.
+Let's take as an example rebuilding MayaHydra in Maya 2024 and OpenUSD 24.11 under Windows.
With Maya 2024 the OpenUSD version used by default was 22.11 which was compiled with Python 3.10.8. ## Rebuilding OpenUSD @@ -15,8 +15,8 @@ If OpenUSD was not built with the same version of Python as the one used in your So for Maya 2024, we need to rebuild OpenUSD with Python 3.10.8.
To do so, you need to clone the OpenUSD repository and checkout the version used by MayaUsd and MayaHydra which is [v24.11-MayaUsd-Public](https://github.com/autodesk-forks/USD/tree/v24.11-MayaUsd-Public).
-As an example is given a Windows batch file to rebuild OpenUSD with Python 3.10.8 which is provided by mayapy.exe in the Maya/bin folder:

-But first, you may need to install Python modules for this version of Python if it's not yet installed (this, not only to rebuild OpenUSD but MayaUsd also), they are :
+As an example here is a Windows batch file to rebuild OpenUSD with Python 3.10.8 which is provided by mayapy.exe in the Maya/bin folder:

+First, to rebuild both OpenUSD and MayaUsd, you may need to install the following Python modules for this version of Python:
PyOpenGL==3.1.0, PySide6, jinja2 and pybind11.
We are assuming that Maya 2024 is installed in its default folder such as C:\Program Files\Autodesk\Maya2024.
``` @@ -30,7 +30,7 @@ To rebuild OpenUSD see the following Windows batch file as an example : ``` rem rebuild OpenUSD with Python 3.10.8 for maya 2024 -rem I had to install in mayapy.exe the modules : PyOpenGL==3.1.0, PySide6 and pybind11. +rem The following modules may need to be installed in mayapy.exe: PyOpenGL==3.1.0, PySide6 and pybind11. set openusd_maya_location=C:/Program^ Files/Autodesk/Maya2024 set openusd_python_include=%openusd_maya_location%/include/Python310/Python @@ -40,7 +40,7 @@ set openusd_python_lib=%openusd_maya_location%/lib/python310.lib rem our destination folder for the build set destination_folder="D:/USD-24.11-Python3.10.8" -rem rebuylding OpenUSD with Python 3.10.8 in release with debug info configuration, if you want to use release only, please change the build-variant +rem rebuilding OpenUSD with Python 3.10.8 in release with debug info configuration, if you want to use release only, please change the build-variant "%openusd_python_exe%" ".\build_scripts\build_usd.py" "%destination_folder%" ^ --build-variant=relwithdebuginfo ^ --build-python-info "%openusd_python_exe%" "%openusd_python_include%" "%openusd_python_lib%" 3.10.8 ^ @@ -81,7 +81,7 @@ set PATH=%PATH:C:\Users\%username%\AppData\Local\Programs\Python\Python311\Scrip set PATH=%PATH:C:\Users\%username%\AppData\Local\Programs\Python\Python311;=% set PATH=%PATH:C:\Users\%username%\AppData\Local\Programs\Python\Python311\=% -rem Add OpenUSD bon and lib path to the Windows PATH +rem Add OpenUSD bin and lib path to the Windows PATH set PATH=%mayausd_pixar_usd_location%\bin;%mayausd_pixar_usd_location%\lib;%PATH% rem Set necessary environment variables for the build process @@ -117,15 +117,15 @@ set PYTHONPATH= ``` Note :
-In my case, I had an issue when rebuilding MayaUsd which was : https://github.com/PixarAnimationStudios/OpenUSD/issues/3310
-So I removed "OpenGL::GL" from the cmake file :
+You may have the following issue when rebuilding MayaUsd: https://github.com/PixarAnimationStudios/OpenUSD/issues/3310
+In this case remove "OpenGL::GL" from the cmake file :
D:/USD-24.11-Python3.10.8/cmake/pxrTargets.cmake
-And when rebuilding MayaUsd, I had to manually add the link to "OpenGL32.lib" to the MayaUsd project under Visual Studio in order to link correctly. +When rebuilding MayaUsd, manually add the link to "OpenGL32.lib" to the MayaUsd project under Visual Studio in order to link correctly. ## Rebuilding MayaHydra -Now you have OpenUSD and MayaUsd rebuilt with the same version of Python as Maya 2024, you can rebuild MayaHydra.
+OpenUSD and MayaUsd are now rebuilt with the same version of Python as Maya 2024. MayaHydra can now be built.
Which under Windows can be made through the follow batch file (adjust it to your custom folders):
``` rem global options to build MayaHydra