473,587 Members | 2,527 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Embed+extend+po rt

Vio
My story: I played with a little embedded python
piece of code (python interpreter embedded in wxWidgets app),
and used SWIG to extend this embedded py interpreter.
I did it in Linux, after some ironing all builds and runs as expected.

On a particularily lazy day, I pasted these same wrapper sources to
Win32 (cygnus). After fiddling with the Makefile to point in the right
directions, compilation seems to go ok (give or take a couple of
warnings). But then the linking step chokes with unfriendly messages
like "undefined reference to _PyExit, _Py_Initialize, etc.".

Could someone tell me what this mean? My guess is that my linker is not
pointed at the right Python library, but could someone confirm/rebute
this? I'm pointing the linker (on win32) to -L"/Python23/libs" where
lives "python23.l ib", as presumably I need an equivalent to Linux's
"/usr/local/lib/python2.3/config/libpython2.3.a" , so I'm wondering if
I'm pointing at the right place on the win32 side, or even if I'd need
to compile Python on win32 (currently using some precompiled distro on
win32, while I recompiled Py on Linux). In other words, I'd like to do
all my development on Linux, and not have to redo the work on win32
(besides some cut&paste). If I sound like a win32 newbie, well, I also
like like one:)

Cheers,
Vio

PS I just read on the list some comments that wxWidgets+Pytho n mix is
kinda slow. Bummer.

Jul 18 '05 #1
1 1591
Vio <vm*******@symp atico.ca> wrote in
news:ma******** *************** *************** @python.org:
My story: I played with a little embedded python
piece of code (python interpreter embedded in wxWidgets app),
and used SWIG to extend this embedded py interpreter.
I did it in Linux, after some ironing all builds and runs as expected.
why someone would embedd a python interpreter but write the gui code some
some other language escapes me, but well ;-)
On a particularily lazy day, I pasted these same wrapper sources to
Win32 (cygnus). After fiddling with the Makefile to point in the right
directions, compilation seems to go ok (give or take a couple of
warnings). But then the linking step chokes with unfriendly messages
like "undefined reference to _PyExit, _Py_Initialize, etc.".

Could someone tell me what this mean? My guess is that my linker is not
pointed at the right Python library,
right. you need to create an import lib for gcc. thats done with pexports
and dlltool:

http://docs.python.org/inst/tweak-fl...00000000000000

also remember to use -mno-cygwin for gcc if you want to make native win32
apps with cygwin.
PS I just read on the list some comments that wxWidgets+Pytho n mix is
kinda slow. Bummer.


is it too slow for _you_?
there are always people that say something is slow, even if it isn't
relevant in real world applications...

chris

--
Chris <cl******@gmx.n et>

Jul 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
13336
matheussousuke
by: matheussousuke | last post by:
Hello, I'm using tiny MCE plugin on my oscommerce and it is inserting my website URL when I use insert image function in the emails. The goal is: Make it send the email with the URL http://mghospedagem.com/images/controlpanel.jpg instead of http://mghospedagem.comhttp://mghospedagem.com/images/controlpanel.jpg As u see, there's the...
0
7918
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
8206
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8340
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
0
8220
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6621
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5713
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3840
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3875
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1452
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.