Upgrading to LibreOffice 4.0 on Fedora 18

LibreOffice 4.0 was recently released with many new features. Fedora 18 comes with 3.6 and does not have 4.0 available in the repositories for upgrading. So how do we get LibreOffice 4.0 installed on Fedora 18? Well that’s what we are going to discuss here. So here is how it is done.

First we need to remove the current LibreOffice packages. Using the handy rpm command it is easy to find.

Note: Your version of LibreOffice may vary with the command below so adjust as needed on the yum remove command.

$ sudo rpm -qa | grep -i libreoffice
libreoffice-presenter-screen-3.6.6.2-9.fc18.x86_64
libreoffice-writer-3.6.6.2-9.fc18.x86_64
libreoffice-kde-3.6.6.2-9.fc18.x86_64
libreoffice-opensymbol-fonts-3.6.6.2-9.fc18.noarch
libreoffice-math-3.6.6.2-9.fc18.x86_64
libreoffice-graphicfilter-3.6.6.2-9.fc18.x86_64
libreoffice-core-3.6.6.2-9.fc18.x86_64
libreoffice-calc-3.6.6.2-9.fc18.x86_64
libreoffice-pdfimport-3.6.6.2-9.fc18.x86_64
libreoffice-ure-3.6.6.2-9.fc18.x86_64
libreoffice-xsltfilter-3.6.6.2-9.fc18.x86_64
libreoffice-langpack-en-3.6.6.2-9.fc18.x86_64
libreoffice-draw-3.6.6.2-9.fc18.x86_64
libreoffice-impress-3.6.6.2-9.fc18.x86_64

As we can see we have a few packages to remove. So in one line we type them (copy paste is must quicker):

$ sudo yum remove libreoffice-presenter-screen-3.6.6.2-9.fc18.x86_64 libreoffice-writer-3.6.6.2-9.fc18.x86_64 libreoffice-kde-3.6.6.2-9.fc18.x86_64 libreoffice-opensymbol-fonts-3.6.6.2-9.fc18.noarch libreoffice-math-3.6.6.2-9.fc18.x86_64 libreoffice-graphicfilter-3.6.6.2-9.fc18.x86_64 libreoffice-core-3.6.6.2-9.fc18.x86_64 libreoffice-calc-3.6.6.2-9.fc18.x86_64 libreoffice-pdfimport-3.6.6.2-9.fc18.x86_64 libreoffice-ure-3.6.6.2-9.fc18.x86_64 libreoffice-xsltfilter-3.6.6.2-9.fc18.x86_64 libreoffice-langpack-en-3.6.6.2-9.fc18.x86_64 libreoffice-draw-3.6.6.2-9.fc18.x86_64 libreoffice-impress-3.6.6.2-9.fc18.x86_64

Next, download the latest LibreOffice 4.0 from http://www.libreoffice.org/download

Extract the downloaded file:

$ tar -xzvf LibreOffice_4.0.4_Linux_x86-64_rpm.tar.gz

Change to the directory:

$ cd LibreOffice_4.0.4.2_Linux_x86-64_rpm/RPMS

Install the new RPM packages:

$ su -c 'yum install *.rpm'

Now we need to install the menu entries on the system, the files are under the desktop-integration folder:

$ cd desktop-integration
$ su -c 'yum install libreoffice4.0-freedesktop-menus-4.0.4-2.noarch.rpm'

Give the system time to refresh the menus and the shortcuts will be in the same place as the old ones and you are ready to go!