pyOCIO Windows compilation error against Python36
renau...@...
I downloaded the latest OCIO code from GitHub (1.1.0) and I was able to compile OCIO using "Visual Studio 2015" as-well as pyOpenColorIO against Python27. However when I tried to compile it against Python36 I get the following error:
Line 153 points to this :
MOD_INIT definition looks like this: pyMain.cpp
pyMODINIT_FUNC is defined here: PyUtil.h
and EXPORT_SYMBOL here: PyUtil.h
I checked online to see if I could figure out what's causing the issue but I couldn't figure it out. Anybody would know why this is happening ? Was anyone able to compile OCIO 1.1.0 | Win64 | Visual Studio 2015 | Python36 (official 64 bit build) ? Thanks. |
|
Richard Shaw <hobbe...@...>
On Sun, Jan 27, 2019 at 12:05 AM <renau...@...> wrote:
My guess is that it hasn't been updated for Python3 yet... There are some incompatible changes. You can try a converter and see if it takes care of the errors but beware any unintended side effects... Thanks, Richard |
|
Patrick Hodoul <patric...@...>
Hi Guys,
Thanks for your investigations around Python 3.
OCIO does not currently support Python 3. But it would be appreciated to have a pull request fixing the Python 3 support :-)
Patrick. On Sunday, January 27, 2019 at 1:04:35 PM UTC-5, Richard wrote:
|
|
Richard Shaw <hobbe...@...>
I had completely forgotten that I moved the Fedora package over to Python 3.7 and haven't had any build issues... Now that being said I don't know if there's any consumers of the python library in Fedora... Feel free to poke around the build logs... Here's the spec file for building... Some of it won't make sense to you but you can review the settings / cmake options I use. Thanks, Richard |
|
Renaud Talon <renau...@...>
Hi Richard,
Thank you for your suggestions, I did look into your diff files but I couldn’t find anything that’s not already added to the current versions of the files. I got it to compile with Windows 10 / Python 3.6 – Visual Studio 2015, by changing the following line in “pyUtil.h” (line 65): from : #define MOD_INIT(name) PyMODINIT_FUNC EXPORT_SYMBOL PyInit_##name(void)
to: #define MOD_INIT(name) EXPORT_SYMBOL PyMODINIT_FUNC PyInit_##name(void)
I did get a warning message though but the compilation process went through and the “.pyd” file was generated. I’m honestly no C++ expert so I’m not sure if this makes sense but it seems to work. I need to run further testing next week to confirm but so far so good.
Thanks again, Renaud
From: ocio...@... <oc...@...> on behalf of Richard Shaw <hob...@...>
Sent: Monday, February 4, 2019 8:45:08 AM To: ocio...@... Subject: Re: [ocio-dev] pyOCIO Windows compilation error against Python36 I had completely forgotten that I moved the Fedora package over to Python 3.7 and haven't had any build issues... Now that being said I don't know if there's any consumers of the python library in Fedora...
Feel free to poke around the build logs...
Here's the spec file for building... Some of it won't make sense to you but you can review the settings / cmake options I use.
Thanks,
Richard
You received this message because you are subscribed to the Google Groups "OpenColorIO Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to ocio-dev+unsu...@.... For more options, visit https://groups.google.com/d/optout. |
|
renaudtalon@...
Sorry for re-opening this so late. I did test the fix I thought work among other few things but I can't get OCIO to work with Python 3+ on Windows.
I tested with both OCIO 1.1 and OCIO 2.0 (master branch) and I can't compile against Python3. Any news on when this will be supported ? Thank you. |
|
Michael Dolan
I'm currently writing new Python bindings for OCIO (with pybind11, targeting the 2.0 release), which will support Python 3 (and 2). Stills a ways to go, but it's in the works. On Wed, Oct 23, 2019 at 1:01 PM <renaudtalon@...> wrote: Sorry for re-opening this so late. I did test the fix I thought work among other few things but I can't get OCIO to work with Python 3+ on Windows. |
|
renaudtalon@...
That's great news, thank you !
|
|