diff --git a/debian/rules b/debian/rules index c249299c3..950c5bf92 100755 --- a/debian/rules +++ b/debian/rules @@ -36,13 +36,16 @@ $(STAMPS_DIR)/build-base: $(BUILD_DIR) $(STAMPS_DIR) $(STAMPS_DIR)/setup-base $(BUILD_DIR) $(STAMPS_DIR): @[ -d $@ ] || mkdir $@ -orig: ../orig/linux-$(MAJOR)-$(VERSION) - rsync --delete --exclude debian --exclude .svn --link-dest=../orig/linux-$(MAJOR)-$(VERSION)/ -a ../orig/linux-$(MAJOR)-$(VERSION)/ . +DIR_ORIG = ../orig/linux-$(MAJOR)-$(VERSION) +TAR_ORIG = ../linux-$(MAJOR)_$(VERSION).orig.tar.gz -../orig/linux-$(MAJOR)-$(VERSION): - if [ -f "../linux-$(MAJOR)_$(VERSION).orig.tar.gz" ]; then \ +orig: $(DIR_ORIG) + rsync --delete --exclude debian --exclude .svn --link-dest=$(DIR_ORIG)/ -a $(DIR_ORIG)/ . + +$(DIR_ORIG): + if [ -f $(TAR_ORIG) ]; then \ mkdir -p ../orig; \ - tar -C ../orig -xzf ../linux-$(MAJOR)_$(VERSION).orig.tar.gz; \ + tar -C ../orig -xzf $(TAR_ORIG); \ else \ echo "Can't find orig tarball." >&2; \ exit 1; \