[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

X Strike Force X.Org X11 SVN commit: r594 - in trunk/debian: . patches patches/debian



Author: barbier
Date: 2005-09-07 16:48:43 -0500 (Wed, 07 Sep 2005)
New Revision: 594

Added:
   trunk/debian/patches/debian/916_add_XKBPATH_env_variable.diff
Modified:
   trunk/debian/changelog
   trunk/debian/patches/series
Log:
Modify setxkbmap and xkbcomp to look for XKB files in $XKBPATH if
this environment variable is set.  This allows installing both xlibs and
xkeyboard-config at the same time, so that xkeyboard-config can install
its files under /etc/X11/xkb-data until all packages depending on xlibs
are fixed (closes: #324768).


Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog	2005-09-03 20:48:30 UTC (rev 593)
+++ trunk/debian/changelog	2005-09-07 21:48:43 UTC (rev 594)
@@ -18,8 +18,15 @@
     dpkg-buildpackage -nc to work. Thanks Jeremy Shaw.
     + Also add -f to ln command in genscripts to allow -nc to work
 
- -- David Nusinow <dnusinow@debian.org>  Sat,  3 Sep 2005 14:52:46 -0400
+  [ Denis Barbier ]
+  * Modify setxkbmap and xkbcomp to look for XKB files in $XKBPATH if this
+    environment variable is set.  This allows installing both xlibs and
+    xkeyboard-config at the same time, so that xkeyboard-config can install
+    its files under /etc/X11/xkb-data until all packages depending on xlibs
+    are fixed (closes: #324768).
 
+ -- Denis Barbier <barbier@debian.org>  Wed,  7 Sep 2005 23:22:15 +0200
+
 xorg-x11 (6.8.2.dfsg.1-6) unstable; urgency=low
 
   [ Branden Robinson ]

Added: trunk/debian/patches/debian/916_add_XKBPATH_env_variable.diff
===================================================================
--- trunk/debian/patches/debian/916_add_XKBPATH_env_variable.diff	2005-09-03 20:48:30 UTC (rev 593)
+++ trunk/debian/patches/debian/916_add_XKBPATH_env_variable.diff	2005-09-07 21:48:43 UTC (rev 594)
@@ -0,0 +1,88 @@
+$Id$
+
+As explained in #324768, this patch modifies setxkbmap and xkbcomp
+programs so that they look for XKB data files in $XKBPATH if this
+environment variable is set.  This allows installing both xlibs and
+xkeyboard-config at the same time, so that xkeyboard-config can
+install its files under /etc/X11/xkb-data until all packages depending
+on xlibs are fixed.  This patch by Denis Barbier.
+
+This patch will not be submitted upstream.
+
+Index: xorg-x11/xc/programs/setxkbmap/setxkbmap.c
+===================================================================
+--- xorg-x11.orig/xc/programs/setxkbmap/setxkbmap.c
++++ xorg-x11/xc/programs/setxkbmap/setxkbmap.c
+@@ -318,9 +318,13 @@
+ int 	i;
+ Bool	ok;
+ unsigned	present;
++char	*xkbpath;
+ 
+     ok= True;
+     addToList(&szInclPath,&numInclPath,&inclPath,".");
++    xkbpath= (char *)getenv("XKBPATH");
++    if (xkbpath!=NULL)
++	addToList(&szInclPath,&numInclPath,&inclPath,xkbpath);
+     addToList(&szInclPath,&numInclPath,&inclPath,DFLT_XKB_CONFIG_ROOT);
+     for (i=1;(i<argc)&&ok;i++) {
+ 	if (argv[i][0]!='-') {
+Index: xorg-x11/xc/programs/xkbcomp/xkbpath.c
+===================================================================
+--- xorg-x11.orig/xc/programs/xkbcomp/xkbpath.c
++++ xorg-x11/xc/programs/xkbcomp/xkbpath.c
+@@ -131,9 +131,14 @@
+ void
+ XkbAddDefaultDirectoriesToPath(void)
+ {
++char *xkbpath;
++
+     if (noDefaultPath)
+ 	return;
+     XkbAddDirectoryToPath(".");
++    xkbpath= (char *)getenv("XKBPATH");
++    if (xkbpath!=NULL)
++	XkbAddDirectoryToPath(xkbpath);
+     XkbAddDirectoryToPath(DFLT_XKB_CONFIG_ROOT);
+ }
+ 
+Index: xorg-x11/xc/programs/xkbevd/xkbevd.c
+===================================================================
+--- xorg-x11.orig/xc/programs/xkbevd/xkbevd.c
++++ xorg-x11/xc/programs/xkbevd/xkbevd.c
+@@ -471,20 +471,28 @@
+     else {
+ 	file= fopen(cfgFileName,"r");
+ 	if (file==NULL) { /* no personal config, try for a system one */
++	    char *xkbpath;
+ 	    if (cfgFileName!=buf) { /* user specified a file.  bail */
+ 		uError("Can't open config file \"%s\n",cfgFileName);
+ 		uAction("Exiting\n");
+ 		exit(1);
+ 	    }
+-	    sprintf(buf,DFLT_SYS_XKBEVD_CONFIG,DFLT_XKB_CONFIG_ROOT);
+-	    file= fopen(cfgFileName,"r");
++	    xkbpath= (char *)getenv("XKBPATH");
++	    if (xkbpath!=NULL) {
++		sprintf(buf,DFLT_SYS_XKBEVD_CONFIG,xkbpath);
++		file= fopen(cfgFileName,"r");
++	    }
+ 	    if (file==NULL) {
+-		if (verbose) {
+-		    uError("Couldn't find a config file anywhere\n");
+-		    uAction("Exiting\n");
+-		    exit(1);
++	        sprintf(buf,DFLT_SYS_XKBEVD_CONFIG,DFLT_XKB_CONFIG_ROOT);
++	        file= fopen(cfgFileName,"r");
++		if (file==NULL) {
++		    if (verbose) {
++			uError("Couldn't find a config file anywhere\n");
++			uAction("Exiting\n");
++			exit(1);
++		    }
++		    exit(0);
+ 		}
+-		exit(0);
+ 	    }
+ 	}
+     }


Property changes on: trunk/debian/patches/debian/916_add_XKBPATH_env_variable.diff
___________________________________________________________________
Name: svn:keywords
   + Id

Modified: trunk/debian/patches/series
===================================================================
--- trunk/debian/patches/series	2005-09-03 20:48:30 UTC (rev 593)
+++ trunk/debian/patches/series	2005-09-07 21:48:43 UTC (rev 594)
@@ -158,6 +158,7 @@
 debian/913_debian_remove_code_ref_to_object_code_files.diff -p0
 debian/914_make_static_libs.diff -p0
 debian/915_disable_i915_debugging.diff -p0
+debian/916_add_XKBPATH_env_variable.diff
 debian/989_ubuntu_add_extra_modelines_from_xorg.diff -p0
 debian/990_ubuntu_accept_enabled_for_extensions.diff -p0
 debian/991_ubuntu_gcc_flags.diff -p0



Reply to: