Adapting OSTree to Yocto pseudo



Hi all,

I'm now working on integration of OSTree into Yocto build process.
Basically, it lets user automatically commit generated rootfs image to a
chosen OSTree repository and later deploy them on target devices. If you
are interested in details, you can look at Automotive Grade Linux
repository
(https://git.automotivelinux.org/gerrit/#/admin/projects/AGL/meta-agl-extra),
namely at meta-agl-extra/meta-sota/rescipes-sota/ostree_git.bb recipe
and meta-agl-extra/meta-sota/classes/image_types_ostree.bbclass.

Right now OSTree versions up to v2016.7 are supported and there is a
small problem with higher versions, because of implementation of call to
renameat2(). To make it short, Yocto uses a fakeroot-like tool (shared
library+daemon) called pseudo. It provides wrappers to standard library
calls, and does some magic before calling actual glibc function to
emulate root access rights for a non-privileged user. renameat2() is
quite new system call and is not supported by glibc, so libglnx code
calls it through syscall() function directly, thus bypassing pseudo
wrappers.

I could work on patches to libglnx to remove call to renameat2(), since
it is only there to check for existence of the target file and could be
replaced with a sequence of calls to more common standard functions.
Alternatively, it could be a patch to libostree. Third option would be
to implement renameat2() in pseudo, but libglnx still needs to be
patched to utilize it.

So I wonder if you consider it a good idea and are interested in
compatibility with fake root enviroments or it is a non-goal.

Best regards,

Anton Gerasimov


-- 
Anton Gerasimov, ATS Advanced Telematic Systems GmbH
Kantstrasse 162, 10623 Berlin
Managing Directors: Dirk Pöschl, Armin G. Schmidt
Register Court: HRB 151501 B, Amtsgericht Charlottenburg



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]