From a1bae63dc634a5a79861eab128c63506081f7ed9 Mon Sep 17 00:00:00 2001 From: Dan Nicholson Date: Sat, 3 Apr 2010 09:33:49 -0700 Subject: [PATCH] xfree86: Set a saner search path for xorg.conf.d There's no reason to carry all the oddities from xorg.conf like appended hostname to the search path for xorg.conf.d. This changes it to something very simple: /etc/X11/ $sysconfdir/X11/ /etc/X11/xorg.conf.d $sysconfdir/X11/xorg.conf.d Signed-off-by: Dan Nicholson Signed-off-by: Peter Hutterer --- cpprules.in | 1 + hw/xfree86/common/xf86Config.c | 16 ++++------------ hw/xfree86/doc/man/xorg.conf.man.pre | 22 ++++------------------ 3 files changed, 9 insertions(+), 30 deletions(-) diff --git a/cpprules.in b/cpprules.in index 301305e58..6e435785a 100644 --- a/cpprules.in +++ b/cpprules.in @@ -34,6 +34,7 @@ MANDEFS = \ -D__adminmansuffix__=$(ADMIN_MAN_SUFFIX) \ -D__mandir__=$(mandir) \ -D__projectroot__=$(prefix) \ + -D__sysconfdir__=$(sysconfdir) \ -D__datadir__=$(datadir) \ -D__xconfigfile__=$(__XCONFIGFILE__) \ -D__xconfigdir__=$(__XCONFIGDIR__) \ diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c index 718a07860..d02c22ac1 100644 --- a/hw/xfree86/common/xf86Config.c +++ b/hw/xfree86/common/xf86Config.c @@ -97,20 +97,12 @@ extern DeviceAssocRec mouse_assoc; #endif #ifndef ROOT_CONFIGDIRPATH #define ROOT_CONFIGDIRPATH "%A," "%R," \ - "/etc/X11/%R," "%P/etc/X11/%R," \ - "/etc/X11/%X-%M," "/etc/X11/%X," "/etc/%X," \ - "%P/etc/X11/%X.%H," "%P/etc/X11/%X-%M," \ - "%P/etc/X11/%X," \ - "%P/lib/X11/%X.%H," "%P/lib/X11/%X-%M," \ - "%P/lib/X11/%X" + "/etc/X11/%R," "%C/X11/%R," \ + "/etc/X11/%X," "%C/X11/%X" #endif #ifndef USER_CONFIGDIRPATH -#define USER_CONFIGDIRPATH "/etc/X11/%S," "%P/etc/X11/%S," \ - "/etc/X11/%X-%M," "/etc/X11/%X," "/etc/%X," \ - "%P/etc/X11/%X.%H," "%P/etc/X11/%X-%M," \ - "%P/etc/X11/%X," \ - "%P/lib/X11/%X.%H," "%P/lib/X11/%X-%M," \ - "%P/lib/X11/%X" +#define USER_CONFIGDIRPATH "/etc/X11/%R," "%C/X11/%R," \ + "/etc/X11/%X," "%C/X11/%X" #endif #ifndef PROJECTROOT #define PROJECTROOT "/usr/X11R6" diff --git a/hw/xfree86/doc/man/xorg.conf.man.pre b/hw/xfree86/doc/man/xorg.conf.man.pre index 9a40ce33f..acfa1caa6 100644 --- a/hw/xfree86/doc/man/xorg.conf.man.pre +++ b/hw/xfree86/doc/man/xorg.conf.man.pre @@ -107,16 +107,9 @@ directories when the server is started as a normal user: .RS 4 .nf .IR /etc/X11/ -.IR __projectroot__/etc/X11/ -.I /etc/X11/__xconfigdir__\-4 +.IR __sysconfdir__/X11/ .I /etc/X11/__xconfigdir__ -.I /etc/__xconfigdir__ -.IR __projectroot__/etc/X11/__xconfigdir__. -.I __projectroot__/etc/X11/__xconfigdir__\-4 -.I __projectroot__/etc/X11/__xconfigdir__ -.IR __projectroot__/lib/X11/__xconfigdir__. -.I __projectroot__/lib/X11/__xconfigdir__\-4 -.I __projectroot__/lib/X11/__xconfigdir__ +.I __sysconfdir__/X11/__xconfigdir__ .fi .RE .PP @@ -133,16 +126,9 @@ config directory search locations are as follows: .nf .IR /etc/X11/ -.IR __projectroot__/etc/X11/ -.I /etc/X11/__xconfigdir__\-4 +.IR __sysconfdir__/X11/ .I /etc/X11/__xconfigdir__ -.I /etc/__xconfigdir__ -.IR __projectroot__/etc/X11/__xconfigdir__. -.I __projectroot__/etc/X11/__xconfigdir__\-4 -.I __projectroot__/etc/X11/__xconfigdir__ -.IR __projectroot__/lib/X11/__xconfigdir__. -.I __projectroot__/lib/X11/__xconfigdir__\-4 -.I __projectroot__/lib/X11/__xconfigdir__ +.I __sysconfdir__/X11/__xconfigdir__ .fi .RE .PP