####################
# gather build information for the 'About' page
+# uses INIT_CWD to try and guess the vserver location
myplc-release:
@echo 'Creating myplc-release'
rm -f $@
(echo -n 'Build bdate: ' ; date '+%Y.%m.%d') >> $@
(echo -n 'Build btime: ' ; date '+%H:%M') >> $@
- (echo -n 'Build hostname: ' ; hostname) >> $@
- (echo -n 'Build location: ' ; pwd) >> $@
+ (echo -n 'Build bhostname: ' ; hostname) >> $@
+ (echo "Build blocation: $(INIT_CWD)") >> $@
(echo -n 'Build tags file: ' ; fgrep '$$''Id' $(PLDISTROTAGS)) >> $@
+ (echo "Build tarch: $(HOSTARCH)") >> $@
+ (echo "Build tdistro: $(DISTRO)") >> $@
+ (echo "Build trelease: $(RELEASE)") >> $@
echo "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx modules versions info" >> $@
$(MAKE) --no-print-directory versions >> $@
develclean:
$(RPM-UNINSTALL-DEVEL) $(ALL-DEVEL-RPMS)
-# xxx tmp - I cannot use this on my mac for local testing
-ISMACOS=$(findstring Darwin,$(shell uname))
-ifneq "$(ISMACOS)" ""
#################### produce reliable version information
# for a given module
VFORMAT="%30s := %s\n"
$(foreach module,$(ALL-MODULES), $(eval $(call print_version,$(module))))
versions: $(foreach module, $(ALL-MODULES), $(module)-version)
-else
-versions:
- @echo "warning : the 'versions' target is not supported on macos"
-endif
#################### include install Makefile
# the default is to use the distro-dependent install file
# figure out which redhat distro we are using (fedora, centos, redhat)
pl_DISTRO=$(pl_getDistro)
-# select basearch of the host devel environment
-pl_DISTRO_ARCH=$(uname -i)
+# select basearch of the host devel environment - protected for macos for local tests
+pl_DISTRO_ARCH=$(uname -i 2>/dev/null|| echo unknownarch))
# let mkfedora select one of its mirrors
pl_DISTRO_URL=""
return $shiftcount
}
+######################################## handling a root image
function pl_makedevs() {
vroot=$1
# Clean ${vroot}/dev, but only when ${vroot}!=""
}
function pl_setup_chroot() {
- root=$1
- shift
- options=$@
+ root=$1; shift
+ options="$@"
pl_mkfedora $root $options
function pl_getPackages() { fcdistro=$1; shift ; pl_parsePkgs package $fcdistro "$@" ; }
function pl_getGroups() { fcdistro=$1; shift ; pl_parsePkgs group $fcdistro "$@" ; }
-### # add -p before each package for mkfedora
-### function pl_getPackagesOptions2 () { pl_getPackages2 "$@" | awk '{for (i=1;i<=NF;i++) {print "-p " $i}}' ; }
-### # add -g before each group for mkfedora
-### function pl_getGroupsOptions2 () { pl_getGroups2 "$@" | awk '{for (i=1;i<=NF;i++) {print "-g " $i}}' ; }
# locates a pldistro-dependant file
# tries first in build/<pldistro>/, then in build/planetlab/