b0549ae
# Makefile for source rpm: afuse
b0549ae
# $Id$
b0549ae
NAME := afuse
b0549ae
SPECFILE = $(firstword $(wildcard *.spec))
b0549ae
b0549ae
define find-makefile-common
b0549ae
for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done
b0549ae
endef
b0549ae
b0549ae
MAKEFILE_COMMON := $(shell $(find-makefile-common))
b0549ae
b0549ae
ifeq ($(MAKEFILE_COMMON),)
b0549ae
# attept a checkout
b0549ae
define checkout-makefile-common
b0549ae
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
b0549ae
endef
b0549ae
b0549ae
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
b0549ae
endif
b0549ae
b0549ae
include $(MAKEFILE_COMMON)