Hey,
There is a strange build issue with tclpd. Basically, the first time you try to build it, swig throws an error, but generates tcl_wrap.cxx anyway. Then the second time things build. Here's the build transcript, the error seems to be "Syntax error in input":
pd@debian-stable-i386:externals > make tclpd cd /home/pd/auto-build/pd-extended/externals/tclpd && make make[1]: Entering directory `/home/pd/auto-build/pd-extended/ externals/tclpd' swig -v -c++ -tcl -o tcl_wrap.cxx -I../../pd/src -I/usr/include/ tcl8.4 tcl.i LibDir: tcl ./ ../../pd/src/ /usr/include/tcl8.4/ /usr/share/swig1.3/tcl/ ./swig_lib/tcl/ /usr/share/swig1.3/config/ ./swig_lib/config/ /usr/share/swig1.3/ ./swig_lib/ Preprocessing... Starting language-specific parse... ../../pd/src/m_pd.h:467: Error: Syntax error in input(1). tcl.i:50: Warning(121): %name is deprecated. Use %rename instead. tcl.i:53: Warning(302): Identifier 't_symbol' redefined (ignored), ../../pd/src/m_pd.h:65: Warning(302): previous definition of 't_symbol' (Renamed from '_symbol'). Processing types... C++ analysis... Generating wrappers... ../../pd/src/m_pd.h:222: Warning(454): Setting a pointer/reference variable may leak memory. ../../pd/src/m_pd.h:223: Warning(454): Setting a pointer/reference variable may leak memory. ../../pd/src/m_pd.h:388: Warning(462): Unable to set variable of type char [] ../../pd/src/m_pd.h:389: Warning(462): Unable to set variable of type char [] ../../pd/src/m_pd.h:539: Warning(454): Setting a pointer/reference variable may leak memory. ../../pd/src/m_pd.h:593: Warning(454): Setting a pointer/reference variable may leak memory. ../../pd/src/m_pd.h:602: Warning(454): Setting a pointer/reference variable may leak memory. ../../pd/src/m_pd.h:621: Warning(454): Setting a pointer/reference variable may leak memory. tcl_extras.h:19: Warning(454): Setting a pointer/reference variable may leak memory. make[1]: *** [tcl_wrap.cxx] Error 1 make[1]: Leaving directory `/home/pd/auto-build/pd-extended/externals/ tclpd' make: *** [/home/pd/auto-build/pd-extended/externals/tclpd/ tcl.pd_linux] Error 2
------------------------------------------------------------------------ ----
You can't steal a gift. Bird gave the world his music, and if you can hear it, you can have it. - Dizzy Gillespie
Hans-Christoph Steiner ha scritto:
Hey,
There is a strange build issue with tclpd. Basically, the first time you try to build it, swig throws an error, but generates tcl_wrap.cxx anyway. Then the second time things build. Here's the build transcript, the error seems to be "Syntax error in input":
pd@debian-stable-i386:externals > make tclpd
[...]
is your problem reproducible with vanilla pd? how's pd-extended's m_pd.h differs from vanilla's m_pd.h ?
I give a quick check, and I see that line 467 of pd-extended:
http://pure-data.svn.sourceforge.net/viewvc/pure-data/branches/pd-extended/v...
it's different from vanilla pd:
http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/pd/src/m_pd.h?re...
just compare the two sources. you will find the answer by yourself (I hope). I am not sure what "__attribute__ ((format (printf, 1, 2)));" is for.
if it gives trouble, you can always disable the wrapping of this function by swig, but I believe error() is required by externals written in Tcl, so it would not be a clever solution.
On Mar 16, 2008, at 4:17 PM, mescalinum@gmail.com wrote:
Hans-Christoph Steiner ha scritto:
Hey,
There is a strange build issue with tclpd. Basically, the first time you try to build it, swig throws an error, but generates tcl_wrap.cxx anyway. Then the second time things build. Here's the build transcript, the error seems to be "Syntax error in input":
pd@debian-stable-i386:externals > make tclpd
[...]
is your problem reproducible with vanilla pd? how's pd-extended's m_pd.h differs from vanilla's m_pd.h ?
I give a quick check, and I see that line 467 of pd-extended:
http://pure-data.svn.sourceforge.net/viewvc/pure-data/branches/pd- extended/v0-40/pd/src/m_pd.h?revision=9168&view=markup#l_460
it's different from vanilla pd:
http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/pd/src/ m_pd.h?revision=9590&view=markup#l_442
just compare the two sources. you will find the answer by yourself (I hope). I am not sure what "__attribute__ ((format (printf, 1, 2)));" is for.
if it gives trouble, you can always disable the wrapping of this function by swig, but I believe error() is required by externals written in Tcl, so it would not be a clever solution.
-- Federico Ferri
Yee haw, it's fixed:
http://pure-data.svn.sourceforge.net/viewvc/pure-data/trunk/externals/ tclpd/tcl.i?r1=8736&r2=9591
Apparently, swig doesn't quite know about the GNU extensions to C.
.hc
------------------------------------------------------------------------ ----
All mankind is of one author, and is one volume; when one man dies, one chapter is not torn out of the book, but translated into a better language; and every chapter must be so translated.... -John Donne