Modified: trunk/launchd/src/Makefile.am (23101 => 23102)
--- trunk/launchd/src/Makefile.am 2007-02-23 00:43:05 UTC (rev 23101)
+++ trunk/launchd/src/Makefile.am 2007-02-23 16:35:27 UTC (rev 23102)
@@ -40,7 +40,7 @@
launchctl_LDFLAGS = -framework CoreFoundation -framework IOKit -weak_library /usr/lib/libedit.dylib
SystemStarter_CFLAGS = -mdynamic-no-pic $(AM_CFLAGS)
-SystemStarter_LDFLAGS = -framework CoreFoundation
+SystemStarter_LDFLAGS = -framework CoreFoundation -framework IOKit
SystemStarter_SOURCES = StartupItems.c IPC.c SystemStarter.c
launchd_CFLAGS = -mdynamic-no-pic $(AM_CFLAGS) -Wno-unused-parameter
Modified: trunk/launchd/src/Makefile.in (23101 => 23102)
--- trunk/launchd/src/Makefile.in 2007-02-23 00:43:05 UTC (rev 23101)
+++ trunk/launchd/src/Makefile.in 2007-02-23 16:35:27 UTC (rev 23102)
@@ -239,7 +239,7 @@
@LIBS_ONLY_FALSE@launchctl_CFLAGS = $(AM_CFLAGS) -I/System/Library/Frameworks/System.framework/PrivateHeaders
@LIBS_ONLY_FALSE@launchctl_LDFLAGS = -framework CoreFoundation -framework IOKit -weak_library /usr/lib/libedit.dylib
@LIBS_ONLY_FALSE@SystemStarter_CFLAGS = -mdynamic-no-pic $(AM_CFLAGS)
-@LIBS_ONLY_FALSE@SystemStarter_LDFLAGS = -framework CoreFoundation
+@LIBS_ONLY_FALSE@SystemStarter_LDFLAGS = -framework CoreFoundation -framework IOKit
@LIBS_ONLY_FALSE@SystemStarter_SOURCES = StartupItems.c IPC.c SystemStarter.c
@LIBS_ONLY_FALSE@launchd_CFLAGS = -mdynamic-no-pic $(AM_CFLAGS) -Wno-unused-parameter
@LIBS_ONLY_FALSE@launchd_LDFLAGS = -lbsm
Modified: trunk/launchd/src/SystemStarter.c (23101 => 23102)
--- trunk/launchd/src/SystemStarter.c 2007-02-23 00:43:05 UTC (rev 23101)
+++ trunk/launchd/src/SystemStarter.c 2007-02-23 16:35:27 UTC (rev 23102)
@@ -22,6 +22,7 @@
* @APPLE_APACHE_LICENSE_HEADER_END@
**/
+#include <IOKit/IOKitLib.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <paths.h>
@@ -115,6 +116,8 @@
} else if (!gDebugFlag && anAction != kActionStop) {
const char *ipw_cmd[] = { "/usr/sbin/ipconfig", "waitall", NULL };
const char *adm_cmd[] = { "/sbin/autodiskmount", "-va", NULL };
+ mach_timespec_t w = { 600, 0 };
+ kern_return_t kr;
/* Too many old StartupItems had implicit dependancies on
* "Network" via other StartupItems that are now no-ops.
@@ -123,6 +126,11 @@
* so we'll stall here to deal with this legacy dependancy
* problem.
*/
+
+ if ((kr = IOKitWaitQuiet(kIOMasterPortDefault, &w)) != kIOReturnSuccess) {
+ syslog(LOG_NOTICE, "IOKitWaitQuiet: %d\n", kr);
+ }
+
fwexec(ipw_cmd, true);
fwexec(adm_cmd, true);
}