How can I update the Ubuntu SDK preview from the Qt 5 Beta PPA to the Qt 5 Release PPA

Solution 1:

During the migration from the Qt 5 Beta to the Qt 5 Release, the packaging changed significantly. This means upgrading the SDK is not a trivial task such as sudo apt-get upgrade, and a few manual steps are necessary.

Migration: from the Qt 5 Beta 1 to Qt 5.0

  1. Open the ~/.bashrc file

    $ gedit ~/.bashrc

  2. Remove the 'export PATH=/opt/qt5/bin:$PATH' line from the ~/.bashrc file

  3. Uninstall Qt Creator temporarily

    $ sudo apt-get remove qtcreator qt4-qmlviewer

  4. Purge the Qt 5 Beta 1 PPA

    $ sudo apt-get install ppa-purge

    $ sudo ppa-purge ppa:canonical-qt5-edgers/qt5-beta1

  5. Install the Ubuntu SDK preview

    $ sudo add-apt-repository ppa:ubuntu-sdk-team/ppa && sudo add-apt-repository ppa:canonical-qt5-edgers/qt5-proper && sudo apt-get update && sudo apt-get install ubuntu-sdk notepad-qml

  6. Test that the Component Showcase app can be executed:

    $ qmlscene /usr/lib/qt-components-ubuntu/demos/ComponentShowcase.qml

Solution 2:

In case the step 4. does not remove all the packages from the qt5-beta1 PPA the line helped me to clean up was this:

$ grep ^Package: /var/lib/apt/lists/ppa.launchpad.net*sdk*Packages /var/lib/apt/lists/ppa.launchpad.net*qt5-beta1*Packages |awk '{print $2}'|xargs sudo apt-get -y remove

You can execute the same command and replace the "apt-get -y remove" to "sudo dpkg --purge" to purge the possible leftovers after apt-get.

Solution 3:

@sil: sudo apt-get install qt-components-ubuntu will install the missing components.

Cheers,