[yocto] Bitbake recipe Post install script not executed once the package is installed

Paul Eggleton paul.eggleton at linux.intel.com
Sat Mar 14 04:31:12 PDT 2015


On Saturday 14 March 2015 10:39:59 Bipnesh, Abhinav wrote:
> I was trying to perform a post install activity as part of the recipe using
> pkg_postinst_PACKAGENAME() but seems it’s not working. Below is the sample
> function we have written as part of the recipe
> 
> pkg_postinst_test (){
>     #!/bin/sh -xe
>     echo " we are calling post install for test"
>     mkdir -p /test/logs/1
>     touch /test/test1/test2/test3/sample.txt
> 
> }
> testX directory exists as they are created as part of the install activity.
> When we verify the post install we did find the file being created as below
> is the output
> 
> ls /test/test1/test2/test3/.txt ls: cannot access
> /test/test1/test2/test3/.txt: No such file or directory

I assume you meant *.txt as .txt wouldn't exist even if the postinstall script 
had run.

> Also didn't see the echo output on the console when the package is being
> installed or post installation activity is being performed.

Is the output package that you are installing actually called "test"?

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre



More information about the yocto mailing list