diff options
Diffstat (limited to 'perl-install/keyboard.pm')
-rw-r--r-- | perl-install/keyboard.pm | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/perl-install/keyboard.pm b/perl-install/keyboard.pm index 695c8747b..672384eb7 100644 --- a/perl-install/keyboard.pm +++ b/perl-install/keyboard.pm @@ -476,19 +476,15 @@ sub setup { } elsif (-e (my $f = "$ENV{SHARE_PATH}/keymaps/$kmap.bkmap")) { load(scalar cat_($f)); } else { - my $F; - if (my $pid = open $F, "-|") { - local $/ = undef; - eval { load(join('', <$F>)) }; - waitpid $pid, 0; - } else { + my $kid = run_program::bg_command(sub { eval { require packdrake; my $packer = new packdrake("$ENV{SHARE_PATH}/keymaps.cz2", quiet => 1); $packer->extract_archive(undef, "$kmap.bkmap"); }; - c::_exit(0); - } + }); + local $/ = undef; + eval { my $fd = $kid->{fd}; load(join('', <$fd>)) }; } if (-x "/usr/X11R6/bin/setxkbmap") { setxkbmap($keyboard); |