Friday, June 20, 2008

Catalyst 8.6 on Fedora 9 x86_64

    For those of us with ATI video cards running Linux, ATI is supporting us with a Linux version of their Catalyst drivers.  They can be downloaded by going to the ATI driver download page and selecting Linux x86_64 and the video card make and model.  From there you can download the self-extracting archive which will either install the driver or build a package.
    It is always a good idea to install from a package since they are easier to update and remove than by hand.    Unfortunately there are a few errors in the package and it will not build correctly on Fedora 9.  I was able to fix these errors and get the package to build although, I cannot use the driver since it has not been updated to work with the XOrg server contained in the Fedora 9 distro. But downgrading the XOrg server is another post.
    Once you have downloaded the self-extracting archive we must extract the files so that we can patch them.  To do this we use the --extract option of the archive.
./ati-driver-installer-8-6-x86.x86_64.run --extract ati
Now that the files are extracted we must patch the .spec file that is used to specify the package build instructions.  Use ATI-fglrx.spec-tmpl.patch to patch the file fixing errors with files being included in the package but not listed as part of the installed files as well as an invalid changelog entry.
patch ./ati/packages/Fedora/ATI-fglrx.spec-tmpl < ./ATI-fglrx.spec-tmpl.patch
Next we must patch the a script used to create the directory structure for the package. There were some issues with the directories for the x86_64 build.  ati-packager.sh.patch will fix these errors allowing the package to build.
patch ./ati/packages/Fedora/ati-packager.sh < ./ati-packager.sh.patch
    Now that the files have been patched we can now build the package.
cd ati
./ati-installer.sh 8-6 --buildpkg Fedora/F9
If all works out as planned you should see messages about 5 different packages created. Congratulations you have successfully build the Fedora 9 package! Now you can use yum to install the packages.
su
yum localinstall --nogpgcheck ATI-fglrx-8.501-1.f9.x86_64.rpm
yum localinstall --nogpgcheck ATI-fglrx-control-center-8.501-1.f9.x86_64.rpm
yum localinstall --nogpgcheck ATI-fglrx-IA32-libs-8.501-1.f9.x86_64.rpm
yum localinstall --nogpgcheck kernel-module-ATI-fglrx-2.6.25.4-30.fc9.x86_64-8.501-1.f9.x86_64.rpm
exit
*Note - The ATI-fglrx-devel-8.501-1.f9.x86_64.rpm file is only required for development.
    As I said at the beginning of the post even after successfully building the Fedora 9 package, it will not work on the default Fedora 9 distro.  For the driver to work the XOrg server must be downgraded.  I have seen a few guides that describe how to downgrade the XOrg server to the version that came with Fedora 8 but I have not yet attempted this myself.

No comments: