linux-rpm.mk: Add auto-download of kernel tarball

Download kernel package only if it does not yet exist in samba
directory
This commit is contained in:
Jan Lindemann 2004-05-12 05:14:26 +00:00 committed by Jan Lindemann
commit 234198936f

View file

@ -22,11 +22,7 @@ TMP_INSTALL = $(KERNEL_BASE)-$(KERNEL_VERSION)-$(KERNEL_RELEASE)
TAG = $(shell echo V_$(KERNEL_VERSION)_$(KERNEL_RELEASE) | sed 's/\./_/g')
ifeq ($(wildcard RELEASE-$(KERNEL_VERSION)),)
<<<<<<< linux-rpm.mk
KERNEL_RELEASE := $(shell echo '\# $$Id$(KERNEL_VERSION),v 0.1$$' \
=======
KERNEL_RELEASE := $(shell echo '\# $$Id$(KERNEL_VERSION),v 0.1$$' \
>>>>>>> 1.1.2.2
KERNEL_RELEASE := $(shell echo '\# \$$""Id:"$$"' \
> RELEASE-$(KERNEL_VERSION); \
cvs add RELEASE-$(KERNEL_VERSION); \
cvs commit -m "initial checkin" RELEASE-$(KERNEL_VERSION); \
@ -69,11 +65,10 @@ export KERNEL_INSTALL_PREFIX
all: rpm
# file rules
$(KERNEL_TGZ):
$(KERNEL_PKG):
mkdir -p $(dirname $(KERNEL_PKG)
ftp -a ftp.kernel.org:/pub/linux/kernel/v$(basename $(KERNEL_VERSION))/$(KERNEL_TGZ)
$(KERNEL_PKG): $(KERNEL_TGZ)
install -m 664 $< $@
install -m 664 $(KERNEL_TGZ) $@
config-$(KERNEL_VERSION):
cp $(shell ls config-$(basename $(KERNEL_VERSION)).* | sed 's/\([0-9]*\)\.\([0-9]*\)\.\([0-9]\)$$/\1.\2.0\3/' | sort -g | sed 's/\.0/./; $$ !d') $@