diff --git a/Makefile b/Makefile index b030aa6..dbcc478 100644 --- a/Makefile +++ b/Makefile @@ -2,23 +2,29 @@ GLUON_BUILD_DIR := gluon-build GLUON_GIT_URL := git://github.com/freifunk-gluon/gluon.git GLUON_GIT_REF := 08ecab23dec1e43b02fdca4caa86d2b7940b2f12 -JOBS ?= $(shell cat /proc/cpuinfo | grep processor | wc -l) - -_GIT_DESCRIBE = $(shell git describe --tags 2>&1) +_GIT_DESCRIBE = $(shell git describe --tags 2>/dev/null) ifneq (,${_GIT_DESCRIBE}) GLUON_RELEASE := ${_GIT_DESCRIBE} - GLUON_BRANCH ?= stable + GLUON_BRANCH := stable else - GLUON_BRANCH ?= nightly + GLUON_RELEASE ?= snapshot~$(shell date '+%Y%m%d')~$(shell git describe --always) endif +JOBS ?= $(shell cat /proc/cpuinfo | grep processor | wc -l) + +GLUON_MAKE := ${MAKE} -j ${JOBS} -C ${GLUON_BUILD_DIR} \ + GLUON_RELEASE=${GLUON_RELEASE} \ + GLUON_BRANCH=${GLUON_BRANCH} + all: build build: gluon-prepare - cd ${GLUON_BUILD_DIR} \ - && make update \ - && make -j ${JOBS} \ - && make manifest + echo '${GLUON_RELEASE} (${GLUON_BRANCH})' + ${GLUON_MAKE} update + ${GLUON_MAKE} images + +manifest: gluon-prepare + ${GLUON_MAKE} manifest ${GLUON_BUILD_DIR}: git clone ${GLUON_GIT_URL} ${GLUON_BUILD_DIR} diff --git a/site.mk b/site.mk index 71c3209..717a1b2 100644 --- a/site.mk +++ b/site.mk @@ -23,7 +23,7 @@ GLUON_SITE_PACKAGES := \ haveged -DEFAULT_GLUON_RELEASE := nightly~$(shell date '+%Y%m%d')~$(shell cd ../../../.. && git describe --always --abbrev=8) +DEFAULT_GLUON_RELEASE := snapshot~$(shell date '+%Y%m%d') # Allow overriding the release number from the command line GLUON_RELEASE ?= $(DEFAULT_GLUON_RELEASE)