Task #9 - How to add bad/ugly

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Task #9 - How to add bad/ugly

Task #9 - How to add bad/ugly

Bad and Ugly gstreamer plugins has their own special licensing, so it cannot be released formally inside any tarball. (I do not understand it deeply, if you want more info, please go to GStreamer: Licensing advice)

But you can add it on your own image, and you only need to change the local.conf

Please, add the following code to your local.conf:

LICENSE_FLAGS_WHITELIST = "commercial"

COMMERCIAL_AUDIO_PLUGINS ?= " \

gst-plugins-ugly-mad \

gst-plugins-ugly-mpegaudioparse \

"

COMMERCIAL_VIDEO_PLUGINS ?= " \

gst-plugins-ugly-mpeg2dec \

gst-plugins-ugly-mpegstream \

gst-plugins-bad-mpegvideoparse \

"

CORE_IMAGE_EXTRA_INSTALL += " \

packagegroup-fsl-gstreamer \

gst-plugins-base-videotestsrc \

gst-plugins-bad-fbdevsink \

gst-ffmpeg alsa-utils \

gst-plugins-good-isomp4 \

"

Please, note that this will not install *every* plugin from ugly or bad. It will only install the plugins from the list.

Go to Yocto Training - HOME

Go to Task #8 - Build kernel manually using created toolchain

Labels (1)
Comments

I try to follow your instructions but I keep getting this error:

Trying to install gst-plugins-bad-mpegtddemux and I get:

DEBUG: Executing shell function do_rootfs
| Note: configuring RPM platform settings
| Note: configuring RPM system provides
| Note: configuring RPM DB settings
| Note: configuring Smart settings
|
|
|
|
|
|
| Note: adding Smart channel nitrogen6x (80)
|
|
| Note: adding Smart channel armv7a_vfp_neon (75)
|
|
| Note: adding Smart channel all (10)
|
|
| Note: configuring RPM cross-install scriptlet_wrapper
|
| Updating cache...               ######################################## [100%]
|
| Saving cache...
|
| Note: adding Smart RPM DB channel
|
| Note: to be installed:  libsoup-2.4@armv7a_vfp_neon firmware-imx-vpu-imx6q@nitrogen6x libgtop-2.0-7@armv7a_vfp_neon rpm-postinsts@all packagegroup-core-nfs-server@all python-subprocess@armv7a_vfp_neon vbmediaserver@armv7a_vfp_neon gst-plugins-base-tcp@nitrogen6x packagegroup-fsl-gstreamer@nitrogen6x python-datetime@armv7a_vfp_neon python-json@armv7a_vfp_neon packagegroup-core-boot@nitrogen6x
| Loading cache...
| Updating cache...               ######################################## [100%]
|
| Computing transaction...error: Can't install libglib-2.0-utils-1:2.34.3-r2@armv7a_vfp_neon: no package provides /usr/local/bin/python
|
| Saving cache...
|
| ERROR: Function failed: do_rootfs (see /home/tim/imx/yocto/fsl-community-bsp/build/tmp/work/nitrogen6x-poky-linux-gnueabi/n6x-min/1.0-r0/temp/log.do_rootfs.18452 for further information)
ERROR: Task 7 (/home/tim/imx/yocto/fsl-community-bsp/sources/meta-n6x-min/recipes-fsl/images/n6x-min.bb, do_rootfs) failed with exit code '1'

Any help would be appreciated.

Thanks

Tim

Sorry for my delay.

Could you, please, let me know which branch are you using? (master or dylan?)

Hello,

Sorry for delay as well. I didn't seem to get email with notification.

I followed the steps according to:

http://www.ossystems.com.br/blog/2013/04/15/yocto-with-boundary-devices-nitrogen6x-5-steps-only

So, I assume dylan according to the post.

I need to get it resolved ASAP if you have any ideas. I have posted to Yocto forum without much support as of yet in getting it resolved.

I have verified on my host machine that /usr/local/bin/python does exist.

Thanks

Tim

how are you trying to install the package?

I tried a few different ways.

1. I tried to add gst-plugins-bad-mpegtsdemux to the packagebase (I think that is the name, I dont' have it in front of me) where the -gstreamer packages are included (gst-plugins-good-meta).

2. The above post. But I removed everything except the LICENSE_FLAGS_WHITELIST and COMMERCIAL_VIDEO_PLUGINS and I changed it to gst-plugins-bad-mpegtsdemux.

Both resulted in the same error. Can you add it to your build and see if it runs?

Tim

Any idea Daiane?

Sorry for delay ~very busy here~ :smileysad:

I will let it building over here and let you know tomorrow

OK thank you... I think it may be possible to just copy for now the mpeg2tsdemux plugin from my LTIB build for temporary fix. But, I would like to get it resolved. Please let me know what you come up with.

Thanks

Tim

Please, see my local.conf. I did build fsl-image-test (on dylan) until the end. I think you can clean some packages, or remove your tmp completely and try again.

~/fsl-community-bsp/dylan/build$ cat conf/local.conf
MACHINE ??= 'nitrogen6x'
DISTRO ?= 'poky'
PACKAGE_CLASSES ?= "package_rpm"
EXTRA_IMAGE_FEATURES = "debug-tweaks"
USER_CLASSES ?= "buildstats image-mklibs image-prelink"
PATCHRESOLVE = "noop"
BB_DISKMON_DIRS = "\
    STOPTASKS,${TMPDIR},1G,100K \
    STOPTASKS,${DL_DIR},1G,100K \
    STOPTASKS,${SSTATE_DIR},1G,100K \
    ABORT,${TMPDIR},100M,1K \
    ABORT,${DL_DIR},100M,1K \
    ABORT,${SSTATE_DIR},100M,1K"
CONF_VERSION = "1"

BB_NUMBER_THREADS = '4'
PARALLEL_MAKE = '-j 4'
ACCEPT_FSL_EULA = "1"

LICENSE_FLAGS_WHITELIST = "commercial"

COMMERCIAL_AUDIO_PLUGINS ?= " \
gst-plugins-ugly-mad \
gst-plugins-ugly-mpegaudioparse \
"

COMMERCIAL_VIDEO_PLUGINS ?= " \
    gst-plugins-ugly-mpeg2dec \
    gst-plugins-ugly-mpegstream \
    gst-plugins-bad-mpegvideoparse \
"

CORE_IMAGE_EXTRA_INSTALL += " \
    packagegroup-fsl-gstreamer \
    gst-plugins-base-videotestsrc \
    gst-plugins-bad-mpegtsdemux \
    gst-plugins-bad-fbdevsink \
    gst-ffmpeg alsa-utils \
    gst-plugins-good-isomp4 \
"

Hello Diane,

When I am running bitbake with above changes, I am getting an error for both gst-ffmpeg and gst-plugins-ugly.

The error I have pasted here is for gst-ffmpeg.

pshah9@ubuntu:~/Documents/yocto/fsl-community-bsp/build$ bitbake fsl-image-guiParsing recipes: 100% |#########################################| Time: 00:13:37

Parsing of 1278 .bb files complete (0 cached, 1278 parsed). 1646 targets, 58 skipped, 0 masked, 0 errors.

Build Configuration:

BB_VERSION        = "1.18.0"

BUILD_SYS         = "x86_64-linux"

NATIVELSBSTRING   = "Ubuntu-12.04"

TARGET_SYS        = "arm-poky-linux-gnueabi"

MACHINE           = "wandboard-dual"

DISTRO            = "poky"

DISTRO_VERSION    = "1.4.2"

TUNE_FEATURES     = "armv7a vfp neon"

TARGET_FPU        = "vfp-neon"

meta            

meta-yocto        = "wvsnp_imx6slevk1:4e399f08d596197859214fdb3b06403b87bf8789"

meta-oe           = "wvsnp_imx6slevk1:a108b2203a997634f87ac687e81712badaf3c546"

meta-fsl-arm      = "wvsnp_imx6slevk1:afe2162644544a92a517f1d51211fdcb76bb1a29"

meta-fsl-arm-extra = "wvsnp_imx6slevk1:5f5a9cfcad223f5a1c623346780510ffcdc012ab"

meta-fsl-demos    = "wvsnp_imx6slevk1:724cfb929748f47782dea3b1dc412b028f6f3515"

NOTE: Resolving any missing task queue dependencies

NOTE: multiple providers are available for jpeg (jpeg, libjpeg-turbo)

NOTE: consider defining a PREFERRED_PROVIDER entry to match jpeg

NOTE: multiple providers are available for jpeg-native (jpeg-native, libjpeg-turbo-native)

NOTE: consider defining a PREFERRED_PROVIDER entry to match jpeg-native

NOTE: Preparing runqueue

NOTE: Executing SetScene Tasks

NOTE: Executing RunQueue Tasks

ERROR: Function failed: do_configure (see /home/pshah9/Documents/yocto/fsl-community-bsp/build/tmp/work/armv7a-vfp-neon-poky-linux-gnueabi/libav/0.8.4+gitAUTOINC+2c8ce46250ff78191fe6565876ddc4bc03fdf519-r8.0/temp/log.do_configure.13483 for further information)

ERROR: Logfile of failure stored in: /home/pshah9/Documents/yocto/fsl-community-bsp/build/tmp/work/armv7a-vfp-neon-poky-linux-gnueabi/libav/0.8.4+gitAUTOINC+2c8ce46250ff78191fe6565876ddc4bc03fdf519-r8.0/temp/log.do_configure.13483

Log data follows:

| DEBUG: Executing python function sysroot_cleansstate

| DEBUG: Python function sysroot_cleansstate finished

| DEBUG: SITE files ['endian-little', 'bit-32', 'arm-common', 'common-linux', 'common-glibc', 'arm-linux', 'arm-linux-gnueabi', 'common']

| DEBUG: Executing shell function autotools_preconfigure

| Previously configured separate build directory detected, cleaning /home/pshah9/Documents/yocto/fsl-community-bsp/build/tmp/work/armv7a-vfp-neon-poky-linux-gnueabi/libav/0.8.4+gitAUTOINC+2c8ce46250ff78191fe6565876ddc4bc03fdf519-r8.0/git/build.arm-poky-linux-gnueabi.arm-poky-linux-gnueabi

| DEBUG: Shell function autotools_preconfigure finished

| DEBUG: Executing shell function do_configure

| arm-poky-linux-gnueabi-gcc is unable to create an executable file.

| C compiler test failed.

|

| If you think configure made a mistake, make sure you are using the latest

| version from Git.  If the latest version fails, report the problem to the

| libav-user@libav.org mailing list or IRC #libav on irc.freenode.net.

| Include the log file "config.log" produced by configure as this will help

| solving the problem.

| ERROR: Function failed: do_configure (see /home/pshah9/Documents/yocto/fsl-community-bsp/build/tmp/work/armv7a-vfp-neon-poky-linux-gnueabi/libav/0.8.4+gitAUTOINC+2c8ce46250ff78191fe6565876ddc4bc03fdf519-r8.0/temp/log.do_configure.13483 for further information)

ERROR: Task 1726 (/home/pshah9/Documents/yocto/fsl-community-bsp/sources/meta-openembedded/meta-oe/recipes-multimedia/libav/libav_0.8.4.bb, do_configure) failed with exit code '1'

NOTE: Tasks Summary: Attempted 6690 tasks of which 6688 didn't need to be rerun and 1 failed.

No currently running tasks (6688 of 6709)

Summary: 1 task failed:

  /home/pshah9/Documents/yocto/fsl-community-bsp/sources/meta-openembedded/meta-oe/recipes-multimedia/libav/libav_0.8.4.bb, do_configure

Summary: There was 1 ERROR message shown, returning a non-zero exit code.

Somehow I am not able to attach a config.log file. Please let me know how to do it if the file is needed.

It is very urgent for me to resolve this error.

Sorry for my delay...

Which branch are you using? I will try to reproduce the error on my side

I am using dylan branch.

Hi Daiane,

I made a switch from Dylan to master branch and it solved the above error for me.

Now I want to add h264 encoder(x264enc) to my image. For this I added

gst-plugins-ugy-meta to CORE_IMAGE_EXTRA_INSTALL as you have shown

for adding particular element to the image.

Everything compiled properly here but still I didn't get x264enc element in my image.

Can you help me adding x264enc to my image?

Tejas,

Make sure the gst-plugins-ugly-meta recipe contains the SW encoder you want. BTW, why do you need SW encoding if you got vpuenc?

leo

Hi Leo,

I am performing power consumption of sending a video from wandboard to a network we have set it up.

Basically here I am comparing the power consumption of video captured using software with video captured

using hardware accelerator on the board.

Hi Leo,

I am looking at the file inside ~/yocto/fsl-community-bsp/sources/poky/meta/recipes-multimedia/gstreamer/gst-plugins-ugly_0.10.19.bb

Is this the correct place to look up?

Hi Tejas,

why are you including gst-plugins-ugly-meta? seems  that the recipe does not exist. As Daiane mentioned, have you add that element this way?

COMMERCIAL_VIDEO_PLUGINS ?= " \
    gst-plugins-ugly-x264enc \
"

In the other hand, That recipe (./poky/meta/recipes-multimedia/gstreamer/gst-plugins-ugly_0.10.19.bb) can also be used to include the element but I think the way Daiane mentioned is better for your purposes.

Leo

Good to hear it´s fixed on newer code. And I would like to see your results comparing both encoders, if you don´t mind to share, in future.

Looking on http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/meta/recipes-multimedia/gstreamer/gstreamer1.0-p...

It looks like the x264 is not selected by default:

PACKAGECONFIG ??= " \
  a52dec lame mad mpeg2dec \
  "


So, could you try, please, to add the following line you your local.conf?

PACKAGECONFIG_pn_gstreamer1.0-plugins-ugly += "x264"

Please, let me know the results

The reason is that I get a error when I add element that way. Here is the error I get:

| Computing transaction...error: Can't install gst-meta-video-0.10-r13@cortexa9hf_vfp_neon: no package provides gst-plugins-ugly-x264enc

|

| Saving cache...

|

| WARNING: exit code 1 from a shell command.

| ERROR: Function failed: do_rootfs (log file is located at /home/pshah9/Desktop/yocto-master/fsl-community-bsp/build/tmp/work/wandboard_dual-poky-linux-gnueabi/fsl-image-gui/1.0-r0/temp/log.do_rootfs.16656)

ERROR: Task 7 (/home/pshah9/Desktop/yocto-master/fsl-community-bsp/sources/meta-fsl-demos/recipes-fsl/images/fsl-image-gui.bb, do_rootfs) failed with exit code '1'

NOTE: Tasks Summary: Attempted 6575 tasks of which 6522 didn't need to be rerun and 1 failed.

No currently running tasks (6575 of 6576)

Summary: 1 task failed:

  /home/pshah9/Desktop/yocto-master/fsl-community-bsp/sources/meta-fsl-demos/recipes-fsl/images/fsl-image-gui.bb, do_rootfs

Summary: There was 1 WARNING message shown.

Summary: There was 1 ERROR message shown, returning a non-zero exit code.

Due to this error I am using gst-plugins-ugly-meta

Here is my config file when I add element as you suggested:

MACHINE ??= 'wandboard-dual'

DISTRO ?= 'poky'

PACKAGE_CLASSES ?= "package_rpm"

EXTRA_IMAGE_FEATURES = "debug-tweaks ssh-server-openssh"

USER_CLASSES ?= "buildstats image-mklibs image-prelink"

PATCHRESOLVE = "noop"

BB_DISKMON_DIRS = "\

    STOPTASKS,${TMPDIR},1G,100K \

    STOPTASKS,${DL_DIR},1G,100K \

    STOPTASKS,${SSTATE_DIR},1G,100K \

    ABORT,${TMPDIR},100M,1K \

    ABORT,${DL_DIR},100M,1K \

    ABORT,${SSTATE_DIR},100M,1K"

CONF_VERSION = "1"

BB_NUMBER_THREADS = '2'

PARALLEL_MAKE = '-j 2'

ACCEPT_FSL_EULA = ""

LICENSE_FLAGS_WHITELIST = "commercial"


COMMERCIAL_VIDEO_PLUGINS ?= " \

    gst-plugins-ugly-x264enc \

"

CORE_IMAGE_EXTRA_INSTALL += " \

gst-plugins-bad-meta \

gst-ffmpeg \

gst-plugins-base-meta \

"

PACKAGECONFIG_pn_gstreamer1.0-plugins-ugly += "x264"

Hi Daiane,

As I mentioned earlier I am using gst-plugins-ugly-meta in CORE_IMAGE_EXTRA_INSTALL.

After adding the line of code that you asked for in the local.conf, it doesn't change anything.

I still get the same error that there is no element as x264enc.

Here is my config file. Please let me know if I have something wrong in there.

MACHINE ??= 'wandboard-dual'

DISTRO ?= 'poky'

PACKAGE_CLASSES ?= "package_rpm"

EXTRA_IMAGE_FEATURES = "debug-tweaks ssh-server-openssh"

USER_CLASSES ?= "buildstats image-mklibs image-prelink"

PATCHRESOLVE = "noop"

BB_DISKMON_DIRS = "\

    STOPTASKS,${TMPDIR},1G,100K \

    STOPTASKS,${DL_DIR},1G,100K \

    STOPTASKS,${SSTATE_DIR},1G,100K \

    ABORT,${TMPDIR},100M,1K \

    ABORT,${DL_DIR},100M,1K \

    ABORT,${SSTATE_DIR},100M,1K"

CONF_VERSION = "1"

BB_NUMBER_THREADS = '2'

PARALLEL_MAKE = '-j 2'

ACCEPT_FSL_EULA = ""

LICENSE_FLAGS_WHITELIST = "commercial"

CORE_IMAGE_EXTRA_INSTALL += " \

gst-plugins-ugly-meta \

gst-plugins-bad-meta \

gst-ffmpeg \

gst-plugins-base-meta \

"

PACKAGECONFIG_pn_gstreamer1.0-plugins-ugly += "x264"

Instead of using gst-plugins-ugly-meta, if I were to use gst-plugins-ugly-x264enc or gst-plugins-ugly-x264 as Leo suggested, then I get the below error.

Ok, I would need to spend more time debugging this, I need to reproduce it on my side.

Tejas Shah, could you, please, make me a favor? Could you, please, open a new discussion on imx-community, With title something like "How to include x264enc on yocto"

This way it would be much easier for another person to find the solution, in future (them among a lot of comments on a Doc).

Please, mention me (use @ and my name daiane_angolini). I´m going to test it using dora and let you know the results.

Oh, please, remember to add your log error :smileywink:

Thanks in advance,

No ratings
Version history
Last update:
‎07-30-2013 11:59 AM
Updated by: