summaryrefslogtreecommitdiff
path: root/boot
diff options
context:
space:
mode:
Diffstat (limited to 'boot')
-rwxr-xr-xboot15
1 files changed, 12 insertions, 3 deletions
diff --git a/boot b/boot
index 8977eaf9a3..af5ccc2853 100755
--- a/boot
+++ b/boot
@@ -155,16 +155,25 @@ sub boot_pkgs {
# autoreconf everything that needs it.
sub autoreconf {
my $dir;
+ my $fail;
foreach $dir (".", glob("libraries/*/")) {
if (-f "$dir/configure.ac") {
+ next if (my $pid = fork);
+ die "fork failed: $!" if (! defined $pid);
print "Booting $dir\n";
chdir $dir or die "can't change to $dir: $!";
- system("autoreconf") == 0
- or die "Running autoreconf failed with exitcode $?";
- chdir $curdir or die "can't change to $curdir: $!";
+ exec("autoreconf");
+ exit 1;
}
}
+
+ # Wait for all child processes to finish.
+ while (wait() != -1) {
+ $fail = 1 if $?;
+ }
+
+ die "Running autoreconf failed" if $fail;
}
sub checkBuildMk {