forked from remote/site-ffmuc
Makefile: Misc release-releated build fixes
This commit is contained in:
24
Makefile
24
Makefile
@@ -2,23 +2,29 @@ GLUON_BUILD_DIR := gluon-build
|
|||||||
GLUON_GIT_URL := git://github.com/freifunk-gluon/gluon.git
|
GLUON_GIT_URL := git://github.com/freifunk-gluon/gluon.git
|
||||||
GLUON_GIT_REF := 08ecab23dec1e43b02fdca4caa86d2b7940b2f12
|
GLUON_GIT_REF := 08ecab23dec1e43b02fdca4caa86d2b7940b2f12
|
||||||
|
|
||||||
JOBS ?= $(shell cat /proc/cpuinfo | grep processor | wc -l)
|
_GIT_DESCRIBE = $(shell git describe --tags 2>/dev/null)
|
||||||
|
|
||||||
_GIT_DESCRIBE = $(shell git describe --tags 2>&1)
|
|
||||||
ifneq (,${_GIT_DESCRIBE})
|
ifneq (,${_GIT_DESCRIBE})
|
||||||
GLUON_RELEASE := ${_GIT_DESCRIBE}
|
GLUON_RELEASE := ${_GIT_DESCRIBE}
|
||||||
GLUON_BRANCH ?= stable
|
GLUON_BRANCH := stable
|
||||||
else
|
else
|
||||||
GLUON_BRANCH ?= nightly
|
GLUON_RELEASE ?= snapshot~$(shell date '+%Y%m%d')~$(shell git describe --always)
|
||||||
endif
|
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
|
all: build
|
||||||
|
|
||||||
build: gluon-prepare
|
build: gluon-prepare
|
||||||
cd ${GLUON_BUILD_DIR} \
|
echo '${GLUON_RELEASE} (${GLUON_BRANCH})'
|
||||||
&& make update \
|
${GLUON_MAKE} update
|
||||||
&& make -j ${JOBS} \
|
${GLUON_MAKE} images
|
||||||
&& make manifest
|
|
||||||
|
manifest: gluon-prepare
|
||||||
|
${GLUON_MAKE} manifest
|
||||||
|
|
||||||
${GLUON_BUILD_DIR}:
|
${GLUON_BUILD_DIR}:
|
||||||
git clone ${GLUON_GIT_URL} ${GLUON_BUILD_DIR}
|
git clone ${GLUON_GIT_URL} ${GLUON_BUILD_DIR}
|
||||||
|
|||||||
2
site.mk
2
site.mk
@@ -23,7 +23,7 @@ GLUON_SITE_PACKAGES := \
|
|||||||
haveged
|
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
|
# Allow overriding the release number from the command line
|
||||||
GLUON_RELEASE ?= $(DEFAULT_GLUON_RELEASE)
|
GLUON_RELEASE ?= $(DEFAULT_GLUON_RELEASE)
|
||||||
|
|||||||
Reference in New Issue
Block a user