aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/xkeyboard-config/tests/xkbTestFunc.pm
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/xkeyboard-config/tests/xkbTestFunc.pm')
-rw-r--r--xorg-server/xkeyboard-config/tests/xkbTestFunc.pm15
1 files changed, 8 insertions, 7 deletions
diff --git a/xorg-server/xkeyboard-config/tests/xkbTestFunc.pm b/xorg-server/xkeyboard-config/tests/xkbTestFunc.pm
index 1d7881d23..77f03144f 100644
--- a/xorg-server/xkeyboard-config/tests/xkbTestFunc.pm
+++ b/xorg-server/xkeyboard-config/tests/xkbTestFunc.pm
@@ -38,13 +38,14 @@ sub getXkbSettings
sub setXkbSettings
{
my ( $xkbRules, $xkbModel, $xkbLayouts, $xkbVariants, $xkbOptions ) = @_;
- ( system ( "setxkbmap", "-synch",
- "-rules", $xkbRules,
- "-model", $xkbModel,
- "-layout", $xkbLayouts,
- "-variant", $xkbVariants,
- "-option", $xkbOptions ) == 0 ) or die "Could not set xkb configuration";
- sleep 1;
+ my $outfile = ".test.out.xkb";
+ ( system ( "setxkbmap -rules \"$xkbRules\" " .
+ "-model \"$xkbModel\" " .
+ "-layout \"$xkbLayouts\" " .
+ "-variant \"$xkbVariants\" " .
+ "-option \"$xkbOptions\" " .
+ "-print | xkbcomp - -xkb $outfile" ) == 0 ) or die "Could not set xkb configuration";
+ unlink($outfile);
}
sub restoreXkbSettings