Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

hmm, i think, i found it. (getting the same err on 32bit/xp)

btw, "Of course, this works only for Windows." --> this is only about windows. no

the other modules define CVAPI_EXPORTS (look above, how it's used), so CV_EXPORTS evaluates to __declspec(dllexport)

the python module does not define CVAPI_EXPORTS, but opencv_python_EXPORTS instead, so the preprocessor misses it, and cvinit() does not end up in the symboltable. ( --> "ImportError: dynamic module does not define init function (initcv2)")

looks like some cmake-related bug to me.

hmm, i think, i found it. (getting the same err on 32bit/xp)

btw, "Of course, this works only for Windows." --> this is only about windows. no need to worry about other users

the other modules define CVAPI_EXPORTS (look above, how it's used), so CV_EXPORTS evaluates to __declspec(dllexport)

the python module does not define CVAPI_EXPORTS, but opencv_python_EXPORTS instead, so the preprocessor misses it, and cvinit() does not end up in the symboltable. ( --> "ImportError: dynamic module does not define init function (initcv2)")

my fix was, to change the malformed opencv_python_EXPORTS to CVAPI_EXPORTS in the preprocessor settings, but that's only marginally better that your solution

looks like some cmake-related bug to me.me, and it should be fixed there.

hmm, i think, i found it. (getting the same err on 32bit/xp)

btw, "Of course, this works only for Windows." --> this is only about windows. no need to worry about other users

the other modules define CVAPI_EXPORTS (look above, how it's used), so CV_EXPORTS evaluates to __declspec(dllexport)

the python module does not define CVAPI_EXPORTS, but opencv_python_EXPORTS instead, so the preprocessor misses it, and cvinit() does not end up in the symboltable. ( --> "ImportError: dynamic module does not define init function (initcv2)")

my fix was, to change the malformed opencv_python_EXPORTS to CVAPI_EXPORTS in the preprocessor settings, but that's only marginally better that your solution

looks like some cmake-related bug to me, and it should be fixed there.


(sidenote, size of cv2.pyd changed from 894kb(built march,23) to 1261kb(now). whoa what might be in there ?