# Makefile for source rpm: frysk
# $Id: Makefile,v 1.6 2009/11/25 23:16:30 notting Exp $
NAME := frysk
SPECFILE = $(firstword $(wildcard *.spec))
define find-makefile-common
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
endef
MAKEFILE_COMMON := $(shell $(find-makefile-common))
ifeq ($(MAKEFILE_COMMON),)
# attempt a checkout
define checkout-makefile-common
test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2
endef
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
endif
include $(MAKEFILE_COMMON)
force-tag: $(SPECFILE) $(COMMON_DIR)/branches
@$(MAKE) tag TAG_OPTS="-F $(TAG_OPTS)"
# Make mock usable. The only standard target is mockbuild which
# doesn't do what you typically want.
mock-help help-mock:
@echo "Mock targets"
@echo " mock-local mock-build: Build from scratch using mock; keep the results"
@echo " mock-shell: Start a chrooted shell in the build-chroot"
@echo " mock-init: Initialize a new clean build-chroot"
@echo " mock-clean: Purge the build-chroot"
@echo " mock-update: Run yum update in the build-chroot"
@echo " mock-orphanskill: Kill any stray processes from the build"
@echo " mock-install PACKAGE=rpm: Install PACKAGE"
@echo " mock-installdeps PACKAGE=rpm: Install dependencies for PACKAGE"
@echo "Use MOCKARGS= for extra arguments"
.PHONY:: mock-help help-mock
# -prep -compile -install -compile-short -install-short
mock-local mock-build: srpm
mock --no-cleanup-after $(MOCKARGS) -r $(MOCKCFG) --resultdir=$(MOCKDIR)/$(TAG) --rebuild $(SRCRPMDIR)/$(NAME)-$(VERSION)-$(RELEASE).src.rpm
.PHONY:: mock-local mock-build
mock-init mock-clean mock-shell mock-update mock-orphanskill:
mock $(MOCKARGS) -r $(MOCKCFG) --resultdir=$(MOCKDIR)/$(TAG) --`expr $@ : 'mock-\(.*\)'`
.PHONY:: mock-init mock-clean mock-shell mock-update mock-orphanskill
mock-install mock-installdeps:
if test x"$(PACKAGE)" = x ; then echo Supply PACKAGE ; exit 1 ; fi
mock $(MOCKARGS) -r $(MOCKCFG) --resultdir=$(MOCKDIR)/$(TAG) --`expr $@ : 'mock-\(.*\)'` $(PACKAGE)
.PHONY:: mock-install mock-installdeps