Building R10B-3 on Mac OS X Tiger

Bjorn Gustavsson <>
Mon May 9 09:35:51 CEST 2005


Thanks for the workaround and the information.

However, the tech note is from Sep 2003.

poll() actually exists and works in Panther. It does seems to
exist in Tiger, too.

We'll try to fix the problem in OTP R10B-6 (it's too late for
R10B-5).


Regarding the workaround:

Instead of removing system header files, I suggest the following patch
to erts/configure. I have not actually tested it on Tiger, but it does
force the emulator to use select() instead of poll().

--- erts/configure.ORIG	Mon May  9 09:28:58 2005
+++ erts/configure	Mon May  9 09:29:23 2005
@@ -3691,7 +3691,7 @@
 
 
 for ac_hdr in fcntl.h limits.h unistd.h syslog.h dlfcn.h ieeefp.h \
-                 poll.h sys/stropts.h \
+                 sys/stropts.h \
                  sys/ioctl.h sys/time.h sys/uio.h sys/sockio.h sys/socketio.h \
                  net/errno.h malloc.h mach-o/dyld.h arpa/nameser.h
 do
@@ -4866,7 +4866,7 @@
 
 
 for ac_func in ieee_handler fpsetmask finite isnan isinf res_gethostbyname dlopen \
-		poll pread pwrite writev memmove strerror strerror_r strncasecmp \
+		pread pwrite writev memmove strerror strerror_r strncasecmp \
 		gethrtime localtime_r gmtime_r mremap memcpy mallopt
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6



/Bjorn


Charles Blair <> writes:

> On Fri, May 06, 2005 at 02:27:46AM +0200, Micka?l R?mond wrote:
> > I did not look what is triggered at compilation by this file, and I  
> > do not understand why poll.h is a problem, but it works for me.
> 
> i was led down the route i followed by the following apple technical
> note:
> 
> poll 
> This API is not supported in Mac OS X, instead, the function select is
> used. [etc.]
> http://developer.apple.com/technotes/tn2002/tn2071.html
> 
> i am not an os x expert, but it's possible that the implementation
> finally caught up with the documentation in os x 10.4, since R10B-4
> compiled fine under 10.3.
> 

-- 
Björn Gustavsson, Erlang/OTP, Ericsson AB



More information about the erlang-questions mailing list