Skip to contentSkip to conversation

Disable pulseaudio in Qt4

RFC PATCH In review Paul Eggleton 4 participants 9 messages Nov 18, 2011 – Nov 22, 2011

lore
Share & tools
lore
#0 lore raw

cover Disable pulseaudio in Qt4

We had a failure on the autobuilder because qt4-x11-free detected pulseaudio was present but then since it wasn't listed in DEPENDS, when it came to compile time pulseaudio happened to be unavailable and the build failed. At first I just added pulseaudio to DEPENDS but then I considered that it becomes a hard runtime dependency of phonon when it is enabled and many will not want that. So I'm making this an RFC, please comment.

The following changes since commit 0a815e889d056f44af1ada623b4b2edcb699693a:

mesa: fix calling host's commands (2011-11-18 14:37:09 +0000)

are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib paule/qt4-pulseaudio
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=paule/qt4-pulseaudio

Paul Eggleton (1):
qt4: disable pulseaudio

 meta/recipes-qt/qt4/files/pulseaudio-config.patch |   31 +++++++++++++++++++++
 meta/recipes-qt/qt4/qt-4.7.4.inc                  |    3 +-
 meta/recipes-qt/qt4/qt4-embedded_4.7.4.bb         |    2 +-
 meta/recipes-qt/qt4/qt4-x11-free_4.7.4.bb         |    2 +-
 4 files changed, 35 insertions(+), 3 deletions(-)
 create mode 100644 meta/recipes-qt/qt4/files/pulseaudio-config.patch
Signature · 1 line
1.7.5.4
#1 lore raw

RFC PATCH 1/1 qt4: disable pulseaudio

Disable pulseaudio support in phonon within Qt4; otherwise it auto-detects it and it may be enabled or disabled depending on what gets built first.

---
 meta/recipes-qt/qt4/files/pulseaudio-config.patch |   31 +++++++++++++++++++++
 meta/recipes-qt/qt4/qt-4.7.4.inc                  |    3 +-
 meta/recipes-qt/qt4/qt4-embedded_4.7.4.bb         |    2 +-
 meta/recipes-qt/qt4/qt4-x11-free_4.7.4.bb         |    2 +-
 4 files changed, 35 insertions(+), 3 deletions(-)
 create mode 100644 meta/recipes-qt/qt4/files/pulseaudio-config.patch
meta/recipes-qt/qt4/files/pulseaudio-config.patch new file +31 -0
new file mode 100644
index 0000000..5b32815
@@ -0,0 +1,31 @@
+# Allows disabling pulseaudio support within phonon at configure time
+# 
+# Upstream-status: pending
+#
+# Signed-off-by: Paul Eggleton <[email protected]>
+#
+--- qt-everywhere-opensource-src-4.7.4.orig/configure
++++ qt-everywhere-opensource-src-4.7.4/configure
+@@ -941,7 +941,7 @@ while [ "$#" -gt 0 ]; do
+         VAL=no
+         ;;
+     #Qt style yes options
+-    -incremental|-qvfb|-profile|-shared|-static|-sm|-xinerama|-xshape|-xsync|-xinput|-egl|-reduce-exports|-pch|-separate-debug-info|-stl|-freetype|-xcursor|-xfixes|-xrandr|-xrender|-mitshm|-fontconfig|-xkb|-nis|-qdbus|-dbus|-dbus-linked|-glib|-gstreamer|-gtkstyle|-cups|-iconv|-largefile|-h|-help|-v|-verbose|-debug|-release|-fast|-accessibility|-confirm-license|-gnumake|-framework|-qt3support|-debug-and-release|-exceptions|-cocoa|-carbon|-universal|-prefix-install|-silent|-armfpa|-optimized-qmake|-dwarf2|-reduce-relocations|-sse|-openssl|-openssl-linked|-ptmalloc|-xmlpatterns|-phonon|-phonon-backend|-multimedia|-audio-backend|-svg|-declarative|-declarative-debug|-javascript-jit|-script|-scripttools|-rpath|-force-pkg-config|-s60|-usedeffiles)
++    -incremental|-qvfb|-profile|-shared|-static|-sm|-xinerama|-xshape|-xsync|-xinput|-egl|-reduce-exports|-pch|-separate-debug-info|-stl|-freetype|-xcursor|-xfixes|-xrandr|-xrender|-mitshm|-fontconfig|-xkb|-nis|-qdbus|-dbus|-dbus-linked|-glib|-gstreamer|-pulseaudio|-gtkstyle|-cups|-iconv|-largefile|-h|-help|-v|-verbose|-debug|-release|-fast|-accessibility|-confirm-license|-gnumake|-framework|-qt3support|-debug-and-release|-exceptions|-cocoa|-carbon|-universal|-prefix-install|-silent|-armfpa|-optimized-qmake|-dwarf2|-reduce-relocations|-sse|-openssl|-openssl-linked|-ptmalloc|-xmlpatterns|-phonon|-phonon-backend|-multimedia|-audio-backend|-svg|-declarative|-declarative-debug|-javascript-jit|-script|-scripttools|-rpath|-force-pkg-config|-s60|-usedeffiles)
+         VAR=`echo $1 | sed "s,^-\(.*\),\1,"`
+         VAL=yes
+         ;;
+@@ -1866,6 +1866,13 @@ while [ "$#" -gt 0 ]; do
+             UNKNOWN_OPT=yes
+         fi
+         ;;
++    pulseaudio)
++        if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then
++            CFG_PULSEAUDIO="$VAL"
++        else
++            UNKNOWN_OPT=yes
++        fi
++        ;;
+     gtkstyle)
+         if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then
+             CFG_QGTKSTYLE="$VAL"
meta/recipes-qt/qt4/qt-4.7.4.inc +2 -1
index bc33b6b..bd3409c 100644
@@ -17,6 +17,7 @@ SRC_URI = "http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-${PV}.
            file://g++.conf \
            file://linux.conf \
            file://fix-qtbug-20925.patch \
+           file://pulseaudio-config.patch \
            "
 
 SRC_URI[md5sum] = "9831cf1dfa8d0689a06c2c54c5c65aaf"
@@ -43,7 +44,7 @@ do_configure_prepend() {
 }
 
 QT_GLFLAGS ?= ""
-QT_CONFIG_FLAGS += " -xmlpatterns -no-rpath -qt3support -reduce-relocations -silent ${QT_GLFLAGS}"
+QT_CONFIG_FLAGS += " -xmlpatterns -no-rpath -qt3support -reduce-relocations --disable-pulseaudio -silent ${QT_GLFLAGS}"
 
 do_compile() {
     # Fixup missing wsegl header in some SGX SDKs
meta/recipes-qt/qt4/qt4-embedded_4.7.4.bb +1 -1
index e34ec8d..6b9f97a 100644
@@ -1,7 +1,7 @@
 require qt-${PV}.inc
 require qt4-embedded.inc
 
-PR = "${INC_PR}.3"
+PR = "${INC_PR}.4"
 
 QT_CONFIG_FLAGS_append_armv6-vfp = " -no-neon "
 
meta/recipes-qt/qt4/qt4-x11-free_4.7.4.bb +1 -1
index 8c48936..0db090f 100644
@@ -1,7 +1,7 @@
 require qt4-x11-free.inc
 require qt-${PV}.inc
 
-PR = "${INC_PR}.3"
+PR = "${INC_PR}.4"
 
 QT_CONFIG_FLAGS_append_armv6-vfp = " -no-neon "
 
Signature · 1 line
1.7.5.4
#2 lore raw

Re: [RFC PATCH 1/1] qt4: disable pulseaudio

Op 18 nov. 2011, om 16:03 heeft Paul Eggleton het volgende geschreven:

Quoted 19 lines

Disable pulseaudio support in phonon within Qt4; otherwise it auto-detects it and it may be enabled or disabled depending on what gets built first.

---

meta/recipes-qt/qt4/files/pulseaudio-config.patch |   31 +++++++++++++++++++++
meta/recipes-qt/qt4/qt-4.7.4.inc                  |    3 +-
meta/recipes-qt/qt4/qt4-embedded_4.7.4.bb         |    2 +-
meta/recipes-qt/qt4/qt4-x11-free_4.7.4.bb         |    2 +-
4 files changed, 35 insertions(+), 3 deletions(-)

create mode 100644 meta/recipes-qt/qt4/files/pulseaudio-config.patch

meta/recipes-qt/qt4/files/pulseaudio-config.patch new file +0 -0
new file mode 100644
index 0000000..5b32815

meta/recipes-qt/qt4/files/pulseaudio-config.patch line 5

Quoted 5 lines
meta/recipes-qt/qt4/files/pulseaudio-config.patch new file +5 -0
@@ -0,0 +1,31 @@
+# Allows disabling pulseaudio support within phonon at configure time
+# 
+# Upstream-status: pending
+#
+# Signed-off-by: Paul Eggleton <[email protected]>

What follows is a generic question and in no way a criticism or comment on your RFC: Have you thought about using git am'able patches for these things?Upstream for QT is using git, so it would be nice to use somethings as close to the upstream submission as we can get. I've been trying to do this for meta-oe and found it helpfull when coming back to do the actual upstream push later.

regards,

Koen

#3 lore raw

Re: [RFC PATCH 1/1] qt4: disable pulseaudio

Quoted 6 lines · On Friday 18 November 2011 16:22:37 Koen Kooi wrote:

What follows is a generic question and in no way a criticism or comment on your RFC: Have you thought about using git am'able patches for these things?Upstream for QT is using git, so it would be nice to use somethings as close to the upstream submission as we can get. I've been trying to do this for meta-oe and found it helpfull when coming back to do the actual upstream push later.

I hadn't thought about it, but anything that makes these patches easier to upstream sounds like a good idea to me, and I would have thought this particular one would definitely be a candidate so I'll do it for this one once people have had a chance to comment.

Cheers,
Paul

Signature · 2 lines
Paul Eggleton
Intel Open Source Technology Centre
#4 lore raw

Re: [RFC PATCH 1/1] qt4: disable pulseaudio

Quoted 8 lines · Paul Eggleton
Quoted 6 lines · On Friday 18 November 2011 16:22:37 Koen Kooi wrote:

What follows is a generic question and in no way a criticism or comment on your RFC: Have you thought about using git am'able patches for these things?Upstream for QT is using git, so it would be nice to use somethings as close to the upstream submission as we can get. I've been trying to do this for meta-oe and found it helpfull when coming back to do the actual upstream push later.

Quoted 4 lines

I hadn't thought about it, but anything that makes these patches easier to upstream sounds like a good idea to me, and I would have thought this particular one would definitely be a candidate so I'll do it for this one once people have had a chance to comment.

I think this needs to be a distro option, not enforced.

I agree this needs to be explicitly added or removed but I'd like it to be optional ... many embedded systems now depends on pulseaudio and if one is using it, phonon ought to use it too.

Signature · 3 lines
Otavio Salvador                             O.S. Systems
E-mail: [email protected]  http://www.ossystems.com.br
Mobile: +55 53 9981-7854              http://projetos.ossystems.com.br
#5 lore raw

Re: [RFC PATCH 1/1] qt4: disable pulseaudio

Quoted 5 lines · On Saturday 19 November 2011 12:55:04 Otavio Salvador wrote:

I think this needs to be a distro option, not enforced.

I agree this needs to be explicitly added or removed but I'd like it to be optional ... many embedded systems now depends on pulseaudio and if one is using it, phonon ought to use it too.

So, is this a DISTRO_FEATURE? Or do we use PACKAGECONFIG?

Cheers,
Paul

Signature · 2 lines
Paul Eggleton
Intel Open Source Technology Centre
#6 lore raw

Re: [RFC PATCH 1/1] qt4: disable pulseaudio

Quoted 8 lines · Paul Eggleton
Quoted 5 lines · On Saturday 19 November 2011 12:55:04 Otavio Salvador wrote:

I think this needs to be a distro option, not enforced.

I agree this needs to be explicitly added or removed but I'd like it to be optional ... many embedded systems now depends on pulseaudio and if one is using it, phonon ought to use it too.

So, is this a DISTRO_FEATURE? Or do we use PACKAGECONFIG?

I'd say it is a distro feature.

Signature · 3 lines
Otavio Salvador                             O.S. Systems
E-mail: [email protected]  http://www.ossystems.com.br
Mobile: +55 53 9981-7854              http://projetos.ossystems.com.br
#7 lore raw

Re: [RFC PATCH 1/1] qt4: disable pulseaudio

In reply to Paul Eggleton
Quoted 19 lines · Paul Eggleton

Disable pulseaudio support in phonon within Qt4; otherwise it auto-detects it and it may be enabled or disabled depending on what gets built first.

---
  meta/recipes-qt/qt4/files/pulseaudio-config.patch |   31 +++++++++++++++++++++
  meta/recipes-qt/qt4/qt-4.7.4.inc                  |    3 +-
  meta/recipes-qt/qt4/qt4-embedded_4.7.4.bb         |    2 +-
  meta/recipes-qt/qt4/qt4-x11-free_4.7.4.bb         |    2 +-
  4 files changed, 35 insertions(+), 3 deletions(-)

create mode 100644 meta/recipes-qt/qt4/files/pulseaudio-config.patch

meta/recipes-qt/qt4/files/pulseaudio-config.patch new file +0 -0
new file mode 100644
index 0000000..5b32815

meta/recipes-qt/qt4/files/pulseaudio-config.patch line 4

Quoted 4 lines
meta/recipes-qt/qt4/files/pulseaudio-config.patch new file +4 -0
@@ -0,0 +1,31 @@
+# Allows disabling pulseaudio support within phonon at configure time
+#
+# Upstream-status: pending
+#

Small nit-pick here, status start with Caps, so this should be Pending

Sau!

Quoted 74 lines
meta/recipes-qt/qt4/files/pulseaudio-config.patch new file +27 -0
+# Signed-off-by: Paul Eggleton<[email protected]>
+#
+--- qt-everywhere-opensource-src-4.7.4.orig/configure
++++ qt-everywhere-opensource-src-4.7.4/configure
+@@ -941,7 +941,7 @@ while [ "$#" -gt 0 ]; do
+         VAL=no
+         ;;
+     #Qt style yes options
+-    -incremental|-qvfb|-profile|-shared|-static|-sm|-xinerama|-xshape|-xsync|-xinput|-egl|-reduce-exports|-pch|-separate-debug-info|-stl|-freetype|-xcursor|-xfixes|-xrandr|-xrender|-mitshm|-fontconfig|-xkb|-nis|-qdbus|-dbus|-dbus-linked|-glib|-gstreamer|-gtkstyle|-cups|-iconv|-largefile|-h|-help|-v|-verbose|-debug|-release|-fast|-accessibility|-confirm-license|-gnumake|-framework|-qt3support|-debug-and-release|-exceptions|-cocoa|-carbon|-universal|-prefix-install|-silent|-armfpa|-optimized-qmake|-dwarf2|-reduce-relocations|-sse|-openssl|-openssl-linked|-ptmalloc|-xmlpatterns|-phonon|-phonon-backend|-multimedia|-audio-backend|-svg|-declarative|-declarative-debug|-javascript-jit|-script|-scripttools|-rpath|-force-pkg-config|-s60|-usedeffiles)
++    -incremental|-qvfb|-profile|-shared|-static|-sm|-xinerama|-xshape|-xsync|-xinput|-egl|-reduce-exports|-pch|-separate-debug-info|-stl|-freetype|-xcursor|-xfixes|-xrandr|-xrender|-mitshm|-fontconfig|-xkb|-nis|-qdbus|-dbus|-dbus-linked|-glib|-gstreamer|-pulseaudio|-gtkstyle|-cups|-iconv|-largefile|-h|-help|-v|-verbose|-debug|-release|-fast|-accessibility|-confirm-license|-gnumake|-framework|-qt3support|-debug-and-release|-exceptions|-cocoa|-carbon|-universal|-prefix-install|-silent|-armfpa|-optimized-qmake|-dwarf2|-reduce-relocations|-sse|-openssl|-openssl-linked|-ptmalloc|-xmlpatterns|-phonon|-phonon-backend|-multimedia|-audio-backend|-svg|-declarative|-declarative-debug|-javascript-jit|-script|-scripttools|-rpath|-force-pkg-config|-s60|-usedeffiles)
+         VAR=`echo $1 | sed "s,^-\(.*\),\1,"`
+         VAL=yes
+         ;;
+@@ -1866,6 +1866,13 @@ while [ "$#" -gt 0 ]; do
+             UNKNOWN_OPT=yes
+         fi
+         ;;
++    pulseaudio)
++        if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then
++            CFG_PULSEAUDIO="$VAL"
++        else
++            UNKNOWN_OPT=yes
++        fi
++        ;;
+     gtkstyle)
+         if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then
+             CFG_QGTKSTYLE="$VAL"
meta/recipes-qt/qt4/qt-4.7.4.inc +2 -1
index bc33b6b..bd3409c 100644
@@ -17,6 +17,7 @@ SRC_URI = "http://get.qt.nokia.com/qt/source/qt-everywhere-opensource-src-${PV}.
             file://g++.conf \
             file://linux.conf \
             file://fix-qtbug-20925.patch \
+           file://pulseaudio-config.patch \
             "
 
  SRC_URI[md5sum] = "9831cf1dfa8d0689a06c2c54c5c65aaf"
@@ -43,7 +44,7 @@ do_configure_prepend() {
  }
 
  QT_GLFLAGS ?= ""
-QT_CONFIG_FLAGS += " -xmlpatterns -no-rpath -qt3support -reduce-relocations -silent ${QT_GLFLAGS}"
+QT_CONFIG_FLAGS += " -xmlpatterns -no-rpath -qt3support -reduce-relocations --disable-pulseaudio -silent ${QT_GLFLAGS}"
 
  do_compile() {
      # Fixup missing wsegl header in some SGX SDKs
meta/recipes-qt/qt4/qt4-embedded_4.7.4.bb +1 -1
index e34ec8d..6b9f97a 100644
@@ -1,7 +1,7 @@
  require qt-${PV}.inc
  require qt4-embedded.inc
 
-PR = "${INC_PR}.3"
+PR = "${INC_PR}.4"
 
  QT_CONFIG_FLAGS_append_armv6-vfp = " -no-neon "
 
meta/recipes-qt/qt4/qt4-x11-free_4.7.4.bb +1 -1
index 8c48936..0db090f 100644
@@ -1,7 +1,7 @@
  require qt4-x11-free.inc
  require qt-${PV}.inc
 
-PR = "${INC_PR}.3"
+PR = "${INC_PR}.4"
 
  QT_CONFIG_FLAGS_append_armv6-vfp = " -no-neon "
 
#8 lore raw

Re: [RFC PATCH 1/1] qt4: disable pulseaudio

Quoted 5 lines · On Tuesday 22 November 2011 12:45:30 Saul Wold wrote:

Review

Quoted 2 lines · Paul Eggleton
(quoted diff) +2 -0
+# Upstream-status: pending
+#

Small nit-pick here, status start with Caps, so this should be Pending

OK, when I rework this as a DISTRO_FEATURE I will fix this up as well.

Cheers,
Paul

Signature · 2 lines
Paul Eggleton
Intel Open Source Technology Centre