Commit 97743f42 authored by Ruslan Kuprieiev's avatar Ruslan Kuprieiev Committed by Pavel Emelyanov

make: fix multithreded compilation

Currently we run into lots of race conditions when building in
multithreded mode.

Reported-by: Mr Jenkins
Signed-off-by: 's avatarRuslan Kuprieiev <kupruser@gmail.com>
Acked-by: 's avatarCyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: 's avatarPavel Emelyanov <xemul@parallels.com>
parent a1f626d4
...@@ -148,7 +148,9 @@ ifeq ($(GCOV),1) ...@@ -148,7 +148,9 @@ ifeq ($(GCOV),1)
%.o $(PROGRAM): override CFLAGS += --coverage %.o $(PROGRAM): override CFLAGS += --coverage
endif endif
all: config pie $(VERSION_HEADER) $(CRIU-LIB) $(PROGRAM) crit all: config pie $(VERSION_HEADER) $(CRIU-LIB)
$(Q) $(MAKE) $(PROGRAM)
$(Q) $(MAKE) crit
protobuf/%:: protobuf/%::
$(Q) $(MAKE) $(build)=protobuf $@ $(Q) $(MAKE) $(build)=protobuf $@
......
...@@ -89,7 +89,7 @@ $(obj)/%.proto.c.d: $(obj)/%.proto | $(obj)/%.proto.d ...@@ -89,7 +89,7 @@ $(obj)/%.proto.c.d: $(obj)/%.proto | $(obj)/%.proto.d
-e 's/.*/$(subst .proto,.pb-c.c,$(subst /,\/,$<)):$(subst /,\/,$(obj))\/&/' | \ -e 's/.*/$(subst .proto,.pb-c.c,$(subst /,\/,$<)):$(subst /,\/,$(obj))\/&/' | \
uniq > $@ uniq > $@
$(obj)/%.pb-c.c $(obj)/%.pb-c.h: $(obj)/%.proto $(obj)/%.proto.c.d $(obj)/%.pb-c.c $(obj)/%.pb-c.h: $(obj)/%.proto $(obj)/%.proto.c.d $(obj)/opts.pb-c.c
$(E) " PBCC " $@ $(E) " PBCC " $@
$(Q) protoc-c --proto_path=$(obj)/ --c_out=$(obj)/ $< $(Q) protoc-c --proto_path=$(obj)/ --c_out=$(obj)/ $<
ifeq ($(SRCARCH),arm) ifeq ($(SRCARCH),arm)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment