cancel
Showing results for 
Search instead for 
Did you mean: 

Removing examples from userfs

OskarM
Associate II

Hi,

I have seen this post: https://community.st.com/t5/stm32-mpus-embedded-software-and/how-to-clear-the-default-st-image-userfs-remove-examples-and/m-p/735819#M4265 

and added to my st-image-userfs.bbappend:

PACKAGE_INSTALL:remove = "m4projects-stm32mp1-userfs"
PACKAGE_INSTALL:remove = "linux-examples-stm32mp1-userfs"
PACKAGE_INSTALL:remove = "packagegroup-st-demo"

My machine has:

M4_BOARDS = ""
M4COPRO_LIST = "m4fwcoredump"

I want to keep the "coredump" features. I have noticed though, that now the userfs gets populated with bin, etc,var folders - which were not present before. I can't track it down, how to get rid of those or how they are cleaned by m4project recipes. Any hint?

1 ACCEPTED SOLUTION

Accepted Solutions
OskarM
Associate II

Ok, I managed to resolve it (or make a dirty fix).

In st-image-paritions.inc is a "reformat_rootfs" function, that does it. There is an issue with this method, that it expects /usr/local to exist and - since it is using "mv" - it fails on empty folder.

The hack is to install a /usr/local manually and add an dummy file, then remove it before deploying the image.

 

View solution in original post

1 REPLY 1
OskarM
Associate II

Ok, I managed to resolve it (or make a dirty fix).

In st-image-paritions.inc is a "reformat_rootfs" function, that does it. There is an issue with this method, that it expects /usr/local to exist and - since it is using "mv" - it fails on empty folder.

The hack is to install a /usr/local manually and add an dummy file, then remove it before deploying the image.