summaryrefslogtreecommitdiffstats
path: root/recipes-containers/criu/criu_git.bb
diff options
context:
space:
mode:
authorZheng Ruoqin <zhengrq.fnst@cn.fujitsu.com>2018-07-16 09:32:48 +0800
committerBruce Ashfield <bruce.ashfield@windriver.com>2018-07-22 23:15:21 -0400
commit10a427caddb31d919c9e50373e4f7d940147dcd3 (patch)
tree882056e6115adbcf55e0e671f1eef5808f65c04e /recipes-containers/criu/criu_git.bb
parent1bcc2431a50df3266e7c5b11c7a6de1422fa07b2 (diff)
downloadmeta-virtualization-10a427caddb31d919c9e50373e4f7d940147dcd3.tar.gz
criu: upgrade to 3.9
1) Upgrade criu from 3.4 to 3.9. 2) Delete fix-building-on-newest-glibc-and-kernel.patch for it has been merged in upstream. 3) Add CFLAGS_arm += "-D__WORDSIZE" add this CFLAGS to solve the compile problem for arm. The log is as following: | ....../tmp/work/armv5e-poky-linux-gnueabi/criu/3.9+gitAUTOINC+202b7745bd-r0/recipe-sysroot/usr/include/bits/wordsize.h:36:2: error: #error "__WORDSIZE is not defined" | #error "__WORDSIZE is not defined" | ^ | ....../tmp/work/armv5e-poky-linux-gnueabi/criu/3.9+gitAUTOINC+202b7745bd-r0/recipe-sysroot/usr/include/bits/wordsize.h:59:2: error: # 4) Add export C_INCLUDE_PATH="${STAGING_INCDIR}/libnl3" add C_INCLUDE_PATH to solve the compile problem for arm. which is libnetlink.c can't find head file. | In file included from criu/libnetlink.c:5: | ....../tmp/work/armv5e-p | oky-linux-gnueabi/criu/3.9+gitAUTOINC+202b7745bd-r0/recipe-sysroot/usr/include/libnl3/netlink/attr.h:15:10: fatal error: netlink/netlink.h: No such file or directory #include <netlink/netlink.h> Signed-off-by: Zheng Ruoqin <zhengrq.fnst@cn.fujitsu.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Diffstat (limited to 'recipes-containers/criu/criu_git.bb')
-rw-r--r--recipes-containers/criu/criu_git.bb86
1 files changed, 0 insertions, 86 deletions
diff --git a/recipes-containers/criu/criu_git.bb b/recipes-containers/criu/criu_git.bb
deleted file mode 100644
index 7d62f354..00000000
--- a/recipes-containers/criu/criu_git.bb
+++ /dev/null
@@ -1,86 +0,0 @@
1SUMMARY = "CRIU"
2DESCRIPTION = "Checkpoint/Restore In Userspace, or CRIU, is a software tool for \
3Linux operating system. Using this tool, you can freeze a running application \
4(or part of it) and checkpoint it to a hard drive as a collection of files. \
5You can then use the files to restore and run the application from the point \
6it was frozen at. The distinctive feature of the CRIU project is that it is \
7mainly implemented in user space"
8HOMEPAGE = "http://criu.org"
9SECTION = "console/tools"
10LICENSE = "GPLv2"
11
12EXCLUDE_FROM_WORLD = "1"
13
14LIC_FILES_CHKSUM = "file://COPYING;md5=412de458544c1cb6a2b512cd399286e2"
15
16SRCREV = "a31c1854e10580a09621e539c3ec052b875a8e06"
17PV = "3.4+git${SRCPV}"
18
19SRC_URI = "git://github.com/xemul/criu.git;protocol=git \
20 file://0001-criu-Fix-toolchain-hardcode.patch \
21 file://0002-criu-Skip-documentation-install.patch \
22 file://0001-criu-Change-libraries-install-directory.patch \
23 file://lib-Makefile-overwrite-install-lib-to-allow-multiarc.patch \
24 file://fix-building-on-newest-glibc-and-kernel.patch \
25 "
26
27COMPATIBLE_HOST = "(x86_64|arm|aarch64).*-linux"
28
29DEPENDS += "libnl libcap protobuf-c-native protobuf-c util-linux-native libbsd libnet"
30RDEPENDS_${PN} = "bash"
31
32S = "${WORKDIR}/git"
33
34#
35# CRIU just can be built on ARMv7 and ARMv6, so the Makefile check
36# if the ARCH is ARMv7 or ARMv6.
37# ARM BSPs need set CRIU_BUILD_ARCH variable for building CRIU.
38#
39EXTRA_OEMAKE_arm += "ARCH=arm UNAME-M=${CRIU_BUILD_ARCH} WERROR=0"
40EXTRA_OEMAKE_x86-64 += "ARCH=x86 WERROR=0"
41EXTRA_OEMAKE_aarch64 += "ARCH=arm64 WERROR=0"
42
43EXTRA_OEMAKE_append += "SBINDIR=${sbindir} LIBDIR=${libdir} INCLUDEDIR=${includedir} PIEGEN=no"
44EXTRA_OEMAKE_append += "LOGROTATEDIR=${sysconfdir} SYSTEMDUNITDIR=${systemd_unitdir}"
45
46CFLAGS += "-D__USE_GNU -D_GNU_SOURCE "
47
48CFLAGS += " -I${STAGING_INCDIR} -I${STAGING_INCDIR}/libnl3"
49
50# overide LDFLAGS to allow criu to build without: "x86_64-poky-linux-ld: unrecognized option '-Wl,-O1'"
51export LDFLAGS=""
52
53export BUILD_SYS
54export HOST_SYS
55
56inherit setuptools
57
58PACKAGECONFIG ??= ""
59PACKAGECONFIG[selinux] = ",,libselinux"
60
61CLEANBROKEN = "1"
62
63do_compile_prepend() {
64 rm -rf ${S}/images/google/protobuf/descriptor.proto
65 ln -s ${PKG_CONFIG_SYSROOT_DIR}/usr/include/google/protobuf/descriptor.proto ${S}/images/google/protobuf/descriptor.proto
66}
67
68do_compile () {
69 oe_runmake
70}
71
72do_install () {
73 export INSTALL_LIB="${libdir}/${PYTHON_DIR}/site-packages"
74 oe_runmake PREFIX=${exec_prefix} LIBDIR=${libdir} DESTDIR="${D}" install
75}
76
77FILES_${PN} += "${systemd_unitdir}/ \
78 ${libdir}/python2.7/site-packages/ \
79 ${libdir}/pycriu/ \
80 ${libdir}/crit-0.0.1-py2.7.egg-info \
81 "
82
83FILES_${PN}-staticdev += " \
84 ${libexecdir}/compel/std.lib.a \
85 ${libexecdir}/compel/fds.lib.a \
86 "