From fc483e0d577a35e41a98ddaae20d1682f10309e3 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 29 Mar 2007 22:57:56 +0000 Subject: [PATCH] * Allow the path to xkbcomp to specified in an environment variable. The X server by default looks for it under its own prefix, which isn't right. Not being able to run xkbcomp causes the Xkb keyboard extension to fail (which incidentally is also the reason why Ctrl-Alt-Fn didn't work). svn path=/nixpkgs/trunk/; revision=8494 --- pkgs/servers/x11/xorg/default.nix | 2 +- .../x11/xorg/generate-expr-from-tarballs.pl | 2 +- .../x11/xorg/xorgserver-xkbcomp-path.patch | 15 +++++++++++++++ 3 files changed, 17 insertions(+), 2 deletions(-) create mode 100644 pkgs/servers/x11/xorg/xorgserver-xkbcomp-path.patch diff --git a/pkgs/servers/x11/xorg/default.nix b/pkgs/servers/x11/xorg/default.nix index 4d1f10d93e0..22c4584a5b8 100644 --- a/pkgs/servers/x11/xorg/default.nix +++ b/pkgs/servers/x11/xorg/default.nix @@ -2663,7 +2663,7 @@ rec { url = http://mirror.switch.ch/ftp/mirror/X11/pub/X11R7.2/src/everything/xorg-server-X11R7.2-1.2.0.tar.bz2; sha256 = "023a13aay8gd09a7x1s6wndbsj3xr2ismsvgbsi9dz4g7nw8ga96"; }; - buildInputs = [pkgconfig bigreqsproto compositeproto damageproto libdmx dmxproto evieext fixesproto fontcacheproto libfontenc fontsproto freetype glproto inputproto kbproto libdrm mkfontdir mkfontscale perl printproto randrproto recordproto renderproto resourceproto scrnsaverproto trapproto videoproto libX11 libXau libXaw xcmiscproto libXdmcp libXext xextproto xf86bigfontproto xf86dgaproto xf86driproto xf86miscproto xf86vidmodeproto libXfixes libXfont libXi xineramaproto libxkbfile libxkbui libXmu libXpm xproto libXrender libXres libXt xtrans libXtst libXxf86misc libXxf86vm zlib ]; mesaSrc = mesa.src; x11BuildHook = ./xorgserver.sh; patches = [./xorgserver-dri-path.patch]; + buildInputs = [pkgconfig bigreqsproto compositeproto damageproto libdmx dmxproto evieext fixesproto fontcacheproto libfontenc fontsproto freetype glproto inputproto kbproto libdrm mkfontdir mkfontscale perl printproto randrproto recordproto renderproto resourceproto scrnsaverproto trapproto videoproto libX11 libXau libXaw xcmiscproto libXdmcp libXext xextproto xf86bigfontproto xf86dgaproto xf86driproto xf86miscproto xf86vidmodeproto libXfixes libXfont libXi xineramaproto libxkbfile libxkbui libXmu libXpm xproto libXrender libXres libXt xtrans libXtst libXxf86misc libXxf86vm zlib ]; mesaSrc = mesa.src; x11BuildHook = ./xorgserver.sh; patches = [./xorgserver-dri-path.patch ./xorgserver-xkbcomp-path.patch]; }) // {inherit bigreqsproto compositeproto damageproto libdmx dmxproto evieext fixesproto fontcacheproto libfontenc fontsproto freetype glproto inputproto kbproto libdrm mkfontdir mkfontscale perl printproto randrproto recordproto renderproto resourceproto scrnsaverproto trapproto videoproto libX11 libXau libXaw xcmiscproto libXdmcp libXext xextproto xf86bigfontproto xf86dgaproto xf86driproto xf86miscproto xf86vidmodeproto libXfixes libXfont libXi xineramaproto libxkbfile libxkbui libXmu libXpm xproto libXrender libXres libXt xtrans libXtst libXxf86misc libXxf86vm zlib ;}; xorgsgmldoctools = (stdenv.mkDerivation { diff --git a/pkgs/servers/x11/xorg/generate-expr-from-tarballs.pl b/pkgs/servers/x11/xorg/generate-expr-from-tarballs.pl index 7d3a117be33..336f8ed5482 100755 --- a/pkgs/servers/x11/xorg/generate-expr-from-tarballs.pl +++ b/pkgs/servers/x11/xorg/generate-expr-from-tarballs.pl @@ -40,7 +40,7 @@ $pcMap{"bdftopcf"} = "bdftopcf"; $pcMap{"libxslt"} = "libxslt"; -$extraAttrs{"xorgserver"} = " mesaSrc = mesa.src; x11BuildHook = ./xorgserver.sh; patches = [./xorgserver-dri-path.patch]; "; +$extraAttrs{"xorgserver"} = " mesaSrc = mesa.src; x11BuildHook = ./xorgserver.sh; patches = [./xorgserver-dri-path.patch ./xorgserver-xkbcomp-path.patch]; "; $extraAttrs{"imake"} = " inherit xorgcffiles; x11BuildHook = ./imake.sh; patches = [./imake.patch]; "; diff --git a/pkgs/servers/x11/xorg/xorgserver-xkbcomp-path.patch b/pkgs/servers/x11/xorg/xorgserver-xkbcomp-path.patch new file mode 100644 index 00000000000..825d09ba1e0 --- /dev/null +++ b/pkgs/servers/x11/xorg/xorgserver-xkbcomp-path.patch @@ -0,0 +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 +*************** +*** 923,928 **** +--- 923,931 ---- + XkbDfltRepeatInterval = (long)atoi(argv[i]); + return 2; + } ++ char *xkbBinDir = getenv("XKB_BINDIR"); ++ if (xkbBinDir) ++ XkbBinDirectory = _XkbDupString(xkbBinDir); + return 0; + } +