Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

yocto: rebuild part of project

I have a project which is using yocto for building libraries including gstreamer. I found out that I need to patch some gstreamer element thus creating new bitbake recipe with patch..

I usually have to run bitbake with image name as parameter which will rebuild whole yocto (which is quite long):

MACHINE=some_machine nice bitbake yocto-etc-etc

How do I rebuild just that part which I need and not whole yocto? I heard about devtool, but I am not sure how to use that.

like image 670
nayana Avatar asked Apr 06 '16 13:04

nayana


People also ask

What does BitBake clean do?

This command will clean up your tmp dir for the given package. It is very useful if you work on a new . bb recipe. Without it your changes to the recipe may not work.

What is poky and BitBake?

Poky is platform-independent and performs cross-compiling, using Bitbake Tool, OpenEmbedded Core, and a default set of metadata. The main objective of Poky is to provide all the features an embedded developer needs. Bitbake is a task scheduler that parses Python and Shell script mixed code, which we called Recipes.


2 Answers

you can pass different command to bitbake based on what you need.

To remove temp:

bitbake -c clean gstreamer

To remove temp and sstate cache (I use this most):

bitbake -c cleansstate gstreamer

To remove download as well, and lets begin build starting from do_fetch and all

bitbake -c cleanall gstreamer

Once you are done with either of these clean, which ever suits you, you can simple give build command for the specified:

bitbake gstreamer
like image 153
Abhishek Dwivedi Avatar answered Sep 20 '22 20:09

Abhishek Dwivedi


First you can create a patch on the gstreamer using quilt or diff etc...

Put the patch into your meta layer and include it into,SRC_URI += "file://xxxx.patch".

Make sure you have added FILESEXTRAPATHS_PREPEND variable in the bbappend file of recipe.

Then do a cleansstate of the package.

bitabake gstreamer** -c cleansstate

Then execute do_patch operation and check our patch has been applied properly.

bitabake gstreamer*** -c patch

Then do the full build of the component followed by built the final target.

like image 37
Vysakh A V Avatar answered Sep 21 '22 20:09

Vysakh A V