# Debug build not working

**URL:** <https://forum.aousd.org/t/debug-build-not-working/2384>\
**Category:** Build and Deployment\
**Tags:** beginner\
**Created:** [April 18, 2025, 7:12am UTC](https://forum.aousd.org/t/debug-build-not-working/2384 "2025-04-18T07:12:40Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 18, 2025, 7:12am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/1 "2025-04-18T07:12:40Z")

</div>

I am trying to get my debug version of my C++ to work with OpenUSD. I have made a release build of OpenUSD and that works in release mode in my project but in debug it does not work. I looked around and came to the conclusion that I should make a debug build of OpenUSD. When I tried to make the debug build, I got the error below.

 ![image](https://us1.discourse-cdn.com/flex016/uploads/aousd/original/1X/88d36ed26432284fecbcde5576210e021471a486.png)

Any idea what I might be doing wrong? Do I need to make a debug build at all?

---

<div class="post-metadata">

**Author:** ![dhruvgovil](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.aousd.org/dhruvgovil/32/3_2.png) [@dhruvgovil](https://forum.aousd.org/u/dhruvgovil)\
**Post date:** [April 18, 2025, 7:31am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/2 "2025-04-18T07:31:36Z")

</div>

To debug , you definitely need debug symbols which means either building in debug or release with debug.

Could you share more about how you’re building, the command you run, the Python version etc that you’re using?

---

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 22, 2025, 4:11am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/3 "2025-04-22T04:11:27Z")

</div>

![image](https://us1.discourse-cdn.com/flex016/uploads/aousd/original/1X/6480b36dc4ef560e3d8535089f5b43b22229328e.png)  
I am building the project using visual studio 2019. As for building the debug version of Open USD I am using the build\_usd.py script and I ran the following in command prompt. (I left in the visual studio errors in case anyone wanted to see some of those.) I am using Python 3.12.1.

---

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 22, 2025, 4:12am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/4 "2025-04-22T04:12:22Z")

</div>

![image](https://us1.discourse-cdn.com/flex016/uploads/aousd/original/1X/eda36b6721d8e42b186ff592bf8f8efbb778f772.png)  
Better screenshot of the command I used

---

<div class="post-metadata">

**Author:** ![dhruvgovil](https://sea2.discourse-cdn.com/flex016/user_avatar/forum.aousd.org/dhruvgovil/32/3_2.png) [@dhruvgovil](https://forum.aousd.org/u/dhruvgovil)\
**Post date:** [April 22, 2025, 1:33pm UTC](https://forum.aousd.org/t/debug-build-not-working/2384/5 "2025-04-22T13:33:17Z")

</div>

It’s quite difficult to parse screenshots. Would you be able to post the text or actual log files going forward?

In this case, both your original and new screenshot show different issues so it’s hard to find a theme based on what’s presented. I would recommend deleting your build folder, and doing a fresh build to make sure there are no conflicts, and then posting the build logs once done.

It would also help to know what version of OpenUSD you are building just to make sure it’s recent.

OpenUSD 25.5 just released a release candidate as well, and might help resolve some build issues potentially.

---

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 24, 2025, 3:43am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/6 "2025-04-24T03:43:30Z")

</div>

[log.txt](https://forum.aousd.org/uploads/short-url/gVBgM7O3x2u5W3VYFmvSZu0P2TI.txt) (636 Bytes)  
Here is the log file for the build errors. I wont try to send anything related to my project build since it is now clear that it is distracting and will likely be fixed by having the debug versions of OpenUSD files. I am going to make a fresh build now and post the results.

---

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 24, 2025, 4:09am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/7 "2025-04-24T04:09:24Z")

</div>

[log.txt](https://forum.aousd.org/uploads/short-url/rAHh4zBxFVh1gvp0GFiNMrfBkxv.txt) (368 Bytes)  
Attempted a fresh build but it couldnt download the boost files. I got around this when I build the first time by downloading the files manually. I didn’t do that this time. The version I am working with is 24.8

---

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 26, 2025, 8:59pm UTC](https://forum.aousd.org/t/debug-build-not-working/2384/8 "2025-04-26T20:59:00Z")

</div>

Doing more reserach, I found out I had the issue described here: [Failed to extract archive boost\_1\_78\_0.zip · Issue #2900 · PixarAnimationStudios/OpenUSD · GitHub](https://github.com/PixarAnimationStudios/OpenUSD/issues/2900). I did the recommended fix (switching the URL to download boost with something that is up right now) and that fixed part of it. I now have a new issue, which is one of the numpy files wont compile. Here is the exact error:

compile-c-c++ C:\Users\donov\Desktop\OpenUSD-Folder\OpenUSD-release\OpenUSD-debug\build\boost\bin.v2\libs\python\build\msvc-14.2\debug\python-3.12\threading-multi\numpy\dtype.obj  
dtype.cpp  
libs\python\src\numpy\dtype.cpp(101): error C2039: ‘elsize’: is not a member of ‘\_PyArray\_Descr’  
C:\Users\donov\AppData\Local\Programs\Python\Python312\Lib\site-packages\numpy\_core\include\numpy\ndarraytypes.h(622): note: see declaration of ‘\_PyArray\_Descr’

```
call "C:\Users\donov\Desktop\OpenUSD-Folder\OpenUSD-release\OpenUSD-debug\build\boost\bin.v2\standalone\msvc\msvc-14.2\msvc-setup.bat" >nul

```

cl /Zm800 -nologo “libs\python\src\numpy\dtype.cpp” -c -Fo"C:\Users\donov\Desktop\OpenUSD-Folder\OpenUSD-release\OpenUSD-debug\build\boost\bin.v2\libs\python\build\msvc-14.2\debug\python-3.12\threading-multi\numpy\dtype.obj" -TP /wd4675 /EHs /GR /Zc:throwingNew /Z7 /Od /Ob0 /W3 /MDd /Zc:forScope /Zc:wchar\_t /Zc:inline /favor:blend -DBOOST\_ALL\_NO\_LIB=1 -DBOOST\_NUMPY\_SOURCE “-I.” “-IC:\Users\donov\AppData\Local\Programs\Python\Python312\Include” “-IC:\Users\donov\AppData\Local\Programs\Python\Python312\Lib\site-packages\numpy\_core\include”

…failed compile-c-c++ C:\Users\donov\Desktop\OpenUSD-Folder\OpenUSD-release\OpenUSD-debug\build\boost\bin.v2\libs\python\build\msvc-14.2\debug\python-3.12\threading-multi\numpy\dtype.obj…

I have also attached the build log below. I will keep trying to fix this in the meantime and update any results here.  
[log.txt](https://forum.aousd.org/uploads/short-url/l60AQpJ7sJxkYNuhTivucsyvWDx.txt) (4.4 MB)

---

<div class="post-metadata">

**Author:** ![benmalartre](https://avatars.discourse-cdn.com/v4/letter/b/c2a13f/32.png) [@benmalartre](https://forum.aousd.org/u/benmalartre)\
**Post date:** [April 28, 2025, 1:29pm UTC](https://forum.aousd.org/t/debug-build-not-working/2384/9 "2025-04-28T13:29:51Z")

</div>

looks like the file  
pxr\external\boost\python\numpy\dtype.hpp is malformed  
you should try delete boost folder inside usd\_build/src and try again

---

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 30, 2025, 5:43am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/10 "2025-04-30T05:43:06Z")

</div>

I tried doing the above and deleting the boost folder from the debug build folder and that didn’t work. I deleted the include folder and than the boost folder again and that didn’t work ether. Looking to the error more, it looks like is a version conflict here where the version USD is expecting is not the same as the version being built. That is weird though because it should be getting the right version. Going to figure out if I am downloading the right version of boost. (I have the log of the latest attempt but it is the same as the one before essentially)  
[log.txt](https://forum.aousd.org/uploads/short-url/cJ1UYP2OIfvw18zhm1XTxWxzpvh.txt) (351 Bytes)

Edit: Here are the links which lead me to the conclusion above:

- [Error: ‘PyArray\_Descr’ has no member named ‘elsize’ - PyTorch Forums](https://discuss.pytorch.org/t/error-pyarray-descr-has-no-member-named-elsize/213726)
- [NumPy 2.0 migration guide — NumPy v2.2 Manual](https://numpy.org/doc/stable//numpy_2_0_migration_guide.html)

Since there is a change in how PyArray\_Descr is organized between versions, it would make sense then that if the versions are being mixed, that is where the error would come from.

---

<div class="post-metadata">

**Author:** ![DonovanWestwater](https://avatars.discourse-cdn.com/v4/letter/d/eb8c5e/32.png) [@DonovanWestwater](https://forum.aousd.org/u/DonovanWestwater)\
**Post date:** [April 30, 2025, 6:32am UTC](https://forum.aousd.org/t/debug-build-not-working/2384/11 "2025-04-30T06:32:03Z")

</div>

I downgraded my numpy version from 2.2.2 to 1.26.4 and that has seemed to have fixed the build errors with boost. I was able to generate a successful debug build after that. Now I can take these files and use them to get my debug build working for my project. Going to mark this as solved since I now know that I need a debug version of OpenUSD for debug builds and I have been able to fix the issues I was having with generating my debug build. Thank you to everyone who helped me.
