fb453cc
# Makefile for source rpm: eclipse-egit
d004fe0
# $Id: Makefile,v 1.1 2007/09/14 21:27:08 kevin Exp $
fb453cc
NAME := eclipse-egit
fb453cc
SPECFILE = $(firstword $(wildcard *.spec))
fb453cc
fb453cc
define find-makefile-common
d004fe0
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
fb453cc
endef
fb453cc
fb453cc
MAKEFILE_COMMON := $(shell $(find-makefile-common))
fb453cc
fb453cc
ifeq ($(MAKEFILE_COMMON),)
fb453cc
# attept a checkout
fb453cc
define checkout-makefile-common
fb453cc
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
fb453cc
endef
fb453cc
fb453cc
MAKEFILE_COMMON := $(shell $(checkout-makefile-common))
fb453cc
endif
fb453cc
fb453cc
include $(MAKEFILE_COMMON)