mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-07-20 16:51:37 +00:00
We will need it when parasite engine will be creating signal frames. Export appropriate headers and use it in CRIU by linking with libcompel.a. Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
51 lines
1.6 KiB
Makefile
51 lines
1.6 KiB
Makefile
include $(SRC_DIR)/Makefile.versions
|
|
|
|
.PHONY: .FORCE
|
|
|
|
COMPEL_SO_VERSION := $(COMPEL_SO_VERSION_MAJOR)$(if $(COMPEL_SO_VERSION_MINOR),.$(COMPEL_SO_VERSION_MINOR))$(if $(COMPEL_SO_VERSION_SUBLEVEL),.$(COMPEL_SO_VERSION_SUBLEVEL))
|
|
COMPEL_SO_VERSION_CODE := $(shell expr $(COMPEL_SO_VERSION_MAJOR) \* 65536 \+ $(COMPEL_SO_VERSION_MINOR) \* 256 \+ $(COMPEL_SO_VERSION_SUBLEVEL))
|
|
ccflags-y += -iquote compel/arch/$(ARCH)/src/lib/include
|
|
ccflags-y += -iquote compel/include
|
|
ccflags-y += -iquote compel/plugins/include
|
|
ccflags-y += -fPIC
|
|
|
|
#
|
|
# UAPI inclusion, referred as <compel/...>
|
|
ccflags-y += -I compel/include/uapi
|
|
ccflags-y += -I compel/plugins/include/uapi
|
|
|
|
lib-name := libcompel.a
|
|
lib-y += arch/$(ARCH)/src/lib/handle-elf.o
|
|
host-lib-y += arch/$(ARCH)/src/lib/handle-elf.o
|
|
lib-y += src/lib/handle-elf.o
|
|
host-lib-y += src/lib/handle-elf.o
|
|
lib-y += src/lib/log.o
|
|
host-lib-y += src/lib/log.o
|
|
|
|
lib-y += arch/$(ARCH)/src/lib/cpu.o
|
|
|
|
ifeq ($(ARCH),x86)
|
|
lib-y += src/lib/handle-elf-32.o
|
|
host-lib-y += src/lib/handle-elf-32.o
|
|
endif
|
|
|
|
obj-y += src/main.o
|
|
|
|
ifeq ($(ARCH),x86)
|
|
CFLAGS_handle-elf-32.o += -UCONFIG_X86_64 -DCONFIG_X86_32
|
|
CFLAGS_handle-elf-32.d += -UCONFIG_X86_64 -DCONFIG_X86_32
|
|
endif
|
|
|
|
host-ccflags-y += $(ccflags-y)
|
|
|
|
hostprogs-y += compel-host
|
|
compel-host-objs := $(patsubst %.o,%-host.o,$(obj-y) $(host-lib-y))
|
|
|
|
ifeq ($(ARCH),x86)
|
|
HOSTCFLAGS_handle-elf-32-host.o += -UCONFIG_X86_64 -DCONFIG_X86_32
|
|
HOSTCFLAGS_handle-elf-32-host.d += -UCONFIG_X86_64 -DCONFIG_X86_32
|
|
endif
|
|
|
|
cleanup-y += compel/compel
|
|
cleanup-y += compel/compel-host
|
|
cleanup-y += compel/libcompel.so
|