[CRIU] [PATCH v2] soccr: Generate config.h dynamically

Cyrill Gorcunov gorcunov at gmail.com
Wed Oct 5 06:38:29 PDT 2016


On Wed, Oct 05, 2016 at 04:29:56PM +0300, Cyrill Gorcunov wrote:
> On Wed, Oct 05, 2016 at 04:25:28PM +0300, Cyrill Gorcunov wrote:
> > Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
> > ---
> >  Makefile       | 3 +++
> >  soccr/config.h | 2 +-
> >  2 files changed, 4 insertions(+), 1 deletion(-)
> 
> Drop it

	Cyrill
-------------- next part --------------
>From b2f2256f2846473c80621238ca86a4f60d5959c5 Mon Sep 17 00:00:00 2001
From: Cyrill Gorcunov <gorcunov at openvz.org>
Date: Wed, 5 Oct 2016 16:24:29 +0300
Subject: [PATCH] soccr: Generate config.h dynamically

Otherwise there is a broken symlink which makes tags/etags unhappy.

Signed-off-by: Cyrill Gorcunov <gorcunov at openvz.org>
---
 Makefile       | 8 ++++++--
 soccr/config.h | 1 -
 2 files changed, 6 insertions(+), 3 deletions(-)
 delete mode 120000 soccr/config.h

diff --git a/Makefile b/Makefile
index 37ae7cb6b7d3..9effc3b9a6ab 100644
--- a/Makefile
+++ b/Makefile
@@ -209,9 +209,12 @@ include Makefile.compel
 # Next the socket CR library
 #
 SOCCR_A := soccr/libsoccr.a
-soccr/%: $(CONFIG_HEADER) .FORCE
+SOCCR_CONFIG := $(SRC_DIR)/soccr/config.h
+$(SOCCR_CONFIG): $(CONFIG_HEADER)
+	$(Q) ln -s $(CONFIG_HEADER) $@
+soccr/%: $(SOCCR_CONFIG) .FORCE
 	$(Q) $(MAKE) $(build)=soccr $@
-soccr/built-in.o: $(CONFIG_HEADER) .FORCE
+soccr/built-in.o: $(SOCCR_CONFIG) .FORCE
 	$(Q) $(MAKE) $(build)=soccr all
 $(SOCCR_A): |soccr/built-in.o
 
@@ -265,6 +268,7 @@ mrproper: subclean
 	$(Q) $(MAKE) $(build)=compel/plugins $@
 	$(Q) $(MAKE) $(build)=soccr $@
 	$(Q) $(RM) $(CONFIG_HEADER)
+	$(Q) $(RM) $(SOCCR_CONFIG)
 	$(Q) $(RM) $(VERSION_HEADER)
 	$(Q) $(RM) $(COMPEL_VERSION_HEADER)
 	$(Q) $(RM) cscope.*
diff --git a/soccr/config.h b/soccr/config.h
deleted file mode 120000
index 106aa8bf2be0..000000000000
--- a/soccr/config.h
+++ /dev/null
@@ -1 +0,0 @@
-../criu/include/config.h
\ No newline at end of file
-- 
2.7.4



More information about the CRIU mailing list