I do not want do_compile to run again, it rebuilds the whole image. What is the best way to always run find_version?
On Sun, Nov 22, 2020 at 7:53 PM Khem Raj <raj.k...@gmail.com> wrote: > > On Sun, Nov 22, 2020 at 6:17 PM Michael Callahan > <coder.calla...@gmail.com> wrote: > > > > I am having trouble with sstate caching of my os-release.bbappend and > > am stuck. The simple example file looks like something below, where I > > am setting a variable from a computed python function. What's the magic > > to make the find_version(d) always run but do_compile to only run if > > VERSION changes? I basically want something like > > `find_version[nostamp]="1"` but that seems to only work for tasks. > > > > def find_version(d): > > import subprocess > > cmd = "git describe --long" > > return subprocess.check_output(cmd).rstrip().decode('utf-8') > > > > VERSION = "${@find_version(d)}" > > # do_compile uses $VERSION > > > > perhaps mark the task which is using this variable as nostamp. > > > > >
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#51536): https://lists.yoctoproject.org/g/yocto/message/51536 Mute This Topic: https://lists.yoctoproject.org/mt/78445317/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-