530f4de
# Makefile for source rpm: perl-Text-WordDiff
60e76f5
# $Id: Makefile,v 1.1 2007/07/23 21:13:57 wtogami Exp $
530f4de
NAME := perl-Text-WordDiff
530f4de
SPECFILE = $(firstword $(wildcard *.spec))
530f4de
530f4de
define find-makefile-common
60e76f5
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
530f4de
endef
530f4de
530f4de
MAKEFILE_COMMON := $(shell $(find-makefile-common))
530f4de
530f4de
ifeq ($(MAKEFILE_COMMON),)
530f4de
# attept a checkout
530f4de
define checkout-makefile-common
530f4de
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
530f4de
endef
530f4de
530f4de
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
530f4de
endif
530f4de
530f4de
include $(MAKEFILE_COMMON)