Skip to content

Commit eebb22e

Browse files
committed
feat: update patch to build against criu-dev 1a3be784fe533f1a7f6612501e4f1fa455141c1e
1 parent 21862ac commit eebb22e

File tree

2 files changed

+20
-6
lines changed

2 files changed

+20
-6
lines changed

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,9 @@ ExternalProject_Add(criu
107107
CONFIGURE_COMMAND ""
108108
DOWNLOAD_DIR ${SOURCE_DOWNLOADS_DIR}
109109
DOWNLOAD_NAME ${DEP_criu_FILENAME}
110-
BUILD_COMMAND
110+
BUILD_COMMAND
111111
${CMAKE_MAKE_PROGRAM} -C <SOURCE_DIR> ${CRIU_MAKE_VARS} mrproper
112-
COMMAND ${CMAKE_COMMAND} -E rm -f "<SOURCE_DIR>/images/google/protobuf/descriptor.proto"
112+
COMMAND ${CMAKE_COMMAND} -E make_directory "<SOURCE_DIR>/images/google/protobuf"
113113
COMMAND ${CMAKE_COMMAND} -E copy "${DESCRIPTOR_PROTO_FILE}" "<SOURCE_DIR>/images/google/protobuf/descriptor.proto"
114114
COMMAND ${CMAKE_COMMAND} -E env
115115
"CFLAGS=${CRIU_CFLAGS}"

patch/criu-build.patch

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
diff --git a/Makefile b/Makefile
2-
index 5d8e89ac1..9006fc193 100644
2+
index 7272cfce1..b26f7581a 100644
33
--- a/Makefile
44
+++ b/Makefile
5-
@@ -268,7 +268,6 @@ criu-deps += $(SOCCR_A)
5+
@@ -270,7 +270,6 @@ criu-deps += $(SOCCR_A)
66
# But note that we're already included
77
# the nmk so we can reuse it there.
88
criu/Makefile: ;
@@ -24,7 +24,7 @@ index 764afadc8..c211f52f4 100644
2424
#
2525
# And compel library.
2626
diff --git a/Makefile.config b/Makefile.config
27-
index 5ab689d41..d7ad71667 100644
27+
index 5cf4b8216..adacedad3 100644
2828
--- a/Makefile.config
2929
+++ b/Makefile.config
3030
@@ -5,58 +5,6 @@ include scripts/feature-tests.mak
@@ -35,7 +35,7 @@ index 5ab689d41..d7ad71667 100644
3535
- LIBS_FEATURES += -lbsd
3636
- FEATURE_DEFINES += -DCONFIG_HAS_LIBBSD
3737
-else
38-
- $(info Note: Building without setproctitle() and strlcpy() support.)
38+
- $(info Note: Building without setproctitle() support.)
3939
- $(info $S Install libbsd-devel (RPM) / libbsd-dev (DEB) to fix.)
4040
-endif
4141
-
@@ -190,6 +190,20 @@ index ef78bcec7..4a64c975a 100644
190190

191191
#include "image.h"
192192
#include "servicefd.h"
193+
diff --git a/images/Makefile b/images/Makefile
194+
index 2c33152e9..51d28901c 100644
195+
--- a/images/Makefile
196+
+++ b/images/Makefile
197+
@@ -93,8 +93,7 @@ makefile-deps := Makefile $(obj)/Makefile
198+
#
199+
# Generate descriptor.pb-c.c and descriptor.pb-c.h to compile opts.proto.
200+
DESCRIPTOR_DIR := images/google/protobuf
201+
-GOOGLE_INCLUDE=$(shell pkg-config protobuf --variable=includedir)/google/protobuf
202+
-$(DESCRIPTOR_DIR)/descriptor.pb-c.c: $(GOOGLE_INCLUDE)/descriptor.proto
203+
+$(DESCRIPTOR_DIR)/descriptor.pb-c.c: images/google/protobuf/descriptor.proto
204+
$(call msg-gen, $@)
205+
$(Q) protoc --proto_path=/usr/include --proto_path=$(obj)/ --c_out=$(obj)/ $<
206+
193207
diff --git a/plugins/cuda/Makefile b/plugins/cuda/Makefile
194208
index cc3d98ac9..6ba0defe8 100644
195209
--- a/plugins/cuda/Makefile

0 commit comments

Comments
 (0)