Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Makefile.static: do not use bintray cache when environment variable i…
…s not defined
  • Loading branch information
perexg committed Jan 18, 2016
1 parent bf487f5 commit e2d8d56
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions Makefile.static
Expand Up @@ -33,9 +33,10 @@
#
# Optional inputs
#
# BINTRAY_USER - The bintray user account for uploads
# BINTRAY_CACHE - Use cached builds from bintray
# BINTRAY_USER - The bintray user account for uploads
# BINTRAY_PASS - The bintray password
# BINTRAY_REPO - The repo to upload to
# BINTRAY_REPO - The repo to upload to
#

MAKEFILE ?= $(firstword $(MAKEFILE_LIST))
Expand All @@ -48,20 +49,25 @@ export CODENAME
export ROOTDIR
export BUILDDIR
export LIBDIR
export BINTRAY_CACHE
export BINTRAY_USER
export BINTRAY_PASS
export BINTRAY_REPO

# Download cache
.PHONY: libcacheget
libcacheget:
@($(ROOTDIR)/support/lib.sh download $(LIB_NAME) &&\
$(ROOTDIR)/support/lib.sh unpack $(LIB_NAME) ) || true
ifneq ($(BINTRAY_CACHE),)
@( $(ROOTDIR)/support/lib.sh download $(LIB_NAME) &&\
$(ROOTDIR)/support/lib.sh unpack $(LIB_NAME) ) || true
endif

# Upload
.PHONY: libcacheput
libcacheput: build
ifneq ($(BINTRAY_USER),)
@$(ROOTDIR)/support/lib.sh upload $(LIB_NAME) $(LIB_FILES)
endif

# Do it all
.PHONY: liball
Expand Down

0 comments on commit e2d8d56

Please sign in to comment.