Bug 122454 - Make upgrade scripts remove Options "xkbrules" "xfree86" lines from config file.
Make upgrade scripts remove Options "xkbrules" "xfree86" lines from config file.
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: xorg-x11 (Show other bugs)
rawhide
All Linux
medium Severity medium
: ---
: ---
Assigned To: Mike A. Harris
David Lawrence
:
Depends On:
Blocks: FC2Blocker
  Show dependency treegraph
 
Reported: 2004-05-04 14:15 EDT by Mike A. Harris
Modified: 2007-11-30 17:10 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-07-12 15:57:07 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
xorg.spec.patch (1.75 KB, patch)
2004-05-07 05:30 EDT, Warren Togami
no flags Details | Diff

  None (edit)
Description Mike A. Harris 2004-05-04 14:15:37 EDT
Modify the rpm upgrade scripts to have the X.org config file
stripped of any xkbrules option lines so that people don't get
burned on upgrades.
Comment 1 Warren Togami 2004-05-06 23:59:09 EDT
I can implement this fairly easily, but is it too late to include in FC2?
Comment 2 Warren Togami 2004-05-07 05:30:49 EDT
Created attachment 100068 [details]
xorg.spec.patch
Comment 3 Mike A. Harris 2004-05-07 07:10:08 EDT
Thanks Warren..  patch looks good, with a few minor changes to
silence potential error situations, and force mv with -f, etc.

Should be in 6.7.0-2
Comment 4 Mike A. Harris 2004-05-07 07:46:32 EDT
While doing a logic review in my head to ensure the code does the
right thing (and it did seem to do so), I had a few extra neurons
kick in and visualized a simpler solution with slightly reversed
logic.  Here's the new method using a for loop:

  for configfile in XF86Config-4 XF86Config ; do
      if [ -r $configfile ]; then
          if [ -r xorg.conf]; then
              mv -f $configfile $configfile.obsoleted
          else
              mv -f $configfile xorg.conf
          fi
      fi
  done

If the -4 file exists and is readable, then if the xorg.conf file
exists the -4 file gets renamed to obsolete.  If xorg.conf doesn't
exist, the -4 gets renamed to xorg.conf.  Next time through the
loop it tries again with the non-4 file, which will follow same
logic.  End result should be that there is 0 or 1 xorg.conf, which
is the correct file we want, and any other old files are renamed
to obsolete.

The logic seems to work, but if anyone spots any errors scream loud
as we're getting close.
Comment 5 Darin May 2004-05-11 14:35:20 EDT
Please note another ommission in the conversion scripts:

http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=121984#c3

Comment 6 Mike A. Harris 2004-07-12 15:57:07 EDT
Resolved in the latest FC2 errata.

Note You need to log in before you can comment on or make changes to this bug.