criu/compel/test/fdspy/Makefile
Kir Kolyshkin ef6c3f6ce6 compel/test/fdspy: fix linking
1. Commit 8b99809 ("compel: make plugins .a archives") changed the
   suffix of compel plugins, so this test no longer compiles.

2. "compel plugins" can print auxiliary plugins now, let's use it.

Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
2017-05-19 09:17:20 +03:00

28 lines
568 B
Makefile

CC := gcc
CFLAGS ?= -O2 -g -Wall -Werror
COMPEL := ../../../compel/compel-host
all: victim spy
clean:
rm -f victim
rm -f spy
rm -f parasite.h
rm -f parasite.po
rm -f parasite.o
victim: victim.c
$(CC) $(CFLAGS) -o $@ $^
spy: spy.c parasite.h
$(CC) $(CFLAGS) $(shell $(COMPEL) includes) -o $@ $< $(shell $(COMPEL) --static libs)
parasite.h: parasite.po
$(COMPEL) hgen -o $@ -f $<
parasite.po: parasite.o
ld $(shell $(COMPEL) ldflags) -o $@ $^ $(shell $(COMPEL) plugins fds)
parasite.o: parasite.c
$(CC) $(CFLAGS) -c $(shell $(COMPEL) cflags) -o $@ $^