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

X Strike Force XFree86 SVN commit: r1328 - in trunk/debian: . local/Xsession.d



Author: branden
Date: 2004-04-28 11:12:46 -0500 (Wed, 28 Apr 2004)
New Revision: 1328

Modified:
   trunk/debian/changelog
   trunk/debian/local/Xsession.d/30xfree86-common_xresources
Log:
Fix 30xfree86-common_xresources Xsession script to check for existence of
xrdb command before attempting to execute it, and warn if it is not found
(thanks, Ryan Murray).  (Closes: #242485)


Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog	2004-04-28 15:46:17 UTC (rev 1327)
+++ trunk/debian/changelog	2004-04-28 16:12:46 UTC (rev 1328)
@@ -1,8 +1,10 @@
 xfree86 (4.3.0.dfsg.1-SVN) unstable; urgency=low
 
-  * Dummy changelog entry.  Replace me with real content.
+  * Fix 30xfree86-common_xresources Xsession script to check for existence of
+    xrdb command before attempting to execute it, and warn if it is not found
+    (thanks, Ryan Murray).  (Closes: #242485)
 
- -- Branden Robinson <branden@debian.org>  Wed, 28 Apr 2004 10:35:39 -0500
+ -- Branden Robinson <branden@debian.org>  Wed, 28 Apr 2004 11:09:16 -0500
 
 xfree86 (4.3.0.dfsg.1-1) unstable; urgency=low
 

Modified: trunk/debian/local/Xsession.d/30xfree86-common_xresources
===================================================================
--- trunk/debian/local/Xsession.d/30xfree86-common_xresources	2004-04-28 15:46:17 UTC (rev 1327)
+++ trunk/debian/local/Xsession.d/30xfree86-common_xresources	2004-04-28 16:12:46 UTC (rev 1328)
@@ -2,19 +2,27 @@
 
 # This file is sourced by Xsession(5), not executed.
 
-if [ -d "$SYSRESOURCES" ]; then
-  RESOURCEFILES=$(run_parts $SYSRESOURCES)
-  if [ -n "$RESOURCEFILES" ]; then
-    for RESOURCEFILE in $RESOURCEFILES; do
-      xrdb -merge $RESOURCEFILE
-    done
+# If xrdb (from xbase-clients) is installed, merge system-wide X resources.
+# Then merge the user's X resources, if the options file is so configured.
+if which xrdb >/dev/null 2>&1; then
+  if [ -d "$SYSRESOURCES" ]; then
+    RESOURCEFILES=$(run_parts $SYSRESOURCES)
+    if [ -n "$RESOURCEFILES" ]; then
+      for RESOURCEFILE in $RESOURCEFILES; do
+        xrdb -merge $RESOURCEFILE
+      done
+    fi
   fi
-fi
 
-if grep -qs ^allow-user-resources "$OPTIONFILE"; then
-  if [ -f "$USRRESOURCES" ]; then
-    xrdb -merge $USRRESOURCES
+  if grep -qs ^allow-user-resources "$OPTIONFILE"; then
+    if [ -f "$USRRESOURCES" ]; then
+      xrdb -merge $USRRESOURCES
+    fi
   fi
+else
+  # Comment out this command if you desire a legacy-free X environment, and find
+  # the warning spurious.
+  message "warning: xrdb command not found; X resources not merged."
 fi
 
 # vim:set ai et sts=2 sw=2 tw=80:



Reply to: