Reduces the size of the yocto generated file system

cancel
Showing results for 
Search instead for 
Did you mean: 

Reduces the size of the yocto generated file system

Jump to solution
600 Views
zh_y
Contributor II

Hi ,

   Firstly, thank you for coming here, please help solve the following problems.

   Yocto version : fsl-yocto-L4.1.15_2.0.0-ga

   Linux Kernel  Version:4.1.15

   My Question:

   The rootfs I generated with yocto was very large, and I carefully checked that there were a lot of debugging software    and other unrelated libraries that I didn't need. I want to trim the file system, but I don't know what instructions or    recipes I should run, please help me solve this problem.

   Thank you !

Labels (3)
0 Kudos
1 Solution
417 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Zhang Ying,

You would need to replace <image> with the recipe for your image, not the resulting file system. In this example fsl-image-qt5.

You could just run:

$ bitbake -g fsl-image-qt5 && cat pn-buildlist

But for ease the command filters the packages maked as “native” and sorts them so they are in alphabetical order and only the unique results.

I hope this helps!

Regards,

View solution in original post

0 Kudos
5 Replies
417 Views
zh_y
Contributor II

Hi,

  • 1.  As you said, I entered the command line and it appears as follows:

  • 捕获.PNG
  • 2.  As I understand it, CUPS and Hplip should work together.I can use CUPS+CUPS on its own with PPD, but that doesn't drive all the printers.I want to know how hplip should be used.Because hplip is very important in the products I'm involved in.

Thank you

Best regards

0 Kudos
417 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Zhang Ying,

The bitbake command should be run on the host while the bitbake environment is setup.

Hplip available on the BSP but you would need to refer to CUPS and HPlib documentation for details of how it works. You may also post a new thread regarding this so more Community users can see it and maybe collaborate with an answer.

Regards,

0 Kudos
417 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Zhang Ying,

Which rootfs did you bake?

You could start from the bigger image and remove packages, or you could start from the core-image-minimal and add packages as needed.

If you need a graphical interface I would suggest the first approach, starting with the larger image with all required libraries and dependencies and removing the unwanted packages.

You can list all packages of an image with the command:

bitbake -g <image> && cat pn-buildlist | grep -ve "native" | sort | uniq

And then work from there removing unnecessary packages by adding the following line on the conf/local.conf file inside the build directory like so:

IMAGE_INSTALL_remove += “ package package1 package2”

 

I hope this helps!
Regards,

0 Kudos
417 Views
zh_y
Contributor II

Thank you very much for your reply !

I just tried using the following cmd-line, but an error occurred.

1_meitu_1.jpg

In addition ,Why look with the "native" parameter?

Thank you !

0 Kudos
418 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Zhang Ying,

You would need to replace <image> with the recipe for your image, not the resulting file system. In this example fsl-image-qt5.

You could just run:

$ bitbake -g fsl-image-qt5 && cat pn-buildlist

But for ease the command filters the packages maked as “native” and sorts them so they are in alphabetical order and only the unique results.

I hope this helps!

Regards,

View solution in original post

0 Kudos