Csound Csound-dev Csound-tekno Search About

[CSOUND-DEV:4321] Re: Csound 5 SConstruct

Date2004-03-15 14:29
From"gogins@pipeline.com"
Subject[CSOUND-DEV:4321] Re: Csound 5 SConstruct
Thanks for your input. I've made some of the fixes you made, and some
others as well, but I've also found other things breaking, in some cases
because John Fitch and I are both working on the code and files sometimes
get out of synch.

And thanks for booking your changes in!

Original Message:
-----------------
From: stevenyi stevenyi@csounds.com
Date: Sun, 14 Mar 2004 21:52:46 -0800
To: csound-dev@eartha.mills.edu
Subject: [CSOUND-DEV:4317] Re: Csound 5 SConstruct


Hi Michael,

In the middle of trying this SCons stuff out.  The SConstruct looks very
easy to work with (then again, I like reading python code).  =)  I had
to change a line:

if commonEnvironment['buildCsoundVST'] == 1 and boostFound and
fltkFound:

instead of:

if commonEnvironment['buildCsoundVST'] and boostFound and fltkFound:

as the second line didn't recognize if I passed buildCsoundVST=0 at the
commandline and thus was trying to build CsoundVST and failing
everytime.  (I've checked that change in.)

I received this error with Flgraph.cpp:

g++
-DCSOUND_WITH_API-DLINUX-g-O2-Wall-DPIPES-DHAVE_FCNTL_H-DHAVE_UNISTED_H-DHAV
E_MALLOC_H-DHAVE_SGTTY_H-DHAVE_SYS_IOCTL_H-DHAVE_SYS_TIME_H-DHAVE_TERMIOS_H-
DHAVE_STRING_H-DHAVE_STRINGS_H-DRTAUDIO-DWINDOWS-DUSE_FLTK -DBETA -I. -IH
-I/usr/local/include -I/usr/include -c -o InOut/FL_graph.o
InOut/FL_graph.cpp
:5:16: warning: ISO C requires whitespace after the macro
name
InOut/FL_graph.cpp: In function `void add_graph(WINDAT*)':
InOut/FL_graph.cpp:197: error: `memcpy' undeclared (first use this
function)
InOut/FL_graph.cpp:197: error: (Each undeclared identifier is reported
only
   once for each function it appears in.)
InOut/FL_graph.cpp:201: error: `strcmp' undeclared (first use this
function)
InOut/FL_graph.cpp:219: error: `strlen' undeclared (first use this
function)
InOut/FL_graph.cpp:220: error: `strcpy' undeclared (first use this
function)
scons: *** [InOut/FL_graph.o] Error 1
scons: building terminated because of errors.


which I'm assuming will be fixed with the config.py you mentioned in
your note, yes?  For the time being I removed the #ifdef check and
included string.h regardless to get past that.

Oh, I see now... It seems that you have no spaces before or after the
something in environment.Append(CCFLAGS = "-Dsomething") and all of
those flags are getting appended to each other without space.  The
manual seems to have " -Dsomething" when appending and "-Dsomething "
when using Prepend().  I'll see if that gets me past the other problem
I'm getting:

:4:16: warning: ISO C requires whitespace after the macro
name
gcc
-DCSOUND_WITH_API-DLINUX-g-O2-Wall-DPIPES-DHAVE_FCNTL_H-DHAVE_UNISTED_H-DHAV
E_MALLOC_H-DHAVE_SGTTY_H-DHAVE_SYS_IOCTL_H-DHAVE_SYS_TIME_H-DHAVE_TERMIOS_H-
DHAVE_STRING_H-DHAVE_STRINGS_H-DRTAUDIO-DWINDOWS-DUSE_FLTK -DBETA -I. -IH
-I/usr/local/include -I/usr/include -c -o OOps/mididevice.o
OOps/mididevice.c
:4:16: warning: ISO C requires whitespace after the macro
name
OOps/mididevice.c: In function `OpenMIDIDevice':
OOps/mididevice.c:400: error: `TIOCGETP' undeclared (first use in this
function)OOps/mididevice.c:400: error: (Each undeclared identifier is
reported only once
OOps/mididevice.c:400: error: for each function it appears in.)
OOps/mididevice.c:401: error: invalid use of undefined type `struct
sgttyb'
OOps/mididevice.c:401: error: `EXTB' undeclared (first use in this
function)
OOps/mididevice.c:402: error: invalid use of undefined type `struct
sgttyb'
OOps/mididevice.c:402: error: `RAW' undeclared (first use in this
function)
OOps/mididevice.c:404: error: `TIOCSETP' undeclared (first use in this
function)OOps/mididevice.c: At top level:
OOps/mididevice.c:126: error: storage size of `tty' isn't known
scons: *** [OOps/mididevice.o] Error 1
scons: building terminated because of errors.

  
I'm going to keep working on the build file a little on my side to see
if I can get a full build (Sorry, forgot to mention this was on Fedora
Core Linux, python 2.2.3, scons 0.93, gcc 3.3.2).  My first impressions:

1)I like the SConstruct file's syntax.  It's easy for me to read, but
then again, as mentioned before, I really like python.

2)When running SCons, it seems to do a dependency check each time it
runs.  Not a big deal though, because:

3)Building with SCons is very fast!  It's seems to breeze by much
quicker than with Autotools or handbuilt Makefile (this observation is
completely subjective).

Thanks very much for checking this in.  All things aside, the build time
is really the part that surprised me the most.  Will write more later as
I spend more time with it.

steven




On Sun, 2004-03-14 at 16:30, gogins@pipeline.com wrote:
> In Csound 5 CVS, I have committed a _very preliminary_ SConstruct file, an
> SCons build file. On my installation of Cygwin, it builds everything in
> Csound CVS: Csound API library, all plugin opcodes, all utilities, console
> Csound, and CsoundVST plugin and front end. The CsoundVST front end runs,
> but does not render Csound files and is hard to debug. Csound renders
> trapped to soundfile and to real-time audio, and the FLTK graphs work.
> 
> On my installation of Fedora Core Linux, it builds all the above except
for
> the CsoundVST plugin and front end.
> 
> Much remains to be done before a valid comparison with autotools can be
> made:
> 
> - Create a working custom.py for dependency header and library locations,
> especially on Windows. Currently too many library and header paths are
> hard-coded.
> 
> - Add rules for building packages for distribution.
> 
> - Get the mingw and Visual C++ configurations working.
> 
> However, I feel that my favorable first impression of SCons has been
> confirmed: that it is essentially as powerful as autotools -- but easier
to
> understand, easier to work with, less likely to break, and it builds
> projects faster. 
> 
> Particularly gratifying is that building Windows DLLs with gcc is cake.
> 
> Anybody who wants to play around with this alpha build system should go to
> www.scons.org, download and install it, look at the User's Guide, and try
> it out.
> 
> 
> 
> --------------------------------------------------------------------
> mail2web - Check your email from the web at
> http://mail2web.com/ .
> 
> 
> 


--------------------------------------------------------------------
mail2web - Check your email from the web at
http://mail2web.com/ .

Date2004-03-15 17:50
Fromstevenyi
Subject[CSOUND-DEV:4323] Re: Csound 5 SConstruct
Yes, I see the new changes from John in the CVS require some SConstruct
changes.  Heading off to work now, I'll try out a compile out on WinXP
later today and perhaps will be able to work on the SConstruct there as
well.  I'll also give it a go on the SourceForge compile farm for
MacOSX, though that won't build for realtime as PortAudio v19 is not
implemented yet for MacOSX.  =(  At least this will see if the file can
build without realtime.

Thanks again for the work with this!  It's already made things easier
for me. =)

steven


On Mon, 2004-03-15 at 06:29, gogins@pipeline.com wrote:
> Thanks for your input. I've made some of the fixes you made, and some
> others as well, but I've also found other things breaking, in some cases
> because John Fitch and I are both working on the code and files sometimes
> get out of synch.
> 
> And thanks for booking your changes in!