landgraf / rpms / bind

Forked from rpms/bind 6 years ago
Clone
cvsdist 49b320d
# Makefile for source rpm: bind
86e08aa
# $Id: Makefile,v 1.1 2004/09/09 03:29:05 cvsdist Exp $
cvsdist 49b320d
NAME := bind
cvsdist 49b320d
SPECFILE = $(firstword $(wildcard *.spec))
cvsdist 49b320d
86e08aa
define find-makefile-common
86e08aa
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
86e08aa
endef
86e08aa
86e08aa
MAKEFILE_COMMON := $(shell $(find-makefile-common))
86e08aa
86e08aa
ifeq ($(MAKEFILE_COMMON),)
86e08aa
# attempt a checkout
86e08aa
define checkout-makefile-common
86e08aa
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
86e08aa
endef
86e08aa
86e08aa
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
86e08aa
endif
86e08aa
86e08aa
include $(MAKEFILE_COMMON)