Python extension compatibility

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Philippe C. Martin

    #1

    Python extension compatibility

    Hi,

    *** QUICK BACKGROUND ***
    -)I have been working with pycsc.c in which I made a few modifications.
    -)When I had it working un linux - I attempted to port it to Windows
    -) I read a lot, downloaded mingwin and had pexports crash when I attempted to
    get the .def out of winscard.dll
    -) I then attempted to create the .def by hand with no luck
    -) I read some more and decided I would have ess problems with Visual
    Studio .NET (sigh) - so I broked down and invested
    -) the setup.py failed on python 2.3 because V6 was required
    -) I read there was a patch but also that the laster 2.4B was compiled with VS
    7.1 (which I assumed meant .NET)
    -) Downloaded it, everyting compiled and linked fine - had to copy the files
    by hand to the right locations and everyting worked great.
    *************** *************** *********
    Now for the question:

    Since pycsc does not use any brand new Python functionality, are the binaries
    be compatible with earlier versions of Python ? down to which ?


    Regards,

    Philippe
  • Scott David Daniels

    #2
    Re: Python extension compatibility

    Philippe C. Martin wrote:[color=blue]
    > Since pycsc does not use any brand new Python functionality, are the binaries
    > be compatible with earlier versions of Python ? down to which ?[/color]
    Binaries are compatible down to major.minor versions.
    That is 2.3.4 works with 2.3.1 and so on. Nothing you build with 2.4
    will work (pass the initial setup test) across major.minor versions.

    In addition to Python sometimes making incompatible changes, Microsoft
    changes the runtime library interface (and in some cases even the C
    function call interface for compiled code) for each version of their
    compiler. Since python 2.3 down (to at least 2.1) uses VC 6, your 2.4
    stuff (compiled with 7.1) wouldn't work even if Python didn't try to
    prevent you.

    You haven't specified what version of Windows you are using, nor what
    version of gcc you tried. I get no crash running gcc 3.2.3's pexports
    from on winscard.dll on Win2K Pro SP 5. I can use that gcc with 2.3
    to build extensions. If you need help either getting that to work, or
    simply want an email of the pexports output, drop me an e-mail to let
    me know.

    -Scott David Daniels
    Scott.Daniels@A cm.Org

    Comment

    Working...