[ug-bosug] porting libntp .. AC_FUNC_MALLOC error
On 8/9/07, Anil Gulecha wrote: > Hi all, > > I was trying to port libntp library that allows talking to > Creative(and other) mp3 players.. the source consists of the libraries > and a sample application. > > I had the initial -Wall errors that I corrected and the library has > built fine. However, the sample app isnt building. > > bash-3.00$ pwd > /tmp/libnjb-2.2.5 > bash-3.00$ ls src/.libs/ > base.o ioutil.olibnjb.sonjbtime.oprotocol3.o > byteorder.o libnjb.alibnjb.so.5 playlist.o songid.o > datafile.o libnjb.la libnjb.so.5.1.0 procedure.o unicode.o > eax.olibnjb.lai njb_error.o protocol.o usb_io.o > bash-3.00$ cd sample/ > bash-3.00$ make > /bin/bash ../libtool --tag=CC --mode=link /opt/SUNWspro/bin/cc > -I../src -g -L/usr/sfw/lib -o cursesplay cursesplay.o > ../src/libnjb.la -lcurses -lusb > /opt/SUNWspro/bin/cc -I../src -g -o .libs/cursesplay cursesplay.o > -L/usr/sfw/lib ../src/.libs/libnjb.so -lcurses -lusb -R/usr/local/lib > Undefined first referenced > symbol in file > rpl_malloc ../src/.libs/libnjb.so > ld: fatal: Symbol referencing errors. No output written to .libs/cursesplay > make: *** [cursesplay] Error 1 > bash-3.00$ > > > Upon googling I found out about AC_FUNC_MALLOC macro in configure.ac > that checks for correct calling of malloc, and malloc is replaced by > rpl_malloc for incorrect calling. > > Workarounds are given at http://wiki.buici.com/wiki/Autoconf_and_RPL_MALLOC > > but these appear to be more hacky that a correct workaround. According > to http://cygwin.com/ml/automake/2003-05/msg00043.html that error > comes forward when malloc isn't correctly called.. and thus the > correct thing to do in this situation is patch the source by clearing > this error. > > My questions are: > > What is the ideal way to patch this error? > What is the best way to patch this error for a spec file? > I removed the -Wall flag from the Makefiles.. however this was said to > be hacky, What is the correct way of going about correcting this > error? > The AC_FUNC_MALLOC is to safeguard against libs that do unsafe memory allocation. If someone puts this check in the configure.ac, then one of the two should be done a) The author should also put the guard code that introduces rpl_malloc OR remove the check if not relevant. b) The person who has downloaded and is using the code should verify if the compiler does a safe mem allocation and remove it. (if it doesn't it is a bug against the compiler !) I feel this check by configure script is useless and may be removed. Regarding the other question about correct way to do, depending on you want to use gcc or not do the following 1. If you use gcc, set CC=gcc before calling configure script in the spec file so that Makefile generated "just works". 2. If you use sunpro, then a) Create a patch that patches the makefile after configure script is run. This can never be submitted upstream and since it patches a temporary file, it is kind of hacky. But it works just fine as a quick solution. b) Better way would be to introduce a test in configure to test if the compiler is gcc, and in Makefile template (Makefile.am) you may use the condition to set the CFLAGS depending on whether compiler is gcc or not. This way the solution goes into the sources and can be submitted to the original author. You wouldn't need to maintain the patch whenever the original sources change. regards Shiv
[ug-bosug] [Invitation]: OSS Tech Talk
On 8/9/07, Ananth Shrinivas wrote: > > >> Are there any plans to record the session for posterity and less > >> fortunate *OSUG members in other parts of the world? > >> > >> > >> > > No plans of recording. Our recording infrastructure is quite cumbersome :-( > > If some BOSUGian can volunteer for it, great ! > > > You can thank Sriram Popuri for volunteering to record the talk. > It will be up on Google Videos sometime next week. Excellent! Sriram, if you are tuned in, thanks mate! > > Cheers, > Ananth > > ___ > ug-bosug mailing list > List-Unsubscribe: mailto:ug-bosug-unsubscribe at opensolaris.org > List-Owner: mailto:ug-bosug-owner at opensolaris.org > List-Archives: http://www.opensolaris.org/jive/forum.jspa?forumID=54 >
[ug-bosug] [Invitation]: OSS Tech Talk
>> Are there any plans to record the session for posterity and less >> fortunate *OSUG members in other parts of the world? >> >> >> > No plans of recording. Our recording infrastructure is quite cumbersome :-( > If some BOSUGian can volunteer for it, great ! > You can thank Sriram Popuri for volunteering to record the talk. It will be up on Google Videos sometime next week. Cheers, Ananth
[ug-bosug] [Invitation]: OSS Tech Talk
Siddharth Karnik wrote: > On 8/9/07, Joe G (Joseph George) wrote: > >> Of course, every BOSUG member is invited. With the ice cream too. :-) >> >> ~Joe >> > > Are there any plans to record the session for posterity and less > fortunate *OSUG members in other parts of the world? > > No plans of recording. Our recording infrastructure is quite cumbersome :-( If some BOSUGian can volunteer for it, great ! We will try to post Meeting Notes, Slides and References though. Cheers, Ananth
[ug-bosug] porting libntp .. AC_FUNC_MALLOC error
Hi all, I was trying to port libntp library that allows talking to Creative(and other) mp3 players.. the source consists of the libraries and a sample application. I had the initial -Wall errors that I corrected and the library has built fine. However, the sample app isnt building. bash-3.00$ pwd /tmp/libnjb-2.2.5 bash-3.00$ ls src/.libs/ base.o ioutil.olibnjb.sonjbtime.oprotocol3.o byteorder.o libnjb.alibnjb.so.5 playlist.o songid.o datafile.o libnjb.la libnjb.so.5.1.0 procedure.o unicode.o eax.olibnjb.lai njb_error.o protocol.o usb_io.o bash-3.00$ cd sample/ bash-3.00$ make /bin/bash ../libtool --tag=CC --mode=link /opt/SUNWspro/bin/cc -I../src -g -L/usr/sfw/lib -o cursesplay cursesplay.o ../src/libnjb.la -lcurses -lusb /opt/SUNWspro/bin/cc -I../src -g -o .libs/cursesplay cursesplay.o -L/usr/sfw/lib ../src/.libs/libnjb.so -lcurses -lusb -R/usr/local/lib Undefined first referenced symbol in file rpl_malloc ../src/.libs/libnjb.so ld: fatal: Symbol referencing errors. No output written to .libs/cursesplay make: *** [cursesplay] Error 1 bash-3.00$ Upon googling I found out about AC_FUNC_MALLOC macro in configure.ac that checks for correct calling of malloc, and malloc is replaced by rpl_malloc for incorrect calling. Workarounds are given at http://wiki.buici.com/wiki/Autoconf_and_RPL_MALLOC but these appear to be more hacky that a correct workaround. According to http://cygwin.com/ml/automake/2003-05/msg00043.html that error comes forward when malloc isn't correctly called.. and thus the correct thing to do in this situation is patch the source by clearing this error. My questions are: What is the ideal way to patch this error? What is the best way to patch this error for a spec file? I removed the -Wall flag from the Makefiles.. however this was said to be hacky, What is the correct way of going about correcting this error? Anil
[ug-bosug] [Invitation]: OSS Tech Talk
On 8/9/07, Joe G (Joseph George) wrote: > Of course, every BOSUG member is invited. With the ice cream too. :-) > > ~Joe Are there any plans to record the session for posterity and less fortunate *OSUG members in other parts of the world? > > On 09-Aug-07, at 8:58 AM, Sivasubramanian Muthusamy wrote: > > > Dear Ananth, > > > > May I attend this meeting ? I am likely to be in Bangalore on this > > day.. > > > > And bring in half a ton of ice cream ? > > > > Sivasubramanian M > > > > On 8/9/07, Ananth Shrinivas wrote: > >> Hi BOSUG, > >> > >> We are pleased to invite you to a tech-talk on "The OSS Audio > >> Framework" > >> by Dev Mazumdar, Co-Founder 4Front Technologies on Monday, 13th > >> August > >> 2007 at 5:00 P.M > >> > >> Dev and his company created the Open Sound System Drivers, API and > >> applications like XMMS for Unix and Unix-Like systems. OSS is free > >> software distributed under the CDDL and GPL > >> > >> Date : Monday, 13 August 2007 > >> Time : 5:00 P.M > >> Venue: > >> Himalaya Conference Room, > >> Sun Microsystems India, > >> Ground Floor, Divyashree Chambers, > >> Off Langford Road, > >> (Next to Shanti Nagar Hockey Stadium) > >> Bangalore - 560025 > >> > >> RSVP not mandatory. But it would be great if you can reply to me > >> if you > >> are interested. > >> > >> Cheers, > >> Ananth > >> > >> ___ > >> ug-bosug mailing list > >> List-Unsubscribe: mailto:ug-bosug-unsubscribe at opensolaris.org > >> List-Owner: mailto:ug-bosug-owner at opensolaris.org > >> List-Archives: http://www.opensolaris.org/jive/forum.jspa?forumID=54 > >> > > ___ > > ug-bosug mailing list > > List-Unsubscribe: mailto:ug-bosug-unsubscribe at opensolaris.org > > List-Owner: mailto:ug-bosug-owner at opensolaris.org > > List-Archives: http://www.opensolaris.org/jive/forum.jspa?forumID=54 > > ___ > ug-bosug mailing list > List-Unsubscribe: mailto:ug-bosug-unsubscribe at opensolaris.org > List-Owner: mailto:ug-bosug-owner at opensolaris.org > List-Archives: http://www.opensolaris.org/jive/forum.jspa?forumID=54 >
[ug-bosug] [Invitation]: OSS Tech Talk
Of course, every BOSUG member is invited. With the ice cream too. :-) ~Joe On 09-Aug-07, at 8:58 AM, Sivasubramanian Muthusamy wrote: > Dear Ananth, > > May I attend this meeting ? I am likely to be in Bangalore on this > day.. > > And bring in half a ton of ice cream ? > > Sivasubramanian M > > On 8/9/07, Ananth Shrinivas wrote: >> Hi BOSUG, >> >> We are pleased to invite you to a tech-talk on "The OSS Audio >> Framework" >> by Dev Mazumdar, Co-Founder 4Front Technologies on Monday, 13th >> August >> 2007 at 5:00 P.M >> >> Dev and his company created the Open Sound System Drivers, API and >> applications like XMMS for Unix and Unix-Like systems. OSS is free >> software distributed under the CDDL and GPL >> >> Date : Monday, 13 August 2007 >> Time : 5:00 P.M >> Venue: >> Himalaya Conference Room, >> Sun Microsystems India, >> Ground Floor, Divyashree Chambers, >> Off Langford Road, >> (Next to Shanti Nagar Hockey Stadium) >> Bangalore - 560025 >> >> RSVP not mandatory. But it would be great if you can reply to me >> if you >> are interested. >> >> Cheers, >> Ananth >> >> ___ >> ug-bosug mailing list >> List-Unsubscribe: mailto:ug-bosug-unsubscribe at opensolaris.org >> List-Owner: mailto:ug-bosug-owner at opensolaris.org >> List-Archives: http://www.opensolaris.org/jive/forum.jspa?forumID=54 >> > ___ > ug-bosug mailing list > List-Unsubscribe: mailto:ug-bosug-unsubscribe at opensolaris.org > List-Owner: mailto:ug-bosug-owner at opensolaris.org > List-Archives: http://www.opensolaris.org/jive/forum.jspa?forumID=54
[ug-bosug] [Invitation]: OSS Tech Talk
Dear Ananth, May I attend this meeting ? I am likely to be in Bangalore on this day.. And bring in half a ton of ice cream ? Sivasubramanian M On 8/9/07, Ananth Shrinivas wrote: > Hi BOSUG, > > We are pleased to invite you to a tech-talk on "The OSS Audio Framework" > by Dev Mazumdar, Co-Founder 4Front Technologies on Monday, 13th August > 2007 at 5:00 P.M > > Dev and his company created the Open Sound System Drivers, API and > applications like XMMS for Unix and Unix-Like systems. OSS is free > software distributed under the CDDL and GPL > > Date : Monday, 13 August 2007 > Time : 5:00 P.M > Venue: > Himalaya Conference Room, > Sun Microsystems India, > Ground Floor, Divyashree Chambers, > Off Langford Road, > (Next to Shanti Nagar Hockey Stadium) > Bangalore - 560025 > > RSVP not mandatory. But it would be great if you can reply to me if you > are interested. > > Cheers, > Ananth > > ___ > ug-bosug mailing list > List-Unsubscribe: mailto:ug-bosug-unsubscribe at opensolaris.org > List-Owner: mailto:ug-bosug-owner at opensolaris.org > List-Archives: http://www.opensolaris.org/jive/forum.jspa?forumID=54 >
[ug-bosug] [Invitation]: OSS Tech Talk
Hi BOSUG, We are pleased to invite you to a tech-talk on "The OSS Audio Framework" by Dev Mazumdar, Co-Founder 4Front Technologies on Monday, 13th August 2007 at 5:00 P.M Dev and his company created the Open Sound System Drivers, API and applications like XMMS for Unix and Unix-Like systems. OSS is free software distributed under the CDDL and GPL Date : Monday, 13 August 2007 Time : 5:00 P.M Venue: Himalaya Conference Room, Sun Microsystems India, Ground Floor, Divyashree Chambers, Off Langford Road, (Next to Shanti Nagar Hockey Stadium) Bangalore - 560025 RSVP not mandatory. But it would be great if you can reply to me if you are interested. Cheers, Ananth