MantisBT - CMake
View Issue Details
0013254CMakeModulespublic2012-05-29 15:592012-10-01 13:23
Kurtis Nusbaum 
Clinton Stimpson 
normalminoralways
closedfixed 
WindowsWindowsWindows 7
 
 
0013254: phonon_ds9 backend plugin not found on windows.
I'm deploying a Qt application which uses phonon on windows. For some reason, the DeployQt4.cmake module wasn't finding the phonon_ds9 backend plugin that is standard with windows installations of Qt4. More specifically (and was I'm almost positive this was what was tripping up DeployQt4), the QT_PHONON_DS9_PLUGIN_RELEASE variable was not set. I went and looked at the FindQt4.cmake file and found this line (it's line 1062 on cmake release 2.8.8):

set( QT_PHONON_BACKEND_PLUGINS phonon_qt7 )

phonon_qt7 is the phonon backend used exclusively on mac. Sure enough, changing the line to

set( QT_PHONON_BACKEND_PLUGINS phonon_ds9 )

resulted in the variable QT_PHONON_DS9_PLUGIN_RELEASE and QT_PHONON_DS9_PLUGIN_DEBUG being set to the correct libraries and DeployQt4 module finding the phonon_ds9 plugin and successfully bundling it with my application. I think this is a bug in FindQt4.cmake
1. Create an application that uses the phonon backend for Qt.
2. Use DeployQt and pass phonon_ds9 and the plugin argument when calling install_qt4_executable function.
Attached is a patch that does a mediocre job at addressing the issue. It basically, if it detects you're building for an APPLE machine it sets the phonon backend plugin variable to phonon_qt7 and if you're on windows it sets the variable to phonon_ds9. This obviously doesn't take into account all the other possible phonon backend situations. A more rigorous fix would address detecting the presence of other phonon backends.
No tags attached.
patch 0001-Added-conditional-for-the-phonon-backend-plugin.-If-.patch (1,421) 2012-05-29 15:59
https://public.kitware.com/Bug/file/4338/0001-Added-conditional-for-the-phonon-backend-plugin.-If-.patch
patch 0001-phonon-backend-tweak.patch (1,416) 2012-05-29 16:52
https://public.kitware.com/Bug/file/4339/0001-phonon-backend-tweak.patch
Issue History
2012-05-29 15:59Kurtis NusbaumNew Issue
2012-05-29 15:59Kurtis NusbaumFile Added: 0001-Added-conditional-for-the-phonon-backend-plugin.-If-.patch
2012-05-29 16:06David ColeAssigned To => Clinton Stimpson
2012-05-29 16:06David ColeStatusnew => assigned
2012-05-29 16:07David ColeNote Added: 0029581
2012-05-29 16:49Clinton StimpsonNote Added: 0029582
2012-05-29 16:52Kurtis NusbaumFile Added: 0001-phonon-backend-tweak.patch
2012-05-29 16:52Kurtis NusbaumNote Added: 0029583
2012-05-29 16:58Clinton StimpsonNote Added: 0029584
2012-05-29 16:58Clinton StimpsonStatusassigned => resolved
2012-05-29 16:58Clinton StimpsonResolutionopen => fixed
2012-10-01 13:23David ColeNote Added: 0031137
2012-10-01 13:23David ColeStatusresolved => closed

Notes
(0029581)
David Cole   
2012-05-29 16:07   
Clint, does this patch look reasonable, or should there be some additional elseif clauses? Any other suggestions?
(0029582)
Clinton Stimpson   
2012-05-29 16:49   
Can you tweak that patch to the following?

+ IF(APPLE)
+ SET( QT_PHONON_BACKEND_PLUGINS phonon_qt7 )
+ ELSEIF(WIN32)
+ SET( QT_PHONON_BACKEND_PLUGINS phonon_ds9 )
+ ENDIF()

Its an improvement, and there are multiple possible backends on Linux... so that will take more work to figure out.
I didn't see an easy way to detect phonon plugins.
(0029583)
Kurtis Nusbaum   
2012-05-29 16:52   
Uploaded the tweaked patch.
(0029584)
Clinton Stimpson   
2012-05-29 16:58   
http://cmake.org/gitweb?p=cmake.git;a=commit;h=ad7c80 [^]
(0031137)
David Cole   
2012-10-01 13:23   
Closing resolved issues that have not been updated in more than 4 months.