]> git.ipfire.org Git - thirdparty/strongswan.git/commitdiff
testing: Avoid unnecessary rebuilds of components built from Git repos
authorTobias Brunner <tobias@strongswan.org>
Fri, 14 Sep 2018 15:19:55 +0000 (17:19 +0200)
committerTobias Brunner <tobias@strongswan.org>
Tue, 30 Oct 2018 14:06:47 +0000 (15:06 +0100)
Installing apparently changes the timestamp on the repo dir triggering make
to checkout and build the whole thing again.

testing/scripts/recipes/005_anet.mk
testing/scripts/recipes/006_tkm-rpc.mk
testing/scripts/recipes/007_x509-ada.mk
testing/scripts/recipes/008_xfrm-ada.mk
testing/scripts/recipes/009_xfrm-proxy.mk
testing/scripts/recipes/010_tkm.mk
testing/scripts/recipes/011_botan.mk

index a6af5df5c5d37cf21c7c4e2fa6d4a22d62514b74..b311c0a99fe26d05f40ee71b0a105408e9b2cc1a 100644 (file)
@@ -8,14 +8,15 @@ PREFIX = /usr/local/ada
 
 all: install
 
-$(PKG):
-       git clone $(SRC) $(PKG)
+.$(PKG)-cloned:
+       [ -d $(PKG) ] || git clone $(SRC) $(PKG)
+       @touch $@
 
-.$(PKG)-cloned-$(REV): $(PKG)
+.$(PKG)-checkout-$(REV): .$(PKG)-cloned
        cd $(PKG) && git fetch && git checkout $(REV)
        @touch $@
 
-.$(PKG)-built-$(REV): .$(PKG)-cloned-$(REV)
+.$(PKG)-built-$(REV): .$(PKG)-checkout-$(REV)
        cd $(PKG) && make LIBRARY_KIND=static
        @touch $@
 
index 5f2e207c8eec669c0112117c8c516ca1889ce8e4..ed2a62396e6cdaaa053fef402a034ce2a45d6d3f 100644 (file)
@@ -10,14 +10,15 @@ export ADA_PROJECT_PATH=$(PREFIX)/lib/gnat
 
 all: install
 
-$(PKG):
-       git clone $(SRC) $(PKG)
+.$(PKG)-cloned:
+       [ -d $(PKG) ] || git clone $(SRC) $(PKG)
+       @touch $@
 
-.$(PKG)-cloned-$(REV): $(PKG)
+.$(PKG)-checkout-$(REV): .$(PKG)-cloned
        cd $(PKG) && git fetch && git checkout $(REV)
        @touch $@
 
-.$(PKG)-built-$(REV): .$(PKG)-cloned-$(REV)
+.$(PKG)-built-$(REV): .$(PKG)-checkout-$(REV)
        cd $(PKG) && make
        @touch $@
 
index 7899f6dec67eafce0615c4f8c64a480df3989af8..57a106dea42dcb5b7a73693170e6f6c1db2d0c47 100644 (file)
@@ -8,14 +8,15 @@ PREFIX = /usr/local/ada
 
 all: install
 
-$(PKG):
-       git clone $(SRC) $(PKG)
+.$(PKG)-cloned:
+       [ -d $(PKG) ] || git clone $(SRC) $(PKG)
+       @touch $@
 
-.$(PKG)-cloned-$(REV): $(PKG)
+.$(PKG)-checkout-$(REV): .$(PKG)-cloned
        cd $(PKG) && git fetch && git checkout $(REV)
        @touch $@
 
-.$(PKG)-built-$(REV): .$(PKG)-cloned-$(REV)
+.$(PKG)-built-$(REV): .$(PKG)-checkout-$(REV)
        cd $(PKG) && make tests && make
        @touch $@
 
index ad1cbb2bc7b07d86503db64818650c28725e91af..64ada0e45e7d90d1e33454bd1678160426913f2f 100644 (file)
@@ -10,14 +10,15 @@ export ADA_PROJECT_PATH=$(PREFIX)/lib/gnat
 
 all: install
 
-$(PKG):
-       git clone $(SRC) $(PKG)
+.$(PKG)-cloned:
+       [ -d $(PKG) ] || git clone $(SRC) $(PKG)
+       @touch $@
 
-.$(PKG)-cloned-$(REV): $(PKG)
+.$(PKG)-checkout-$(REV): .$(PKG)-cloned
        cd $(PKG) && git fetch && git checkout $(REV)
        @touch $@
 
-.$(PKG)-built-$(REV): .$(PKG)-cloned-$(REV)
+.$(PKG)-built-$(REV): .$(PKG)-checkout-$(REV)
        cd $(PKG) && make
        @touch $@
 
index a7c9d31cc2f5c4859ecbef2a6142882fcac07b7e..bdf5b121163b644a5c7efcc812e5290950899c1d 100644 (file)
@@ -8,14 +8,15 @@ export ADA_PROJECT_PATH=/usr/local/ada/lib/gnat
 
 all: install
 
-$(PKG):
-       git clone $(SRC) $(PKG)
+.$(PKG)-cloned:
+       [ -d $(PKG) ] || git clone $(SRC) $(PKG)
+       @touch $@
 
-.$(PKG)-cloned-$(REV): $(PKG)
+.$(PKG)-checkout-$(REV): .$(PKG)-cloned
        cd $(PKG) && git fetch && git checkout $(REV)
        @touch $@
 
-.$(PKG)-built-$(REV): .$(PKG)-cloned-$(REV)
+.$(PKG)-built-$(REV): .$(PKG)-checkout-$(REV)
        cd $(PKG) && make
        @touch $@
 
index 03ee5b52671d0e2c3874dfdfac6b83fe0e8805ae..2651660db687b0c598e24297b17656e16b71ca13 100644 (file)
@@ -8,14 +8,15 @@ export ADA_PROJECT_PATH=/usr/local/ada/lib/gnat
 
 all: install
 
-$(PKG):
-       git clone $(SRC) $(PKG)
+.$(PKG)-cloned:
+       [ -d $(PKG) ] || git clone $(SRC) $(PKG)
+       @touch $@
 
-.$(PKG)-cloned-$(REV): $(PKG)
+.$(PKG)-checkout-$(REV): .$(PKG)-cloned
        cd $(PKG) && git fetch && git checkout $(REV)
        @touch $@
 
-.$(PKG)-built-$(REV): .$(PKG)-cloned-$(REV)
+.$(PKG)-built-$(REV): .$(PKG)-checkout-$(REV)
        cd $(PKG) && make
        @touch $@
 
index ef0f6d066061aa9449cee6ed5255132ed242715f..e507f731020f37f027f8e8082dac79f9fb830c54 100644 (file)
@@ -15,14 +15,15 @@ CONFIG_OPTS = \
 
 all: install
 
-$(PKG):
-       git clone $(SRC) $(PKG)
+.$(PKG)-cloned:
+       [ -d $(PKG) ] || git clone $(SRC) $(PKG)
+       @touch $@
 
-.$(PKG)-cloned-$(REV): $(PKG)
+.$(PKG)-checkout-$(REV): .$(PKG)-cloned
        cd $(PKG) && git fetch && git checkout $(REV)
        @touch $@
 
-.$(PKG)-built-$(REV): .$(PKG)-cloned-$(REV)
+.$(PKG)-built-$(REV): .$(PKG)-checkout-$(REV)
        cd $(PKG) && python ./configure.py $(CONFIG_OPTS) && make -j $(NUM_CPUS)
        @touch $@