From: Alberchou <tun...@ho...> - 2012-05-18 10:03:17
|
Hello again, Summarizing: 1- I did my Ejecutor.i and got my Ejecutor.py and Ejecutor_wrap.cxx by "swig -c++ -python Ejecutor.i" 2- I did a DLL Library project in Dev-C++ including all my c++ project files and Ejecutor_wrap.cxx. 3- I put at Compiler options this command in the compiler line: "-I ..\..\..\python\include" 4- At project options, I put all the python libraries path (..\..\..\python\libs\<lib>) at linker parameters. 5- I compiled and it gaves me an _Ejecutor.dll and a lib_Ejecutor.a 6- I put the path to _Ejecutor.dll in my PATH environment variable. 7- import Ejecutor in my python project. And finally it still gives me the following compiling error: [...] File "C:\Panda3D-1.7.2\samples\PFC\Ejecutor.py", line 26, in <module> _Ejecutor = swig_import_helper() File "C:\Panda3D-1.7.2\samples\PFC\Ejecutor.py", line 18, in swig_import_helper import _Ejecutor ImportError: No module named _Ejecutor What am I doing bad :(?? agurnani wrote: > > In your C++ compile/link line you need to make sure you give the > appropriate > command line arguments to build a DLL and to name the new DLL > _Ejecutor.dll > - and then when you run Python, make sure that DLL is in your PATH. > > > -----Original Message----- > From: Alberchou [mailto:tun...@ho...] > Sent: Thursday, May 17, 2012 6:32 AM > To: swi...@li... > Subject: [Swig-user] Can't get the DLL file > > > Hi everyone, > > I'm using swig between python and c++. I got my wrap file, compiled with > my > c++ project and linked with the python libraries: > > NOTE: I'm using Dev-C++ in Windows, "-I python/include" <- to compile and > linked with "python/libs" > > But I don't get the DLL file and I don't know why. > > Then, when I try to import my Ejecutor.py (this is the extension) to my > Python project, it gives me the following error: > > File "C:\Panda3D-1.7.2\samples\PFC\Ejecutor.py", line 26, in <module> > _Ejecutor = swig_import_helper() > File "C:\Panda3D-1.7.2\samples\PFC\Ejecutor.py", line 18, in > swig_import_helper > import _Ejecutor > ImportError: No module named _Ejecutor > > Could you help me, please? > > Thanks Alot!! > -- > View this message in context: > http://old.nabble.com/Can%27t-get-the-DLL-file-tp33863356p33863356.html > Sent from the swig-user mailing list archive at Nabble.com. > > > ---------------------------------------------------------------------------- > -- > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Swig-user mailing list > Swi...@li... > https://lists.sourceforge.net/lists/listinfo/swig-user > > > ------------------------------------------------------------------------------ > Live Security Virtual Conference > Exclusive live event will cover all the ways today's security and > threat landscape has changed and how IT managers can respond. Discussions > will include endpoint security, mobile security and the latest in malware > threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ > _______________________________________________ > Swig-user mailing list > Swi...@li... > https://lists.sourceforge.net/lists/listinfo/swig-user > > -- View this message in context: http://old.nabble.com/Can%27t-get-the-DLL-file-tp33863356p33869388.html Sent from the swig-user mailing list archive at Nabble.com. |