Csound Csound-dev Csound-tekno Search About

[Csnd] Re: Re: Re: Re: Re: Tentative request

Date2008-05-07 19:24
Fromvictor
Subject[Csnd] Re: Re: Re: Re: Re: Tentative request
No. The Python module has to be compiled and
linked against one of the versions (MacPython 2.4,2.5 or
Apple Python 2.3), which also sit in different locations.
Also the header file Python.h is different for each
Python version, and there is a bit of code in the interfaces
file that will not link to 2.3, because it uses functions
introduced later, so it needs to be selected for version.

Victor

----- Original Message ----- 
From: "JK" 
To: 
Sent: Wednesday, May 07, 2008 7:15 PM
Subject: [Csnd] Re: Re: Re: Re: Tentative request


> victor wrote:
>> That is a real problem, because it needs to link to one of
>> the many alternatives...
>
> Can it link dynamically, as in dlopen or whatever
> the heck the Windows equivalent is?  In which case
> the Python version could be a configuration option
> detected (or user-supplied) at install time.
>
> No doubt this option has already been considered and
> rejected... but why?
>
> -- JK, who has probably not spent enough time lurking...
>
>> ----- Original Message ----- From: "DavidW" 
>> To: 
>> Sent: Wednesday, May 07, 2008 2:29 AM
>> Subject: [Csnd] Re: Re: Tentative request
>>
>>
>> how about a build of the api on OSX which is python-version independent?
>> That'd mean I could make music again. :-)
>>
>> David
>>
>
> -- 
> I do not particularly want to go where the money is -
>  it usually does not smell nice there. -- A. Stepanov
>
>
> Send bugs reports to this list.
> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe 
> csound" 


Date2008-05-07 20:09
FromJK
Subject[Csnd] Re: Re: Re: Re: Re: Re: Tentative request
victor wrote:
> No. The Python module has to be compiled and
> linked against one of the versions (MacPython 2.4,2.5 or
> Apple Python 2.3), which also sit in different locations.
> Also the header file Python.h is different for each
> Python version, and there is a bit of code in the interfaces
> file that will not link to 2.3, because it uses functions
> introduced later, so it needs to be selected for version.

Ah, OK.  Could still work, but would need an extra
layer of shared lib indirection, which is not going
to be trivial to arrange.

-- JK

-- 
I do not particularly want to go where the money is -
  it usually does not smell nice there. -- A. Stepanov

Date2008-05-08 02:21
FromFelipe Sateler
Subject[Csnd] Re: Re: Re: Re: Re: Re: Re: Tentative request
AttachmentsNone  

Date2008-05-08 03:49
FromJK
Subject[Csnd] Re: Re: Re: Re: Re: Re: Re: Re: Tentative request
Felipe Sateler wrote:
> On Wednesday 07 May 2008 15:09:51 JK wrote:
>> Ah, OK.  Could still work, but would need an extra
>> layer of shared lib indirection, which is not going
>> to be trivial to arrange.
> 
> python 2.3 and 2.5 are not guaranteed to be ABI compatible, so AFAICS, you 
> can't simply load one or the other. If they were, it would merely suffice to 
> link with 2.3 and 2.5 could be a drop-in replacement.

Right, but you could implement the same Csound functions
in terms of each Python API in separate shared libs,
eg csnd-py.23.so, csnd-py.24.so, and csnd-py.25.so;
then choose which of *those* libs to load based on which
version of Python was present.  The various csnd-*.so's
link to the proper Python libs, either statically or
dynamically.

-- JK

-- 
I do not particularly want to go where the money is -
  it usually does not smell nice there. -- A. Stepanov