ffmpeg: fix build when DISTRO_FEATURES doesn't contain x11
PATCH 1/1 ffmpeg: fix build when DISTRO_FEATURES doesn't contain x11
If avdevice is enabled, libxv is used if it is detected by configure for the XV outdev. However, we can't depend on libxv for avdevice when DISTRO_FEATURES doesn't contain x11 as this will result in an error.
Fix this by adding a libxv dependency only when the avdevice PACKAGECONFIG is enabled and DISTRO_FEATURES contains x11. XV outdev is only one of many that are supported by avdevice so it is still useful to enable avdevice even if libxv is not available.
--- meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb +2 -1
@@ -23,11 +23,12 @@ SRC_URI[sha256sum] = "25bcedbdafadac3d09c325c1d46a51f53d858b26a260d5aed6b4f17fea PROVIDES = "libav libpostproc" DEPENDS = "alsa-lib zlib libogg yasm-native" +DEPENDS += "${@bb.utils.contains('PACKAGECONFIG', 'avdevice', bb.utils.contains('DISTRO_FEATURES', 'x11', 'libxv', '', d), '', d)}" inherit autotools pkgconfig PACKAGECONFIG ??= "avdevice avfilter gpl theora x264 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}" -PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice, libxv" +PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice" PACKAGECONFIG[avfilter] = "--enable-avfilter,--disable-avfilter" PACKAGECONFIG[faac] = "--enable-libfaac,--disable-libfaac,faac" PACKAGECONFIG[gpl] = "--enable-gpl,--disable-gpl"
Signature · 1 line
2.7.1
Quoted 19 lines · Jonathan Liu
If avdevice is enabled, libxv is used if it is detected by configure for the XV outdev. However, we can't depend on libxv for avdevice when
DISTRO_FEATURESdoesn't contain x11 as this will result in an error.Fix this by adding a libxv dependency only when the avdevice PACKAGECONFIG is enabled and
DISTRO_FEATUREScontains x11. XV outdev is only one of many that are supported by avdevice so it is still useful to enable avdevice even if libxv is not available.Signed-off-by Jonathan Liu <[email protected]>--- meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb +0
-0
meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb SRC_URI[sha256sum] = "25bcedbdafadac3d09c325c1d46a51f53d858b26a260d5aed6b4f17fea · line 31
Quoted 10 lines
meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb +2
-1@@ -23,11 +23,12 @@ SRC_URI[sha256sum] = "25bcedbdafadac3d09c325c1d46a51f53d858b26a260d5aed6b4f17fea PROVIDES = "libav libpostproc" DEPENDS = "alsa-lib zlib libogg yasm-native" +DEPENDS += "${@bb.utils.contains('PACKAGECONFIG', 'avdevice', bb.utils.contains('DISTRO_FEATURES', 'x11', 'libxv', '', d), '', d)}" inherit autotools pkgconfig PACKAGECONFIG ??= "avdevice avfilter gpl theora x264 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}" -PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice, libxv" +PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice"
bb.utils.contains didn't work in PACKAGECONFIG?
Why not
PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice, ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'libxv', '', d)"
Quoted 11 lines
meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb +0
-0PACKAGECONFIG[avfilter] = "--enable-avfilter,--disable-avfilter" PACKAGECONFIG[faac] = "--enable-libfaac,--disable-libfaac,faac" PACKAGECONFIG[gpl] = "--enable-gpl,--disable-gpl"Signature · 7 lines
2.7.1 -- _______________________________________________ Openembedded-core mailing list [email protected] http://lists.openembedded.org/mailman/listinfo/openembedded-core
Signature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
Hi Martin,
It doesn't work in PACKAGECONFIG..... that is the first thing I tried.
Regards,
Jonathan
Quoted 50 lines · Martin Jansa
Quoted 19 lines · Jonathan Liu
If avdevice is enabled, libxv is used if it is detected by configure for the XV outdev. However, we can't depend on libxv for avdevice when
DISTRO_FEATURESdoesn't contain x11 as this will result in an error.Fix this by adding a libxv dependency only when the avdevice PACKAGECONFIG is enabled and
DISTRO_FEATUREScontains x11. XV outdev is only one of many that are supported by avdevice so it is still useful to enable avdevice even if libxv is not available.Signed-off-by Jonathan Liu <[email protected]>--- meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb +0
-0meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb SRC_URI[sha256sum] = "25bcedbdafadac3d09c325c1d46a51f53d858b26a260d5aed6b4f17fea · line 31
Quoted 10 lines
meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb +2
-1@@ -23,11 +23,12 @@ SRC_URI[sha256sum] = "25bcedbdafadac3d09c325c1d46a51f53d858b26a260d5aed6b4f17fea PROVIDES = "libav libpostproc" DEPENDS = "alsa-lib zlib libogg yasm-native" +DEPENDS += "${@bb.utils.contains('PACKAGECONFIG', 'avdevice', bb.utils.contains('DISTRO_FEATURES', 'x11', 'libxv', '', d), '', d)}" inherit autotools pkgconfig PACKAGECONFIG ??= "avdevice avfilter gpl theora x264 ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}" -PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice, libxv" +PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice"bb.utils.contains didn't work in PACKAGECONFIG?
Why not
PACKAGECONFIG[avdevice] = "--enable-avdevice,--disable-avdevice, ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'libxv', '', d)"Quoted 11 lines
meta/recipes-multimedia/ffmpeg/ffmpeg_2.8.6.bb +0
-1PACKAGECONFIG[avfilter] = "--enable-avfilter,--disable-avfilter" PACKAGECONFIG[faac] = "--enable-libfaac,--disable-libfaac,faac" PACKAGECONFIG[gpl] = "--enable-gpl,--disable-gpl" --2.7.1
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core--
Martin 'JaMa' Jansa jabber: [email protected]
Quoted 2 lines · Jonathan Liu
It doesn't work in PACKAGECONFIG..... that is the first thing I tried.
I'd call that a bug, and should be simple to resolve (pass expand=True when fetching getVarFlags in the PACKAGECONFIG handling code).
Ross
Quoted 10 lines · Ross
Quoted 2 lines · Jonathan Liu
It doesn't work in PACKAGECONFIG..... that is the first thing I tried.
I'd call that a bug, and should be simple to resolve (pass expand=True when fetching getVarFlags in the PACKAGECONFIG handling code).
Ross
Feel free to submit a patch to handle the PACKAGECONFIG expansion and then I can update the fix.
Regards,
Jonathan
Quoted 8 lines
Quoted 5 lines
I'd call that a bug, and should be simple to resolve (pass expand=True when
fetching getVarFlags in the PACKAGECONFIG handling code).Ross
Feel free to submit a patch to handle the PACKAGECONFIG expansion and then I can update the fix.
I think you need to solve this in a different way altogether. Write a patch for the upstream code that turns a floating, implicit xv dependency into something that can be explicitly turned on and off, and then add a PACKAGECONFIG option for it to the recipe.
Alex
Quoted 9 lines · On 27 February 2016 at 01:43, <[email protected]> wrote:
Quoted 8 lines
Quoted 5 lines
I'd call that a bug, and should be simple to resolve (pass expand=True when
fetching getVarFlags in the PACKAGECONFIG handling code).Ross
Feel free to submit a patch to handle the PACKAGECONFIG expansion and then I can update the fix.
Quoted 6 lines
I think you need to solve this in a different way altogether. Write a patch for the upstream code that turns a floating, implicit xv dependency into something that can be explicitly turned on and off, and then add a PACKAGECONFIG option for it to the recipe.
Alex
Okay. Please disregard this patch.
I will rework into a new patch.
Regards,
Jonathan