make "nat-libs" a dependency of the "deps-common" target

This commit is contained in:
Ștefan Talpalaru 2019-09-04 19:13:28 +02:00
parent bf86dccf4d
commit 178ded44a3
No known key found for this signature in database
GPG Key ID: CBF7934204F1B6F9
1 changed files with 3 additions and 3 deletions

View File

@ -23,7 +23,7 @@ sanity-checks:
# (timestamp-checked) prerequisites here
#- $(NIM_BINARY) is both a proxy for submodules having been initialised
# and a check for the actual compiler build
deps-common: sanity-checks $(NIM_BINARY) $(NIMBLE_DIR)
deps-common: sanity-checks $(NIM_BINARY) $(NIMBLE_DIR) nat-libs
#- conditionally re-builds the Nim compiler (not usually needed, because `make update` calls this rule; delete $(NIM_BINARY) to force it)
#- allows parallel building with the '+' prefix
@ -60,7 +60,7 @@ update-remote:
nat-libs: | libminiupnpc.a libnatpmp.a
libminiupnpc.a: | deps
libminiupnpc.a: | sanity-checks
ifeq ($(OS), Windows_NT)
+ [ -e vendor/nim-nat-traversal/vendor/miniupnp/miniupnpc/$@ ] || \
$(MAKE) -C vendor/nim-nat-traversal/vendor/miniupnp/miniupnpc -f Makefile.mingw CC=gcc init $@ $(HANDLE_OUTPUT)
@ -68,7 +68,7 @@ else
+ $(MAKE) -C vendor/nim-nat-traversal/vendor/miniupnp/miniupnpc $@ $(HANDLE_OUTPUT)
endif
libnatpmp.a: | deps
libnatpmp.a: | sanity-checks
ifeq ($(OS), Windows_NT)
+ $(MAKE) -C vendor/nim-nat-traversal/vendor/libnatpmp CC=gcc CFLAGS="-Wall -Os -DWIN32 -DNATPMP_STATICLIB -DENABLE_STRNATPMPERR" $@ $(HANDLE_OUTPUT)
else