2007年07月13日 星期五 06:05
¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. ÏÂÃæÊÇDLLµÄ´úÂ룺 #include#include python.hpp> using namespace boost::python; std::string strtmp; char const* Recognise(const char* url) { strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; strtmp+=url; return strtmp.c_str(); } BOOST_PYTHON_MODULE(TestBoost) { def("Recognise", Recognise); } zhangbaocai_cug 2007-07-12 -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/d1538615/attachment.htm
2007年07月12日 星期四 15:24
ÄÇÊÇÒòΪӦ¸ÃÊÇimport TestBoost²Å¶Ô¡£ ¶¯Ì¬Á´½Ó¿âÎļþµÄÃû×Ö±ØÐëºÍBOOST_PYTHON_MODULE(TestBoost)Õâ¸öºê¶¨ÒåµÄÃû×ÖTestBoostÒ»Ö¡£ ÔÚ07-7-13£¬zhangbaocai_cug <zhangbaocai_cug在tom.com> дµÀ£º > > ¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). > PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. > ÏÂÃæÊÇDLLµÄ´úÂ룺 > #include> #include python.hpp> < i>> using namespace boost::python; > > > > std::string strtmp; > char const* Recognise(const char* url) > { > strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; > strtmp+=url; > return strtmp.c_str(); > } > > > BOOST_PYTHON_MODULE(TestBoost) > { > def("Recognise", Recognise); > } > > > ------------------------------ > zhangbaocai_cug > 2007-07-12 > > _______________________________________________ > python-chinese > Post: send python-chinese在lists.python.cn > Subscribe: send subscribe to python-chinese-request在lists.python.cn > Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn > Detail Info: http://python.cn/mailman/listinfo/python-chinese > -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/6e41f841/attachment.htm
2007年07月12日 星期四 15:27
»¶ÓÄã¼ÓÈëµ½boost::pythonÂÛ̳£¬Ïà¹ØÎÊÌâ´ó¼Ò¿ÉÒÔÒ»ÆðÑо¿¡£ http://groups.google.com/group/boostpythoncn?hl=zh-CN ÔÚ07-7-12£¬Li Qingfeng <liqfemail在gmail.com> дµÀ£º > > ÄÇÊÇÒòΪӦ¸ÃÊÇimport TestBoost²Å¶Ô¡£ > ¶¯Ì¬Á´½Ó¿âÎļþµÄÃû×Ö±ØÐëºÍBOOST_PYTHON_MODULE(TestBoost)Õâ¸öºê¶¨ÒåµÄÃû×ÖTestBoostÒ»Ö¡£ > > ÔÚ07-7-13£¬zhangbaocai_cug <zhangbaocai_cug在tom.com> дµÀ£º > > > > ¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). > > PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. > > ÏÂÃæÊÇDLLµÄ´úÂ룺 > > #include> > #include python.hpp> < i>> > using namespace boost::python; > > > > > > > > std::string strtmp; > > char const* Recognise(const char* url) > > { > > strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; > > strtmp+=url; > > return strtmp.c_str(); > > } > > > > > > BOOST_PYTHON_MODULE(TestBoost) > > { > > def("Recognise", Recognise); > > } > > > > > > ------------------------------ > > zhangbaocai_cug > > 2007-07-12 > > > > _______________________________________________ > > python-chinese > > Post: send python-chinese在lists.python.cn > > Subscribe: send subscribe to python-chinese-request在lists.python.cn > > Unsubscribe: send unsubscribe to > > python-chinese-request在lists.python.cn > > Detail Info: http://python.cn/mailman/listinfo/python-chinese > > > > -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/117422b3/attachment-0001.html
2007年07月12日 星期四 15:41
ÎÒ°ÑÄãµÄ´úÂëÔÚ×Ô¼ºµÄµçÄÔÉϱàÒëÖ´ÐÐÁËÒ»±éûÓÐÎÊÌ⣬²»¹ýÎÒÊÇubuntu²Ù×÷ϵͳ£¬±àÒë³É.soÎļþ¡£ ÊDz»ÊÇÒòΪdllÎļþ²»ÔÚpythonµÄpathÏÂÃ棬ÊÔÊÔ°ÑËü·Åµ½ÄãÆô¶¯pythonÃüÁîµÄÎļþ¼ÐÏÂÃæ¡£ ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º > > ÎÒÊÇimport TestBoost Ò²²»¶Ô > IDLE 1.2 > >>> import TestBoost > > Traceback (most recent call last): > File "", line 1, in > import TestBoost > ImportError: No module named TestBoost > >>> > > ------------------------------ > zhangbaocai_cug > 2007-07-12 > ------------------------------ > *·¢¼þÈË£º* Li Qingfeng > *·¢ËÍʱ¼ä£º* 2007-07-12 00:28:04 > *ÊÕ¼þÈË£º* python-chinese在lists.python.cn > *³ËÍ£º* > *Ö÷Ì⣺* Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, > why?ÎÒÓõÄÊÇvc8+python2.5 > > »¶ÓÄã¼ÓÈëµ½boost::pythonÂÛ̳£¬Ïà¹ØÎÊÌâ´ó¼Ò¿ÉÒÔÒ»ÆðÑо¿¡£ > http://groups.google.com/group/boostpythoncn?hl=zh-CN > > ÔÚ07-7-12£¬ Li Qingfeng <liqfemail在gmail.com> дµÀ£º > > > > ÄÇÊÇÒòΪӦ¸ÃÊÇimport TestBoost²Å¶Ô¡£ > > ¶¯Ì¬Á´½Ó¿âÎļþµÄÃû×Ö±ØÐëºÍBOOST_PYTHON_MODULE(TestBoost)Õâ¸öºê¶¨ÒåµÄÃû×ÖTestBoostÒ»Ö¡£ > > > > ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º > > > > > > ¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). > > > PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. > > > ÏÂÃæÊÇDLLµÄ´úÂ룺 > > > #include> > > #include python.hpp> < i>> > > using namespace boost::python; > > > > > > > > > > > > std::string strtmp; > > > char const* Recognise(const char* url) > > > { > > > strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; > > > strtmp+=url; > > > return strtmp.c_str(); > > > } > > > > > > > > > BOOST_PYTHON_MODULE(TestBoost) > > > { > > > def("Recognise", Recognise); > > > } > > > > > > > > > ------------------------------ > > > zhangbaocai_cug > > > 2007-07-12 > > > > > > _______________________________________________ > > > python-chinese > > > Post: send python-chinese在lists.python.cn > > > Subscribe: send subscribe to python-chinese-request在lists.python.cn > > > Unsubscribe: send unsubscribe to > > > python-chinese-request在lists.python.cn > > > Detail Info: http://python.cn/mailman/listinfo/python-chinese > > > > > > > > > _______________________________________________ > python-chinese > Post: send python-chinese在lists.python.cn > Subscribe: send subscribe to python-chinese-request在lists.python.cn > Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn > Detail Info: http://python.cn/mailman/listinfo/python-chinese > -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/aa8e175f/attachment.html
2007年07月12日 星期四 17:12
¹§Ï²Äã¸ã¶¨¡£ ·¢ÏÖÔÚubuntuÏ¿ª·¢ÕæÊÇ·½±ã£¬²½Öè¼òµ¥ºÜ¶à°¡¡£ ÔÚ07-7-13£¬zhangbaocai_cug <zhangbaocai_cug在tom.com> дµÀ£º > > ÕÒµ½´ð°¸ÁË£¬Òª°ÑTestBoost.dll ¸Ä³ÉTestBoost.pyd ¾Í¿ÉÒÔÁË£¬Õæ±ä̬°¡ > ¾ßÌåÇë¿´ÏÂÃæµÄÍøÒ³ > http://www.cppblog.com/jacky2019/archive/2007/06/26/25662.html > > ------------------------------ > zhangbaocai_cug > 2007-07-12 > ------------------------------ > *·¢¼þÈË£º* Li Qingfeng > *·¢ËÍʱ¼ä£º* 2007-07-12 00:41:55 > *ÊÕ¼þÈË£º* python-chinese在lists.python.cn > *³ËÍ£º* > *Ö÷Ì⣺* Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, > why?ÎÒÓõÄÊÇvc8+python2.5 > > ÎÒ°ÑÄãµÄ´úÂëÔÚ×Ô¼ºµÄµçÄÔÉϱàÒëÖ´ÐÐÁËÒ»±éûÓÐÎÊÌ⣬²»¹ýÎÒÊÇubuntu²Ù×÷ϵͳ£¬±àÒë³É.soÎļþ¡£ > ÊDz»ÊÇÒòΪdllÎļþ²»ÔÚpythonµÄpathÏÂÃ棬ÊÔÊÔ°ÑËü·Åµ½ÄãÆô¶¯pythonÃüÁîµÄÎļþ¼ÐÏÂÃæ¡£ > > ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º > > > > ÎÒÊÇimport TestBoost Ò²²»¶Ô > > IDLE 1.2 > > >>> import TestBoost > > > > Traceback (most recent call last): > > File "", line 1, in > > import TestBoost > > ImportError: No module named TestBoost > > >>> > > > > ------------------------------ > > zhangbaocai_cug > > 2007-07-12 > > ------------------------------ > > *·¢¼þÈË£º* Li Qingfeng > > *·¢ËÍʱ¼ä£º* 2007-07-12 00:28:04 > > *ÊÕ¼þÈË£º* python-chinese在lists.python.cn > > *³ËÍ£º* > > *Ö÷Ì⣺* Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, > > why?ÎÒÓõÄÊÇvc8+python2.5 > > > > »¶ÓÄã¼ÓÈëµ½boost::pythonÂÛ̳£¬Ïà¹ØÎÊÌâ´ó¼Ò¿ÉÒÔÒ»ÆðÑо¿¡£ > > http://groups.google.com/group/boostpythoncn?hl=zh-CN > > > > ÔÚ07-7-12£¬ Li Qingfeng <liqfemail在gmail.com> дµÀ£º > > > > > > ÄÇÊÇÒòΪӦ¸ÃÊÇimport TestBoost²Å¶Ô¡£ > > > ¶¯Ì¬Á´½Ó¿âÎļþµÄÃû×Ö±ØÐëºÍBOOST_PYTHON_MODULE(TestBoost)Õâ¸öºê¶¨ÒåµÄÃû×ÖTestBoostÒ»Ö¡£ > > > > > > ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º > > > > > > > > ¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). > > > > PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. > > > > ÏÂÃæÊÇDLLµÄ´úÂ룺 > > > > #include> > > > #include python.hpp> < i>> > > > using namespace boost::python; > > > > > > > > > > > > > > > > std::string strtmp; > > > > char const* Recognise(const char* url) > > > > { > > > > strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; > > > > strtmp+=url; > > > > return strtmp.c_str(); > > > > } > > > > > > > > > > > > BOOST_PYTHON_MODULE(TestBoost) > > > > { > > > > def("Recognise", Recognise); > > > > } > > > > > > > > > > > > ------------------------------ > > > > zhangbaocai_cug > > > > 2007-07-12 > > > > > > > > _______________________________________________ > > > > python-chinese > > > > Post: send python-chinese在lists.python.cn > > > > Subscribe: send subscribe to python-chinese-request在lists.python.cn > > > > Unsubscribe: send unsubscribe to > > > > python-chinese-request在lists.python.cn > > > > Detail Info: http://python.cn/mailman/listinfo/python-chinese > > > > > > > > > > > > > > _______________________________________________ > > python-chinese > > Post: send python-chinese在lists.python.cn > > Subscribe: send subscribe to python-chinese-request在lists.python.cn > > Unsubscribe: send unsubscribe to > > python-chinese-request在lists.python.cn > > Detail Info: http://python.cn/mailman/listinfo/python-chinese > > > > > _______________________________________________ > python-chinese > Post: send python-chinese在lists.python.cn > Subscribe: send subscribe to python-chinese-request在lists.python.cn > Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn > Detail Info: http://python.cn/mailman/listinfo/python-chinese > -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/8fd462ce/attachment-0001.html
2007年07月13日 星期五 06:32
ÎÒÊÇimport TestBoost Ò²²»¶Ô IDLE 1.2 >>> import TestBoost Traceback (most recent call last): File "", line 1, in import TestBoost ImportError: No module named TestBoost >>> zhangbaocai_cug 2007-07-12 ·¢¼þÈË£º Li Qingfeng ·¢ËÍʱ¼ä£º 2007-07-12 00:28:04 ÊÕ¼þÈË£º python-chinese在lists.python.cn ³ËÍ£º Ö÷Ì⣺ Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, why?ÎÒÓõÄÊÇvc8+python2.5 »¶ÓÄã¼ÓÈëµ½boost::pythonÂÛ̳£¬Ïà¹ØÎÊÌâ´ó¼Ò¿ÉÒÔÒ»ÆðÑо¿¡£ http://groups.google.com/group/boostpythoncn?hl=zh-CN ÔÚ07-7-12£¬ Li Qingfeng <liqfemail在gmail.com> дµÀ£º ÄÇÊÇÒòΪӦ¸ÃÊÇimport TestBoost²Å¶Ô¡£ ¶¯Ì¬Á´½Ó¿âÎļþµÄÃû×Ö±ØÐëºÍBOOST_PYTHON_MODULE(TestBoost)Õâ¸öºê¶¨ÒåµÄÃû×ÖTestBoostÒ»Ö¡£ ÔÚ07-7-13£¬zhangbaocai_cug <zhangbaocai_cug在tom.com> дµÀ£º ¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. ÏÂÃæÊÇDLLµÄ´úÂ룺 #include #include python.hpp> using namespace boost::python; std::string strtmp; char const* Recognise(const char* url) { strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; strtmp+=url; return strtmp.c_str(); } BOOST_PYTHON_MODULE(TestBoost) { def("Recognise", Recognise); } zhangbaocai_cug 2007-07-12 _______________________________________________ python-chinese Post: send python-chinese在lists.python.cn Subscribe: send subscribe to python-chinese-request在lists.python.cn Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn Detail Info: http://python.cn/mailman/listinfo/python-chinese -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/a81f9453/attachment.htm
2007年07月13日 星期五 06:51
ÎÒµÄÊÇÔÚwindowsÏÂÃ棬pathÒѾÉè¹ýÁË£¬ÓÃdepends²é¿´ÁËÒ»°ÑËùÓеÄÒÀÀµ¿â¶¼ÓУ¬¶øÇÒinitTestBoostº¯ÊýÒ²ÊÇC·ç¸ñµÄ£¬ÓÃpython2.4±àÒëµÄ¿ÉÒÔµ¼È룬µ«ÓÃpython2.5¾Í²»¿ÉÒÔ£¬ÄѵÀÊÇbug£¿ ¿½±´µ½pythonĿ¼ÏÂÒ²²»¿ÉÒÔ zhangbaocai_cug 2007-07-12 ·¢¼þÈË£º Li Qingfeng ·¢ËÍʱ¼ä£º 2007-07-12 00:41:55 ÊÕ¼þÈË£º python-chinese在lists.python.cn ³ËÍ£º Ö÷Ì⣺ Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, why?ÎÒÓõÄÊÇvc8+python2.5 ÎÒ°ÑÄãµÄ´úÂëÔÚ×Ô¼ºµÄµçÄÔÉϱàÒëÖ´ÐÐÁËÒ»±éûÓÐÎÊÌ⣬²»¹ýÎÒÊÇubuntu²Ù×÷ϵͳ£¬±àÒë³É.soÎļþ¡£ ÊDz»ÊÇÒòΪdllÎļþ²»ÔÚpythonµÄpathÏÂÃ棬ÊÔÊÔ°ÑËü·Åµ½ÄãÆô¶¯pythonÃüÁîµÄÎļþ¼ÐÏÂÃæ¡£ ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º ÎÒÊÇimport TestBoost Ò²²»¶Ô IDLE 1.2 >>> import TestBoost Traceback (most recent call last): File "", line 1, in import TestBoost ImportError: No module named TestBoost >>> zhangbaocai_cug 2007-07-12 ·¢¼þÈË£º Li Qingfeng ·¢ËÍʱ¼ä£º 2007-07-12 00:28:04 ÊÕ¼þÈË£º python-chinese在lists.python.cn ³ËÍ£º Ö÷Ì⣺ Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, why?ÎÒÓõÄÊÇvc8+python2.5 »¶ÓÄã¼ÓÈëµ½boost::pythonÂÛ̳£¬Ïà¹ØÎÊÌâ´ó¼Ò¿ÉÒÔÒ»ÆðÑо¿¡£ http://groups.google.com/group/boostpythoncn?hl=zh-CN ÔÚ07-7-12£¬ Li Qingfeng <liqfemail在gmail.com> дµÀ£º ÄÇÊÇÒòΪӦ¸ÃÊÇimport TestBoost²Å¶Ô¡£ ¶¯Ì¬Á´½Ó¿âÎļþµÄÃû×Ö±ØÐëºÍBOOST_PYTHON_MODULE(TestBoost)Õâ¸öºê¶¨ÒåµÄÃû×ÖTestBoostÒ»Ö¡£ ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º ¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. ÏÂÃæÊÇDLLµÄ´úÂ룺 #include #include python.hpp> using namespace boost::python; std::string strtmp; char const* Recognise(const char* url) { strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; strtmp+=url; return strtmp.c_str(); } BOOST_PYTHON_MODULE(TestBoost) { def("Recognise", Recognise); } zhangbaocai_cug 2007-07-12 _______________________________________________ python-chinese Post: send python-chinese在lists.python.cn Subscribe: send subscribe to python-chinese-request在lists.python.cn Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn Detail Info: http://python.cn/mailman/listinfo/python-chinese _______________________________________________ python-chinese Post: send python-chinese在lists.python.cn Subscribe: send subscribe to python-chinese-request在lists.python.cn Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn Detail Info: http://python.cn/mailman/listinfo/python-chinese -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/f0bbe2f9/attachment-0001.htm
2007年07月13日 星期五 07:42
ÕÒµ½´ð°¸ÁË£¬Òª°ÑTestBoost.dll ¸Ä³ÉTestBoost.pyd ¾Í¿ÉÒÔÁË£¬Õæ±ä̬°¡ ¾ßÌåÇë¿´ÏÂÃæµÄÍøÒ³ http://www.cppblog.com/jacky2019/archive/2007/06/26/25662.html zhangbaocai_cug 2007-07-12 ·¢¼þÈË£º Li Qingfeng ·¢ËÍʱ¼ä£º 2007-07-12 00:41:55 ÊÕ¼þÈË£º python-chinese在lists.python.cn ³ËÍ£º Ö÷Ì⣺ Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, why?ÎÒÓõÄÊÇvc8+python2.5 ÎÒ°ÑÄãµÄ´úÂëÔÚ×Ô¼ºµÄµçÄÔÉϱàÒëÖ´ÐÐÁËÒ»±éûÓÐÎÊÌ⣬²»¹ýÎÒÊÇubuntu²Ù×÷ϵͳ£¬±àÒë³É.soÎļþ¡£ ÊDz»ÊÇÒòΪdllÎļþ²»ÔÚpythonµÄpathÏÂÃ棬ÊÔÊÔ°ÑËü·Åµ½ÄãÆô¶¯pythonÃüÁîµÄÎļþ¼ÐÏÂÃæ¡£ ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º ÎÒÊÇimport TestBoost Ò²²»¶Ô IDLE 1.2 >>> import TestBoost Traceback (most recent call last): File "", line 1, in import TestBoost ImportError: No module named TestBoost >>> zhangbaocai_cug 2007-07-12 ·¢¼þÈË£º Li Qingfeng ·¢ËÍʱ¼ä£º 2007-07-12 00:28:04 ÊÕ¼þÈË£º python-chinese在lists.python.cn ³ËÍ£º Ö÷Ì⣺ Re: [python-chinese]boost::pythonÉú³ÉµÄ*.dllÎļþ²»ÄÜimport, why?ÎÒÓõÄÊÇvc8+python2.5 »¶ÓÄã¼ÓÈëµ½boost::pythonÂÛ̳£¬Ïà¹ØÎÊÌâ´ó¼Ò¿ÉÒÔÒ»ÆðÑо¿¡£ http://groups.google.com/group/boostpythoncn?hl=zh-CN ÔÚ07-7-12£¬ Li Qingfeng <liqfemail在gmail.com> дµÀ£º ÄÇÊÇÒòΪӦ¸ÃÊÇimport TestBoost²Å¶Ô¡£ ¶¯Ì¬Á´½Ó¿âÎļþµÄÃû×Ö±ØÐëºÍBOOST_PYTHON_MODULE(TestBoost)Õâ¸öºê¶¨ÒåµÄÃû×ÖTestBoostÒ»Ö¡£ ÔÚ07-7-13£¬zhangbaocai_cug < zhangbaocai_cug在tom.com> дµÀ£º ¿ÉÊÇÓÃboost::pythonÉú³ÉµÄ*.dllÎļþÈ´ÓÖ²»ÄÜimportÁË(IDLEºÍc++ÀïÃæimport¶¼Ê§°Ü). PS:ÎÒ¶¼ÊÇÓÃrelease°æ±¾µÄ. ÏÂÃæÊÇDLLµÄ´úÂ룺 #include #include python.hpp> using namespace boost::python; std::string strtmp; char const* Recognise(const char* url) { strtmp ="´ÓdllÖзµ»ØµÄÊý¾Ý... : "; strtmp+=url; return strtmp.c_str(); } BOOST_PYTHON_MODULE(TestBoost) { def("Recognise", Recognise); } zhangbaocai_cug 2007-07-12 _______________________________________________ python-chinese Post: send python-chinese在lists.python.cn Subscribe: send subscribe to python-chinese-request在lists.python.cn Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn Detail Info: http://python.cn/mailman/listinfo/python-chinese _______________________________________________ python-chinese Post: send python-chinese在lists.python.cn Subscribe: send subscribe to python-chinese-request在lists.python.cn Unsubscribe: send unsubscribe to python-chinese-request在lists.python.cn Detail Info: http://python.cn/mailman/listinfo/python-chinese -------------- 下一部分 -------------- Ò»¸öHTML¸½¼þ±»ÒƳý... URL: http://python.cn/pipermail/python-chinese/attachments/20070712/31e99c14/attachment-0001.html
Zeuux © 2025
京ICP备05028076号