summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorLauri Leukkunen <lle@rahina.org>2009-01-09 02:04:20 +0200
committerLauri Leukkunen <lle@rahina.org>2009-01-10 01:12:43 +0200
commitb57596d84e964e44bd42ce4b6a447c296392cfcd (patch)
tree540964976df35d26c951e25c64f3c698e0da249c /utils
parentf5e1929e764965d8ef0fb951a825b9cd74bcf0cd (diff)
Builds for OS X 10.4 with these changes
A bit more ifdef __APPLE__ testing was needed. Signed-off-by: Lauri Leukkunen <lle@rahina.org>
Diffstat (limited to 'utils')
-rw-r--r--utils/Makefile4
-rw-r--r--utils/sb2-monitor.c7
2 files changed, 8 insertions, 3 deletions
diff --git a/utils/Makefile b/utils/Makefile
index 3a4a99f..cf9b6c4 100644
--- a/utils/Makefile
+++ b/utils/Makefile
@@ -6,7 +6,7 @@ $(D)/sb2-show: CFLAGS := $(CFLAGS) -Wall -W -Werror \
-I$(SRCDIR)/include
$(D)/sb2-show.o: preload/exported.h
-$(D)/sb2-show: preload/libsb2.${SHLIBEXT} $(D)/sb2-show.o
+$(D)/sb2-show: preload/libsb2.$(SHLIBEXT) $(D)/sb2-show.o
$(MKOUTPUTDIR)
$(P)LD
$(Q)$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^
@@ -25,7 +25,7 @@ $(D)/sb2-interp-wrapper: CFLAGS := $(CFLAGS) -Wall -W -Werror \
-I$(SRCDIR)/preload -Ipreload/ $(PROTOTYPEWARNINGS) \
-I$(SRCDIR)/include
-$(D)/sb2-interp-wrapper: preload/libsb2.so $(D)/sb2-interp-wrapper.o
+$(D)/sb2-interp-wrapper: preload/libsb2.$(SHLIBEXT) $(D)/sb2-interp-wrapper.o
$(MKOUTPUTDIR)
$(P)LD
$(Q)$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ -ldl
diff --git a/utils/sb2-monitor.c b/utils/sb2-monitor.c
index f37e515..2ae186c 100644
--- a/utils/sb2-monitor.c
+++ b/utils/sb2-monitor.c
@@ -370,7 +370,12 @@ int main(int argc, char *argv[])
* never arrives - purpose of the pipe is only to keep
* the PID reserved until the parent dies.
*/
- setpgrp(); /* change process group to avoid signals*/
+#ifdef __APPLE__
+ setpgrp(0, 0); /* change process group to
+ * avoid signals*/
+#else
+ setpgrp();
+#endif
close(pipe_fds[1]); /* close W-end */
while (read(pipe_fds[0], &ch, 1) > 0);
DEBUG_MSG("dummy child: done\n");