Csound Csound-dev Csound-tekno Search About

[Csnd] Re: Re: Re: problems building python interface for Mac Leopard

Date2008-02-27 09:07
Fromvictor
Subject[Csnd] Re: Re: Re: problems building python interface for Mac Leopard
except that it should be commonEnvironment.Copy().

I will look, but this all seems odd to me. Csound5 is building with
dynamic build with all the released components. That is the build
I maintain and if it doesn't build I know immediately.

Victor

----- Original Message ----- 
From: "Hector Centeno" 
To: 
Sent: Wednesday, February 27, 2008 6:32 AM
Subject: [Csnd] Re: Re: problems building python interface for Mac Leopard


> aaarrrgggh! sorry for the unnecessary long email. Reading the man page
> for scons I found the solution for this problem, csndPythonEnvironment
> should be defined this way:
>
> csndPythonEnvironment = Environment();
>
> The rest can stay as it is in CVS right now... later scons stopped
> with errors, but I'll try to figure it out before posting.
>
> Cheers,
>
>
> Hector
>
>
>
> On Wed, Feb 27, 2008 at 1:15 AM, Hector Centeno  wrote:
>> Trying to build with interfaces (singles or doubles, static or
>>  dynamic), first I get:
>>
>>
>>  CONFIGURATION DECISION: Not building Csound Lua interface library.
>>  NameError: name 'csndPythonEnvironment' is not defined:
>>   File "/Users/hector/Documents/build/csound5/SConstruct", line 1193:
>>
>>    csndPythonEnvironment.Append(LIBS = ['csound','_csnd'])
>>
>>  So I edit SConstruct and change this:
>>
>>             if commonEnvironment['dynamicCsoundLibrary'] == '1':
>>                 csndPythonEnvironment.Append(LIBS = ['_csnd'])
>>             else:
>>
>>  To this:
>>
>>             if commonEnvironment['dynamicCsoundLibrary'] == '1':
>>                 csndPythonEnvironment = []
>>                 csndPythonEnvironment.append(LIBS = ['_csnd'])
>>             else:
>>
>>  Then I get:
>>
>>  TypeError: append() takes no keyword arguments:
>>
>>  So I change it to this:
>>
>>             if commonEnvironment['dynamicCsoundLibrary'] == '1':
>>                 csndPythonEnvironment = []
>>                 LIBS = ['_csnd']
>>                 csndPythonEnvironment.append(LIBS)
>>             else:
>>
>>  But then it moves forward and I get this:
>>
>>  AttributeError: 'list' object has no attribute 'SharedObject'
>>
>>  related to this section:
>>
>>
>>         csoundPythonInterface = csndPythonEnvironment.SharedObject(
>>             'interfaces/python_interface.i',
>>             SWIGFLAGS = [swigflags, '-python', '-outdir', '.'])
>>
>>  Changing it to: csndPythonEnvironment.Copy I get:
>>
>>  AttributeError: 'list' object has no attribute 'copy'
>>
>>
>>  I don't know where to go from here. SharedObject is defined by scons
>>  and should work, I don't know why is not.
>>
>>  Thanks,
>>
>>  Hector
>>
>>
>>
>>
>>
>>
>>  On Tue, Feb 26, 2008 at 1:36 PM, victor  
>> wrote:
>>  > csndPythonEnvironment = commonEnvironment.Copy() ?
>>  >
>>  >  I need to look at this, SConstruct should build regardless of
>>  >  it being 10.5 or not. I think it's the static lib build again, which
>>  >  I thought I'd fixed. Or is it doubles version? I need to get this
>>  >  right, trouble is finding time these days...
>>  >
>>  >
>>  >
>>  >  ----- Original Message -----
>>  >  From: "Hector Centeno" 
>>  >  To: 
>>  >  Sent: Tuesday, February 26, 2008 5:12 PM
>>  >  Subject: [Csnd] problems building python interface for Mac Leopard
>>  >
>>  >
>>  >  > Hi,
>>  >  >
>>  >  > Just in case someone has some time and information to help me with 
>> this:
>>  >  >
>>  >  > Trying to build csound with interfaces in Mac OS X Leopard, gave me
>>  >  > errors at this point:
>>  >  >
>>  >  > csndPythonEnvironment.Append(LIBS = ['csound','_csnd'])
>>  >  >
>>  >  > First I changed the spelling of Append to lowercase and that 
>> changed
>>  >  > the error to name not defined for csndPythonEnvironment. I added 
>> some
>>  >  > hacks to make it work, without knowing if I'm doing the right thing 
>> (I
>>  >  > predefined it this way: csndPythonEnvironment = []), and got pass 
>> that
>>  >  > point but then it stopped at:
>>  >  >
>>  >  > csoundPythonInterface =
>>  >  > 
>> csndPythonEnvironment.SharedObject('interfaces/python_interface.i',SWIGFLAGS
>>  >  > = [swigflags, '-python', '-outdir', '.'])
>>  >  >
>>  >  > Saying there is no SharedObject method, which I guess might be 
>> related
>>  >  > to my changes, or not?
>>  >  >
>>  >  >
>>  >  >
>>  >  > Cheers,
>>  >  >
>>  >  > Hector
>>  >  >
>>  >  >
>>  >  > Send bugs reports to this list.
>>  >  > To unsubscribe, send email sympa@lists.bath.ac.uk with body 
>> "unsubscribe
>>  >  > csound"
>>  >
>>  >
>>  >
>>  >  Send bugs reports to this list.
>>  >  To unsubscribe, send email sympa@lists.bath.ac.uk with body 
>> "unsubscribe csound"
>>  >
>>
>
>
> Send bugs reports to this list.
> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe 
> csound" 


Date2008-02-27 10:34
FromVictor Lazzarini
Subject[Csnd] Re: Re: Re: Re: problems building python interface for Mac Leopard
I fixed the build, it should work now with both

scons buildInterfaces=1

and

scons dynamicCsoundLibrary=1 buildInterfaces=1

It was my fault, really, I started fixing the static lib build and broke the
dynamic build and both would not build the python module.

It should be OK now.

Victor


At 09:07 27/02/2008, you wrote:
>except that it should be commonEnvironment.Copy().
>
>I will look, but this all seems odd to me. Csound5 is building with
>dynamic build with all the released components. That is the build
>I maintain and if it doesn't build I know immediately.
>
>Victor
>
>----- Original Message ----- From: "Hector Centeno" 
>To: 
>Sent: Wednesday, February 27, 2008 6:32 AM
>Subject: [Csnd] Re: Re: problems building python interface for Mac Leopard
>
>
>>aaarrrgggh! sorry for the unnecessary long email. Reading the man page
>>for scons I found the solution for this problem, csndPythonEnvironment
>>should be defined this way:
>>
>>csndPythonEnvironment = Environment();
>>
>>The rest can stay as it is in CVS right now... later scons stopped
>>with errors, but I'll try to figure it out before posting.
>>
>>Cheers,
>>
>>
>>Hector
>>
>>
>>
>>On Wed, Feb 27, 2008 at 1:15 AM, Hector Centeno  wrote:
>>>Trying to build with interfaces (singles or doubles, static or
>>>  dynamic), first I get:
>>>
>>>
>>>  CONFIGURATION DECISION: Not building Csound Lua interface library.
>>>  NameError: name 'csndPythonEnvironment' is not defined:
>>>   File "/Users/hector/Documents/build/csound5/SConstruct", line 1193:
>>>
>>>    csndPythonEnvironment.Append(LIBS = ['csound','_csnd'])
>>>
>>>  So I edit SConstruct and change this:
>>>
>>>             if commonEnvironment['dynamicCsoundLibrary'] == '1':
>>>                 csndPythonEnvironment.Append(LIBS = ['_csnd'])
>>>             else:
>>>
>>>  To this:
>>>
>>>             if commonEnvironment['dynamicCsoundLibrary'] == '1':
>>>                 csndPythonEnvironment = []
>>>                 csndPythonEnvironment.append(LIBS = ['_csnd'])
>>>             else:
>>>
>>>  Then I get:
>>>
>>>  TypeError: append() takes no keyword arguments:
>>>
>>>  So I change it to this:
>>>
>>>             if commonEnvironment['dynamicCsoundLibrary'] == '1':
>>>                 csndPythonEnvironment = []
>>>                 LIBS = ['_csnd']
>>>                 csndPythonEnvironment.append(LIBS)
>>>             else:
>>>
>>>  But then it moves forward and I get this:
>>>
>>>  AttributeError: 'list' object has no attribute 'SharedObject'
>>>
>>>  related to this section:
>>>
>>>
>>>         csoundPythonInterface = csndPythonEnvironment.SharedObject(
>>>             'interfaces/python_interface.i',
>>>             SWIGFLAGS = [swigflags, '-python', '-outdir', '.'])
>>>
>>>  Changing it to: csndPythonEnvironment.Copy I get:
>>>
>>>  AttributeError: 'list' object has no attribute 'copy'
>>>
>>>
>>>  I don't know where to go from here. SharedObject is defined by scons
>>>  and should work, I don't know why is not.
>>>
>>>  Thanks,
>>>
>>>  Hector
>>>
>>>
>>>
>>>
>>>
>>>
>>>  On Tue, Feb 26, 2008 at 1:36 PM, victor  wrote:
>>>  > csndPythonEnvironment = commonEnvironment.Copy() ?
>>>  >
>>>  >  I need to look at this, SConstruct should build regardless of
>>>  >  it being 10.5 or not. I think it's the static lib build again, which
>>>  >  I thought I'd fixed. Or is it doubles version? I need to get this
>>>  >  right, trouble is finding time these days...
>>>  >
>>>  >
>>>  >
>>>  >  ----- Original Message -----
>>>  >  From: "Hector Centeno" 
>>>  >  To: 
>>>  >  Sent: Tuesday, February 26, 2008 5:12 PM
>>>  >  Subject: [Csnd] problems building python interface for Mac Leopard
>>>  >
>>>  >
>>>  >  > Hi,
>>>  >  >
>>>  >  > Just in case someone has some time and information to help me 
>>> with this:
>>>  >  >
>>>  >  > Trying to build csound with interfaces in Mac OS X Leopard, gave me
>>>  >  > errors at this point:
>>>  >  >
>>>  >  > csndPythonEnvironment.Append(LIBS = ['csound','_csnd'])
>>>  >  >
>>>  >  > First I changed the spelling of Append to lowercase and that changed
>>>  >  > the error to name not defined for csndPythonEnvironment. I added some
>>>  >  > hacks to make it work, without knowing if I'm doing the right 
>>> thing (I
>>>  >  > predefined it this way: csndPythonEnvironment = []), and got pass 
>>> that
>>>  >  > point but then it stopped at:
>>>  >  >
>>>  >  > csoundPythonInterface =
>>>  >  > 
>>> csndPythonEnvironment.SharedObject('interfaces/python_interface.i',SWIGFLAGS
>>>  >  > = [swigflags, '-python', '-outdir', '.'])
>>>  >  >
>>>  >  > Saying there is no SharedObject method, which I guess might be 
>>> related
>>>  >  > to my changes, or not?
>>>  >  >
>>>  >  >
>>>  >  >
>>>  >  > Cheers,
>>>  >  >
>>>  >  > Hector
>>>  >  >
>>>  >  >
>>>  >  > Send bugs reports to this list.
>>>  >  > To unsubscribe, send email sympa@lists.bath.ac.uk with body 
>>> "unsubscribe
>>>  >  > csound"
>>>  >
>>>  >
>>>  >
>>>  >  Send bugs reports to this list.
>>>  >  To unsubscribe, send email sympa@lists.bath.ac.uk with body 
>>> "unsubscribe csound"
>>>  >
>>
>>
>>Send bugs reports to this list.
>>To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe 
>>csound"
>
>
>
>Send bugs reports to this list.
>To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe 
>csound"

Victor Lazzarini
Music Technology Laboratory
Music Department
National University of Ireland, Maynooth


Date2008-02-27 17:56
From"Hector Centeno"
Subject[Csnd] Re: problems building python interface for Mac Leopard
AttachmentsNone