summaryrefslogtreecommitdiffstats
path: root/rules/kernel-rmk.make
blob: efc68327539c67dba6d4f030ff9cb329a79f70d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# -*-makefile-*-
# $Id$
#
# Copyright (C) 2003 by Marc Kleine-Budde <kleine-budde.de>
#          
# See CREDITS for details about who has contributed to this project.
#
# For further information about the PTXdist project and license conditions
# see the README file.
#

#
# We provide this package
#
# ifdef PTXCONF_KERNEL_RMK
# KERNEL_PATCHES += kernel-rmk
# endif

#
# Paths and names
#
KERNEL_RMK_VERSION	= $(call get_option, \
	s/^PTXCONF_KERNEL_\([0-9]\)_\([0-9]\)_\([0-9]*\)_\(rmk[0-9]\).*/\1.\2.\3-\4/, rmk)
KERNEL_RMK		= patch-$(KERNEL_RMK_VERSION)
KERNEL_RMK_SUFFIX	= bz2
KERNEL_RMK_URL		= ftp://ftp.arm.linux.org.uk/pub/armlinux/source/kernel-patches/v$(KERNEL_VERSION_MAJOR).$(KERNEL_VERSION_MINOR)/$(KERNEL_RMK).$(KERNEL_RMK_SUFFIX)
KERNEL_RMK_SOURCE	= $(SRCDIR)/$(KERNEL_RMK).$(KERNEL_RMK_SUFFIX)


# ----------------------------------------------------------------------------
# Get
# ----------------------------------------------------------------------------

kernel-rmk_get: $(STATEDIR)/kernel-rmk.get

kernel-rmk_get_deps = \
	$(KERNEL_RMK_SOURCE)

$(STATEDIR)/kernel-rmk.get: $(kernel-rmk_get_deps)
	@$(call targetinfo, $@)
	touch $@

$(KERNEL_RMK_SOURCE):
	@$(call targetinfo, $@)
	@$(call get, $(KERNEL_RMK_URL))

# ----------------------------------------------------------------------------
# Install
# ----------------------------------------------------------------------------

kernel-rmk_install: $(STATEDIR)/kernel-rmk.install

$(STATEDIR)/kernel-rmk.install: $(STATEDIR)/kernel-rmk.get
	@$(call targetinfo, $@)
	@$(call patch_apply, $(KERNEL_RMK_SOURCE), $(KERNEL_DIR))
	touch $@

# ----------------------------------------------------------------------------
# Clean
# ----------------------------------------------------------------------------

kernel-rmk_clean:
	rm -rf $(STATEDIR)/kernel*

# vim: syntax=make