qtdeclarative5-qtquick2-plugin should depend on libgl1-mesa-dri

Bug #1176199 reported by Albert Astals Cid
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
qtdeclarative-opensource-src (Ubuntu)
Fix Released
Undecided
Timo Jyrinki

Bug Description

In the Unity Shell team we have found that running qtdeclarative5-qtquick2-plugin without libgl1-mesa-dri can lead to unexpected crashes when Qt tries to use VBO, we should provide a runtime dependency for it so other people don't stumble on the same issue and lose the same amount of time we did trying to figure what's wrong

Revision history for this message
Timo Jyrinki (timo-jyrinki) wrote :

Committed a fix to the packaging and put a raring build into qt5-beta-proper. I'd like to understand the problem itself a bit more closely though.

Changed in qtdeclarative-opensource-src (Ubuntu):
assignee: nobody → Timo Jyrinki (timo-jyrinki)
status: New → In Progress
status: In Progress → Fix Committed
Revision history for this message
Albert Astals Cid (aacid) wrote :

Ok, here comes my analysis:

 QSGRenderer::draw contains code like

    if (g->indexDataPattern() != QSGGeometry::AlwaysUploadPattern && g->indexCount() > 512) {
        // Base pointer for a VBO is 0
        indexData = 0;
        ...
    } else {
       ...
    }
    ....
    // draw the stuff...
    ...
    glDrawElements(g->drawingMode(), g->indexCount(), g->indexType(), indexData);

So in some cases uses a VBO passing indexData as 0

Without having libgl1-mesa-dri installed that crashes, with it installed it does not. My guess is that libgl1-mesa-dri adds VBO support and thus can interpret the 0 in indexData as a VBO instead of simply trying to access a NULL pointer

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qtdeclarative-opensource-src - 5.0.2-1ubuntu1

---------------
qtdeclarative-opensource-src (5.0.2-1ubuntu1) saucy; urgency=low

  [ Timo Jyrinki ]
  * debian/patches/we_do_want_the_mouse_event_to_ourselves.patch:
    - Drop, merged upstream
  * debian/patches/fix_lp1087643.patch:
    - Drop, merged upstream
  * Merge with Debian experimental, remaining changes:
    - Keep architecture restrictions
    - Keep debian/patches/rendering_performance_fix_lp1092358.patch
  * Add libgl1-mesa-dri dependency for the quick2 plugin (LP: #1176199)
  * Cherry-pick listview crasher fixes from upstream 5.1 branch (LP: #1176962):
    - debian/patches/01_8563adb737cec5d440197ddbd514fe201c5f18ff_backport.patch
    - debian/patches/02_53e317468626284fe26877659dff551ce3bc0e55_backport.patch
    - debian/patches/03_51665a9ecaebaef2382c1e76ebedfeffacb4b3de_backport.patch
    - debian/patches/04_9d6cd72353e4862592c016951810abf9a7ab8079_backport.patch

  [ Lisandro Damián Nicanor Pérez Meyer ]
  * Fix wrong permissions of examples.

qtdeclarative-opensource-src (5.0.2-1) experimental; urgency=low

  * Initial release. (Closes: #697509)
 -- Timo Jyrinki <email address hidden> Mon, 29 Apr 2013 16:27:13 -0700

Changed in qtdeclarative-opensource-src (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Dimitri John Ledkov (xnox) wrote :

This dependency has unwanted consequences, as on ubuntu-touch (armhf, amd64, i386) or ubuntu-desktop (non-free drivers) mesa is not providing the gl implementation. It's managed by seeds else-wise, e.g. ubuntu-drivers-common / per-device seeds. Essentially, installations that do not have a valid gl implementation provided will not work, but it's not qtdeclarative5-qtquick2-plugin to pull one in, as it doesn't know which one it should be pulling in (e.g. hybris, mesa, nvidia, etc.).

How was the machine installed which didn't have any valid gl implementation available? Or alternatively, does qtdeclrative-opensource-src needs fixing / checking to work correctly with all gl implementations we care about? (android/hybris, mesa (native), nvidiat / ati). Cause libgl1-mesa-dri results in pulling in software Gallium3D rendereing on to ubuntu-touch devices which is about 40MB of dependencies, none of which we'd want to run (ever).

Revision history for this message
Albert Astals Cid (aacid) wrote :

This was on the CI machines, no clue how they are installed.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.