[omniORB] EXT : Trying 4.1.7 on Visual Studio 12

James Kulp jek at parera.com
Sun Nov 3 16:52:23 GMT 2013


Thanks for feedback.
I installed the 2.7.5 MSI  for x86_64 from the python site.
My windows 7 system in 64 bit, confirmed in the control panel.
There doesn't appear to be any 64 bit specific configuration in omniorb.
Python headers look for #ifdef _WIN64, but I notice that the VS12 
compiler does not set this.
(but this probably does not relate to the problem at hand).
It looks like the compiled omniidl files are referencing dll symbols 
(__imp__).
Using dumpbin /all on python27.lib, it shows, e.g., a symbol:
__imp_PyType_IsSubType
(note single underscore after "imp")

Where as the undefined in the error message is:

idlpython.o : error LNK2019: unresolved external symbol __imp__PyType_IsSubtype referenced in function _IdlPyCompile


Which is double underscore after the "imp"??





On 11/2/13 5:25 PM, Obermaier, Stephen J (IS) wrote:
> Hi James -
>
> The first question is your machine target (X64 or win32).  Based on your target (64-bit or 32-bit) you need to link with the appropriate Python dlls.  There are both a 64-bit and 32-bit versions of Python, and you must download the correct version of python to support the build.  You can have both Python implementations coexist on the same machine, but you have to set up some specific environment variables to do this (PYTHONPATH, PYTHONHOME).
>
> The other issue I ran into when building VS2012 is that the make veryclean does not purge all the pdb files in the debug directories (codesets, dynamic, connections and orbcore) so you must explicitly delete these or a VC12 build will fail (if you are building the debug dlls).
>
>
> Good luck,
>
> Steve Obermaier
>
>
>
> -----Original Message-----
> From: James Kulp [mailto:jek at parera.com]
> Sent: Saturday, November 02, 2013 3:57 PM
> To: omniorb-list at omniorb-support.com
> Subject: EXT :[omniORB] Trying 4.1.7 on Visual Studio 12
>
> I figured I would give this a try on WIndows 7 and Visual Studio 12.0 (2013). (setting the platform to vs10).
>
> There is some sort of python library issue (below).
> The symbols in question are in the python27.lib which is referenced on the link line, but not with the __imp__ prefix.
> (using dumpbin /exports).
> I'm no WIndows or Python expert at all.  I tried two different precompiled python packages for windows, with the same error.
> I have not yet tried building python from source on VS12.
> I did notice that several of the "libpath" entries point to places that don't exist in python2.7, like "python27\lib\x86_win32" and "python27\PCBuild".
>
> Any ideas?
>
> Here are the errors:
> link -out:omniidl.exe -nologo -manifest -DEBUG -libpath:c:\python27\libs
> -libpath:c:\python27\lib\x86_win32 -libpath:c:\python27\PCbuild -PDB:omniidl.exe.pdb -libpath:..\..\..\..\lib\x86_win32 y.tab.o lex.yy.o idlerr.o idlutil.o idltype.o idlrepoId.o idlscope.o idlexpr.o idlast.o idlvalidate.o idldump.o idlconfig.o idlfixed.o idlpython.o python27.lib
>      Creating library omniidl.lib and object omniidl.exp idlpython.o : error LNK2019: unresolved external symbol __imp__PyType_IsSubtype referenced in function _IdlPyCompile idlpython.o : error LNK2019: unresolved external symbol __imp__PyObject_SetAttrString referenced in function _init_omniidl idlpython.o : error LNK2019: unresolved external symbol __imp__PyInt_FromLong referenced in function _IdlPyAlwaysTempFile idlpython.o : error LNK2019: unresolved external symbol __imp__PyLong_FromUnsignedLong referenced in function "public: virtual void __thiscall PythonVisitor::visitCaseLabel(class CaseLabel *)"
> (?visitCaseLabel at PythonVisitor@@UAEXPAVCaseLabel@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol __imp__PyLong_FromLongLong referenced in function "public: virtual void __thiscall PythonVisitor::visitCaseLabel(class CaseLabel *)"
> (?visitCaseLabel at PythonVisitor@@UAEXPAVCaseLabel@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol __imp__PyLong_FromUnsignedLongLong referenced in function "public:
> virtual void __thiscall PythonVisitor::visitCaseLabel(class CaseLabel *)" (?visitCaseLabel at PythonVisitor@@UAEXPAVCaseLabel@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol __imp__PyFloat_FromDouble referenced in function "public: virtual void __thiscall PythonVisitor::visitConst(class Const *)"
> (?visitConst at PythonVisitor@@UAEXPAVConst@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol __imp__PyString_FromString referenced in function _IdlPyPlatformDefines idlpython.o : error LNK2019: unresolved external symbol __imp__PyString_AsString referenced in function _IdlPyCompile idlpython.o : error LNK2019: unresolved external symbol __imp__PyList_New referenced in function _IdlPyPlatformDefines idlpython.o : error LNK2019: unresolved external symbol __imp__PyList_GetItem referenced in function "public: virtual void __thiscall PythonVisitor::visitTypedef(class Typedef *)"
> (?visitTypedef at PythonVisitor@@UAEXPAVTypedef@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol __imp__PyList_SetItem referenced in function "private: struct _object * __thiscall PythonVisitor::commentsToList(class Comment const *)"
> (?commentsToList at PythonVisitor@@AAEPAU_object@@PBVComment@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol __imp__PyList_Insert referenced in function _IdlPyRelativeScopedName idlpython.o : error LNK2019: unresolved external symbol __imp__PyList_Append referenced in function _IdlPyPlatformDefines idlpython.o : error LNK2019: unresolved external symbol __imp__PyFile_AsFile referenced in function _IdlPyCompile idlpython.o : error LNK2019: unresolved external symbol __imp__PyFile_Name referenced in function _IdlPyCompile idlpython.o : error LNK2019: unresolved external symbol __imp__PyErr_SetString referenced in function _IdlPyCompile idlpython.o : error LNK2019: unresolved external symbol __imp__PyArg_ParseTuple referenced in function _IdlPyCompile idlpython.o : error LNK2019: unresolved external symbol __imp__Py_BuildValue referenced in function "public: virtual void __thiscall PythonVisitor::visitCaseLabel(class CaseLabel *)"
> (?visitCaseLabel at PythonVisitor@@UAEXPAVCaseLabel@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol
> __imp__Py_InitModule4 referenced in function _init_omniidl idlpython.o : error LNK2019: unresolved external symbol __imp__Py_Initialize referenced in function _main idlpython.o : error LNK2019: unresolved external symbol __imp__PyRun_SimpleStringFlags referenced in function _main idlpython.o : error LNK2019: unresolved external symbol __imp__PyRun_InteractiveLoopFlags referenced in function _IdlPyRunInteractiveLoop idlpython.o : error LNK2019: unresolved external symbol __imp__PyErr_Print referenced in function "public: __thiscall PythonVisitor::PythonVisitor(void)" (??0PythonVisitor@@QAE at XZ) idlpython.o : error LNK2019: unresolved external symbol __imp__PySys_SetArgv referenced in function _main idlpython.o : error LNK2019: unresolved external symbol __imp__PyImport_ImportModule referenced in function "public: __thiscall PythonVisitor::PythonVisitor(void)" (??0PythonVisitor@@QAE at XZ) idlpython.o : error LNK2019: unresolved external symbol __imp__PyObject_CallMethod referenced in function "private: struct _object * __thiscall PythonVisitor::commentsToList(class Comment const *)" (?commentsToList at PythonVisitor@@AAEPAU_object@@PBVComment@@@Z)
> idlpython.o : error LNK2019: unresolved external symbol __imp__PyObject_Size referenced in function _IdlPyRelativeScopedName idlpython.o : error LNK2019: unresolved external symbol __imp__PySequence_Check referenced in function _IdlPyRelativeScopedName idlpython.o : error LNK2019: unresolved external symbol __imp__PySequence_GetItem referenced in function _IdlPyRelativeScopedName idlpython.o : error LNK2001: unresolved external symbol __imp___Py_NoneStruct idlpython.o : error LNK2001: unresolved external symbol __imp__PyFile_Type idlpython.o : error LNK2001: unresolved external symbol __imp__PyExc_IOError idlpython.o : error LNK2001: unresolved external symbol __imp__PyExc_TypeError omniidl.exe : fatal error LNK1120: 34 unresolved externals
>
>
>
> _______________________________________________
> omniORB-list mailing list
> omniORB-list at omniorb-support.com
> http://www.omniorb-support.com/mailman/listinfo/omniorb-list





More information about the omniORB-list mailing list