HOSTARCH := $(shell uname -i)
DISTRO := $(shell ./getdistro.sh)
RELEASE := $(shell ./getrelease.sh)
+DISTRONAME := $(shell ./getdistroname.sh)
RPM-INSTALL-DEVEL := rpm --force -Uvh
# cannot force rpm -e
RPM-UNINSTALL-DEVEL := rpm -e
#
define package_hasdate
$(1).has-date = $(if $(subst myplc,,$(1)), \
- $(if $($(1)-SVNPATH),\
- $(if $(findstring /trunk,$($(1)-SVNPATH)),yes,),\
- $(if $(findstring HEAD,$($(1)-TAG)),yes,)), \
+ $(if $($($(1).module)-SVNPATH),\
+ $(if $(findstring /trunk,$($($(1).module)-SVNPATH)),yes,),\
+ $(if $(findstring HEAD,$($($(1).module)-TAG)),yes,)), \
yes)
endef
$($(1).specpath):
mkdir -p SPECS
(echo -n "# Generated by planetlab build from $($(1)-SPEC) on " ; date) > $($(1).specpath)
- echo "%define distroname $(DISTRO)" >> $($(1).specpath)
+ echo "%define distro $(DISTRO)" >> $($(1).specpath)
echo "%define distrorelease $(RELEASE)" >> $($(1).specpath)
+ echo "%define distroname $(DISTRONAME)" >> $($(1).specpath)
echo "%define pldistro $(PLDISTRO)" >> $($(1).specpath)
echo "%define plrelease $(PLANETLAB_RELEASE)" >> $($(1).specpath)
$(if $($(1).has-date),echo "%define date $(shell date +%Y.%m.%d)" >> $($(1).specpath),)
version-build:
@echo -n 'Build build-date: ' ; date '+%Y.%m.%d'
- @echo -n 'Build build-time: ' ; date '+%H:%M'
+ @echo -n 'Build build-time: ' ; date '+%H:%M-%Z'
@echo -n 'Build build-hostname: ' ; hostname
@echo "Build build-base: $(NIGHTLY_BASE)"
- @echo "Build planetab-distro: $(PLDISTRO)"
+ @echo "Build planetlab-distro: $(PLDISTRO)"
@echo "Build planetlab-tags: $(PLDISTROTAGS)"
@echo -n 'Build planetlab-tagsid: ' ; fgrep '$$''Id' $(PLDISTROTAGS)
@echo "Build target-arch: $(HOSTARCH)"