Commit cebc7de2 authored by Stanislav Kinsbursky's avatar Stanislav Kinsbursky Committed by Cyrill Gorcunov

make: fix parasite deps

Remove explicit parasite targets dependence on deps files and use them as
makefile parts.
Signed-off-by: 's avatarStanislav Kinsbursky <skinsbursky@parallels.com>
Acked-by: 's avatarPavel Emelyanov <xemul@parallels.com>
Signed-off-by: 's avatarCyrill Gorcunov <gorcunov@openvz.org>
parent d1df3f60
...@@ -77,12 +77,10 @@ OBJS += libnetlink.o ...@@ -77,12 +77,10 @@ OBJS += libnetlink.o
OBJS += sockets.o OBJS += sockets.o
OBJS += files.o OBJS += files.o
DEPS := $(patsubst %.o,%.d,$(OBJS))
HEADERS := $(shell find ./include/* -name '*.h' -print) HEADERS := $(shell find ./include/* -name '*.h' -print)
OBJS-BLOB += parasite.o OBJS-BLOB += parasite.o
DEPS-BLOB += $(patsubst %.o,%.d,$(OBJS-BLOB))
SRCS-BLOB += $(patsubst %.o,%.c,$(OBJS-BLOB)) SRCS-BLOB += $(patsubst %.o,%.c,$(OBJS-BLOB))
HEAD-BLOB-GEN := $(patsubst %.o,%-blob.h,$(OBJS-BLOB)) HEAD-BLOB-GEN := $(patsubst %.o,%-blob.h,$(OBJS-BLOB))
...@@ -91,6 +89,8 @@ HEAD-LDS := $(patsubst %.o,%.lds.S,$(OBJS-BLOB)) ...@@ -91,6 +89,8 @@ HEAD-LDS := $(patsubst %.o,%.lds.S,$(OBJS-BLOB))
HEAD-IDS := $(patsubst %.h,%_h__,$(subst -,_,$(HEAD-BLOB))) HEAD-IDS := $(patsubst %.h,%_h__,$(subst -,_,$(HEAD-BLOB)))
DEPS := $(patsubst %.o,%.d,$(OBJS)) $(patsubst %.o,%.d,$(OBJS-BLOB))
all: $(PROGRAM) all: $(PROGRAM)
$(OBJS-BLOB): $(SRCS-BLOB) $(OBJS-BLOB): $(SRCS-BLOB)
...@@ -101,7 +101,7 @@ $(HEAD-BIN): $(OBJS-BLOB) $(HEAD-LDS) ...@@ -101,7 +101,7 @@ $(HEAD-BIN): $(OBJS-BLOB) $(HEAD-LDS)
$(E) " GEN " $@ $(E) " GEN " $@
$(Q) $(LD) -T $(patsubst %.bin,%.lds.S,$@) $< -o $@ $(Q) $(LD) -T $(patsubst %.bin,%.lds.S,$@) $< -o $@
$(HEAD-BLOB-GEN): $(HEAD-BIN) $(DEPS-BLOB) $(HEAD-BLOB-GEN): $(HEAD-BIN)
$(E) " GEN " $@ $(E) " GEN " $@
$(Q) $(SH) gen-offsets.sh \ $(Q) $(SH) gen-offsets.sh \
parasite_h__ \ parasite_h__ \
...@@ -123,9 +123,6 @@ $(DEPS_PARA): $(HEAD-BLOB-GEN) ...@@ -123,9 +123,6 @@ $(DEPS_PARA): $(HEAD-BLOB-GEN)
%.d: %.c %.d: %.c
$(Q) $(CC) -M -MT $(patsubst %.d,%.o,$@) $(CFLAGS) $< -o $@ $(Q) $(CC) -M -MT $(patsubst %.d,%.o,$@) $(CFLAGS) $< -o $@
$(DEPS-BLOB): $(SRCS-BLOB)
$(Q) $(CC) -M -MT $(patsubst %.d,%.o,$@) $(CFLAGS) $< -o $@
test: test:
$(Q) $(MAKE) -C test all $(Q) $(MAKE) -C test all
.PHONY: test .PHONY: test
......
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