Merge pull request #7316 from nslqqq/fix_xephyr2

xorg: fix Xephyr
This commit is contained in:
Domen Kožar 2015-04-11 07:35:51 -04:00
commit 87e9925d4a
3 changed files with 18 additions and 14 deletions

View File

@ -1,7 +1,7 @@
{ args, xorg }:
let
inherit (args) stdenv;
inherit (args) stdenv makeWrapper;
inherit (stdenv) lib isDarwin;
inherit (lib) overrideDerivation;
@ -300,13 +300,14 @@ in
in
if (!isDarwin)
then {
buildInputs = commonBuildInputs;
buildInputs = [ makeWrapper ] ++ commonBuildInputs;
propagatedBuildInputs = commonPropagatedBuildInputs ++ lib.optionals stdenv.isLinux [
args.udev
];
patches = commonPatches;
configureFlags = [
"--enable-kdrive" # not built by default
"--enable-xephyr"
"--enable-xcsecurity" # enable SECURITY extension
"--with-default-font-path=" # there were only paths containing "${prefix}",
# and there are no fonts in this package anyway
@ -314,6 +315,9 @@ in
postInstall = ''
rm -fr $out/share/X11/xkb/compiled
ln -s /var/tmp $out/share/X11/xkb/compiled
wrapProgram $out/bin/Xephyr \
--set XKB_BINDIR "${xorg.xkbcomp}/bin" \
--add-flags "-xkbdir ${xorg.xkeyboardconfig}/share/X11/xkb"
'';
passthru.version = version; # needed by virtualbox guest additions
} else {

View File

@ -1,15 +1,15 @@
diff -rc xorg-server-X11R7.2-1.2.0-orig/xkb/xkbInit.c xorg-server-X11R7.2-1.2.0/xkb/xkbInit.c
*** xorg-server-X11R7.2-1.2.0-orig/xkb/xkbInit.c Tue Jan 23 04:13:16 2007
--- xorg-server-X11R7.2-1.2.0/xkb/xkbInit.c Fri Mar 30 00:52:53 2007
*** xorg-server-X11R7.2-1.2.0-orig/xkb/xkbInit.c 2015-02-11 00:32:06.000000000 +0100
--- xorg-server-X11R7.2-1.2.0/xkb/xkbInit.c 2015-04-11 10:10:41.948438435 +0200
***************
*** 923,928 ****
--- 923,931 ----
XkbDfltRepeatInterval = (long)atoi(argv[i]);
return 2;
}
*** 733,738 ****
--- 733,742 ----
int
XkbProcessArguments(int argc, char *argv[], int i)
{
+ char *xkbBinDir = getenv("XKB_BINDIR");
+ if (xkbBinDir)
+ XkbBinDirectory = Xstrdup(xkbBinDir);
return 0;
}
+
if (strncmp(argv[i], "-xkbdir", 7) == 0) {
if (++i < argc) {
#if !defined(WIN32) && !defined(__CYGWIN__)

View File

@ -8682,7 +8682,7 @@ let
xorg = recurseIntoAttrs (import ../servers/x11/xorg/default.nix {
inherit clangStdenv fetchurl fetchgit fetchpatch stdenv pkgconfig intltool freetype fontconfig
libxslt expat libpng zlib perl mesa_drivers spice_protocol
dbus libuuid openssl gperf m4 libevdev tradcpp
dbus libuuid openssl gperf m4 libevdev tradcpp makeWrapper
autoconf automake libtool xmlto asciidoc flex bison python mtdev pixman;
bootstrap_cmds = if stdenv.isDarwin then darwin.bootstrap_cmds else null;
mesa = mesa_noglu;