cvsdist 4d2792b
# Makefile for source rpm: binutils
c2859fc
# $Id: Makefile,v 1.1 2004/09/09 03:29:48 cvsdist Exp $
cvsdist 4d2792b
NAME := binutils
cvsdist 4d2792b
SPECFILE = $(firstword $(wildcard *.spec))
cvsdist 4d2792b
c2859fc
define find-makefile-common
c2859fc
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
c2859fc
endef
c2859fc
c2859fc
MAKEFILE_COMMON := $(shell $(find-makefile-common))
c2859fc
c2859fc
ifeq ($(MAKEFILE_COMMON),)
c2859fc
# attempt a checkout
c2859fc
define checkout-makefile-common
c2859fc
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
c2859fc
endef
c2859fc
c2859fc
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
c2859fc
endif
c2859fc
c2859fc
include $(MAKEFILE_COMMON)