pie: generate native and compat parasites

Only parasite should be mode-depended, not restorer, as
restorer will just switch to compatible mode with arch_prctl
at the end and jump to 32-bit executable with sigreturn.

So for parasite there are two targets: "native" and "compat",
and one for restorer with the same name "restorer".
It will result in parasite-native.o, parasite-compat.o and restorer.o
objects.

Pie build still may work with piegen or without it (gen-offset.sh).

There are many FIXME in this patch, all them are in C code, that should
be fixed to use compatible parsite when needed.

Signed-off-by: Dmitry Safonov <dsafonov@virtuozzo.com>
Acked-by: Cyrill Gorcunov <gorcunov@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com>
Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
Dmitry Safonov 2016-04-12 19:10:49 +03:00 committed by Andrei Vagin
parent 29a434c4cf
commit d94b9f3065
6 changed files with 134 additions and 63 deletions

4
.gitignore vendored
View file

@ -33,9 +33,9 @@ criu/include/syscall*.h
soccr/config.h
criu/include/version.h
criu/pie/restorer-blob.h
criu/pie/parasite-blob.h
criu/pie/parasite-*-blob.h
criu/pie/piegen/piegen
criu/pie/pie.lds.S
criu/pie/pie.lds*.S
criu/protobuf-desc-gen.h
scripts/build/qemu-user-static/*
lib/.crit-setup.files