Erlang Mailing Lists

Author Message

<  Erlang patches mailing list  ~  Mac OS X Patch

bfulg at pacbell.net
Posted: Wed Feb 02, 2005 4:39 am Reply with quote
Guest
Back in September of 2003, Sean Hinde identified a problem with Erlang
under Mac OS X. Could this patch be incorporated upstream so we don't
have to keep manually patching the sources?

Thanks,

-Brent

========================================

From: Sean Hinde <sean.hinde_at_mac.com>
Subject: OS X patch for run_erl.c
Date: Sat, 13 Sep 2003 18:35:17 +0100

Hi,

The following patch to run_erl.c is required for Erlang to run in
embedded mode under OS X. Without this patch run_erl fails to create
the pipe in /tmp

Hopefully this will make it into R9C-1, but in the meantime here it is
in case anyone else has encountered the problem and needs a fix now.

Regs,
Sean

[HugeMac:~/Desktop] sean% diff -u
otp_src_R9C-0.orig/erts/etc/unix/run_erl.c
otp_src_R9C-0/erts/etc/unix/run_erl.c
--- otp_src_R9C-0.orig/erts/etc/unix/run_erl.c Mon Jul 7 13:01:10 2003
+++ otp_src_R9C-0/erts/etc/unix/run_erl.c Sat Sep 13 18:26:53 2003
<at> <at> -738,7 +738,11 <at> <at>
*/
static int create_fifo(char *name, int perm)
{
- if ((mknod(name, S_IFIFO | perm, 0) < 0) && (errno != EEXIST))
+#ifdef HAVE_MACH_O_DYLD_H
+ if ((mkfifo(name, perm) < 0) && (errno != EEXIST))
+#else
+ if ((mknod(name, S_IFIFO | perm, 0) < 0) && (errno != EEXIST))
+#endif
return -1;
return 0;
}



Post generated using Mail2Forum (http://m2f.sourceforge.net)

Display posts from previous:  

All times are GMT
Page 1 of 1
This forum is locked: you cannot post, reply to, or edit topics.

Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum