summaryrefslogtreecommitdiff
path: root/Xprint
diff options
context:
space:
mode:
authorRoland Mainz <roland.mainz@nrubsig.org>2004-08-11 13:55:03 +0000
committerRoland Mainz <roland.mainz@nrubsig.org>2004-08-11 13:55:03 +0000
commitca458e3c9b25c3efc10532eb8e31bdcff44dc321 (patch)
tree538b6611b73e5dab916b150e59f2ce09141b5f8d /Xprint
parent81881b96861d707b0729e0146a4b53b3dd234885 (diff)
Fix for http://freedesktop.org/bugzilla/show_bug.cgi?id=492 -
/etc/init.d/xprint did not source xorg.conf for font paths additionally to xfree86 config files
Diffstat (limited to 'Xprint')
-rw-r--r--Xprint/etc/init.d/xprint.cpp29
1 files changed, 22 insertions, 7 deletions
diff --git a/Xprint/etc/init.d/xprint.cpp b/Xprint/etc/init.d/xprint.cpp
index 51fb89cca..40ab6fbae 100644
--- a/Xprint/etc/init.d/xprint.cpp
+++ b/Xprint/etc/init.d/xprint.cpp
@@ -263,17 +263,32 @@ get_fontlist_from_all_xfs_configs()
get_fontlist_from_xf86config()
{
- srcxf86configfile=""
- [ -f "/etc/X11/XF86Config-4" ] && srcxf86configfile="/etc/X11/XF86Config-4"
- [ -f "/etc/X11/XF86Config" ] && srcxf86configfile="/etc/X11/XF86Config"
-
-
- if [ "${srcxf86configfile}" = "" ] ; then
+ srcxconf=""
+
+ XCOMM see xorg.conf(5x) manual page for the list of locations used here
+ [ "${srcxconf}" = "" -a -f "/etc/X11/xorg.conf" ] && srcxconf="/etc/X11/xorg.conf"
+ [ "${srcxconf}" = "" -a -f "/usr/X11R6/etc/X11/xorg.conf" ] && srcxconf="/usr/X11R6/etc/X11/xorg.conf"
+ [ "${srcxconf}" = "" -a -f "/etc/X11/xorg.conf-4" ] && srcxconf="/etc/X11/xorg.conf-4"
+ [ "${srcxconf}" = "" -a -f "/etc/X11/xorg.conf" ] && srcxconf="/etc/X11/xorg.conf"
+ [ "${srcxconf}" = "" -a -f "/etc/xorg.conf" ] && srcxconf="/etc/xorg.conf"
+ [ "${srcxconf}" = "" -a -f "/usr/X11R6/etc/X11/xorg.conf.${hostname}" ] && srcxconf="/usr/X11R6/etc/X11/xorg.conf.${hostname}"
+ [ "${srcxconf}" = "" -a -f "/usr/X11R6/etc/X11/xorg.conf-4" ] && srcxconf="/usr/X11R6/etc/X11/xorg.conf-4"
+ [ "${srcxconf}" = "" -a -f "/usr/X11R6/etc/X11/xorg.conf" ] && srcxconf="/usr/X11R6/etc/X11/xorg.conf"
+ [ "${srcxconf}" = "" -a -f "/usr/X11R6/lib/X11/xorg.conf.${hostname}" ] && srcxconf="/usr/X11R6/lib/X11/xorg.conf.${hostname}"
+ [ "${srcxconf}" = "" -a -f "/usr/X11R6/lib/X11/xorg.conf-4" ] && srcxconf="/usr/X11R6/lib/X11/xorg.conf-4"
+ [ "${srcxconf}" = "" -a -f "/usr/X11R6/lib/X11/xorg.conf" ] && srcxconf="/usr/X11R6/lib/X11/xorg.conf"
+
+ XCOMM Xfree86 locations
+ [ "${srcxconf}" = "" -a -f "/etc/X11/XF86Config-4" ] && srcxconf="/etc/X11/XF86Config-4"
+ [ "${srcxconf}" = "" -a -f "/etc/X11/XF86Config" ] && srcxconf="/etc/X11/XF86Config"
+
+
+ if [ "${srcxconf}" = "" ] ; then
return 0
fi
currsection=""
- cat "${srcxf86configfile}" |
+ cat "${srcxconf}" |
while read i1 i2 i3 i4 ; do
# Strip "\"" from I2
i2="${i2#\"}" ; i2="${i2%\"}"