From: David L. R. <ra...@cs...> - 2009-12-19 09:26:06
|
Greetings SBCL-Devel, This post is related to my earlier question about writing a patch for timed waiting on semaphores and condition variables [visible at http://sourceforge.net/mailarchive/forum.php?thread_name=633...@ma...&forum_name=sbcl-help ] I attempted to build the lutex version of SBCL and received an error about PTHREAD_MUTEX_ERRORCHECK being undeclared. It looks like the compiler needs C flag USE_UNIX98 to enable the inclusion of that constant. So, I first tried adding the flag "XOPEN_SOURCE=500" to the CFLAGS variable in line 26 of src/runtime/GNUmakefile. After that failed, I tried instead adding the flag "GNU_SOURCE". This second change seems to work [suggested changes taken from http://ipozgaj.blogspot.com/2006/08/posix-threads-and-manual-pages-rant.html ]. Is building the lutex version of threaded SBCL 1.0.33 on Linux 64 bit machines known to have this problem? I had the same difficulty with version 1.0.30. Does the second change look reasonable? Do we know whether such a change would introduce performance problems? In the long run, I don't expect to need to manually enable lutexes on my Ubuntu64 setup. It's just that I need to get the lutex version to work before I can test the addition of timed waiting to lutexes, and it seems like modifying the GNUMakefile could also have benefits for others. Thanks, David |