make-rules/prep-patch.mk
author Mike Sullivan <Mike.Sullivan@Oracle.COM>
Thu, 26 Jan 2017 16:44:14 -0800
changeset 7617 14b1a4293086
parent 7004 e6de22056378
permissions -rw-r--r--
Close of build 117.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     1
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     2
# CDDL HEADER START
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     3
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     7
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    11
# and limitations under the License.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    12
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    18
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    19
# CDDL HEADER END
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    20
#
5682
94c0ca64c022 15558602 TCL_LD_SEARCH_FLAGS is wrongly defined in tclConfig.sh
Shawn Walker-Salas <shawn.walker@oracle.com>
parents: 4357
diff changeset
    21
94c0ca64c022 15558602 TCL_LD_SEARCH_FLAGS is wrongly defined in tclConfig.sh
Shawn Walker-Salas <shawn.walker@oracle.com>
parents: 4357
diff changeset
    22
#
6911
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
    23
# Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved.
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    24
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    25
7003
539760b03c07 23228877 prepare for removal of /usr/gnu/bin/patch
Esha Wang <esha.wang@oracle.com>
parents: 6991
diff changeset
    26
GPATCH =	/usr/bin/patch
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    27
PATCH_LEVEL ?=	1
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    28
GPATCH_BACKUP =	--backup --version-control=numbered
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    29
GPATCH_FLAGS =	--strip=$(PATCH_LEVEL) $(GPATCH_BACKUP)
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    30
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    31
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    32
# Rules for patching source that is downloaded and unpacked or pulled from
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    33
# a source repository.  Patches should be named
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    34
# patches/{patch-file-name}.patch{version} where {patch-file-name} is a
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    35
# meaningful name for the patch contents and {version} corresponds to the
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    36
# COMPONENT_NAME{version} of the source to be patched.  Typically, version
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    37
# would be something like "_1", "_2", ...  After all {version} patches have
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    38
# been applied, a final set of patches without a {version} suffix may be
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    39
# applied.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    40
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    41
# PATCH_DIR can be overridden to move patches to a different location
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    42
# PATCH_PATTERN can be overridden to adjust the patch naming scheme that the
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    43
#     build recognizes.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    44
# EXTRA_PATCHES{version} can be defined in the component Makefile to include
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    45
#     additional patches.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    46
#
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    47
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    48
PATCH_PATTERN ?=	*.patch*
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    49
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    50
PATCH_DIR ?=		patches
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    51
# patches specific to parfait builds.
4254
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
    52
ifeq   ($(strip $(PARFAIT_BUILD)),yes)
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    53
PARFAIT_PATCH_DIR =	parfait
4254
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
    54
endif
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    55
7004
e6de22056378 23228877 prepare for removal of /usr/gnu/bin/patch (fix mismerge)
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 7003
diff changeset
    56
ALL_PATCHES =	$(shell find $(PATCH_DIR) $(PARFAIT_PATCH_DIR) -type f \
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    57
			 -name '$(PATCH_PATTERN)' 2>/dev/null | \
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    58
				LC_COLLATE=C sort)
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    59
6869
63619dbf968d 24611050 warning from prep-patch.mk when running gmake clobber for neutron
Laszlo Peter <laszlo.peter@oracle.com>
parents: 5682
diff changeset
    60
# Patches for different source tarballs have _X filename extensions to
63619dbf968d 24611050 warning from prep-patch.mk when running gmake clobber for neutron
Laszlo Peter <laszlo.peter@oracle.com>
parents: 5682
diff changeset
    61
# match the _X extensions to the COMPONENT_* make variables.  Find these
63619dbf968d 24611050 warning from prep-patch.mk when running gmake clobber for neutron
Laszlo Peter <laszlo.peter@oracle.com>
parents: 5682
diff changeset
    62
# extensions, using $(sort) to uniq them to prevent multiple rules from
63619dbf968d 24611050 warning from prep-patch.mk when running gmake clobber for neutron
Laszlo Peter <laszlo.peter@oracle.com>
parents: 5682
diff changeset
    63
# getting generated.
7004
e6de22056378 23228877 prepare for removal of /usr/gnu/bin/patch (fix mismerge)
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 7003
diff changeset
    64
PCH_SUFFIXES = $(sort $(patsubst .patch_%,%, $(filter-out .patch,$(suffix $(ALL_PATCHES)))))
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    65
6911
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
    66
define patch-variables
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    67
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    68
ifeq ($(1),_0)
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    69
PATCH_PATTERN$(1) ?=	%.patch
7004
e6de22056378 23228877 prepare for removal of /usr/gnu/bin/patch (fix mismerge)
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 7003
diff changeset
    70
PATCHES$(1) = $(filter %.patch,$(ALL_PATCHES))
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    71
else
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    72
PATCH_PATTERN$(1) ?=	%.patch$(1)
7004
e6de22056378 23228877 prepare for removal of /usr/gnu/bin/patch (fix mismerge)
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 7003
diff changeset
    73
PATCHES$(1) = $(filter %.patch$(1),$(ALL_PATCHES))
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    74
endif
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    75
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    76
ifneq ($$(PATCHES$(1)),)
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    77
PATCH_STAMPS$(1) += $$(PATCHES$(1):$(PATCH_DIR)/%=$$(SOURCE_DIR$(1))/.patched-%)
4254
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
    78
ifeq   ($(strip $(PARFAIT_BUILD)),yes)
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
    79
PATCH_STAMPS$(1) += $$(PATCHES$(1):$(PARFAIT_PATCH_DIR)/%=$$(SOURCE_DIR$(1))/.patched-%)
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
    80
endif 
6911
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
    81
endif
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
    82
endef
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    83
6911
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
    84
define patch-rules
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
    85
ifneq ($$(PATCHES$(1)),)
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    86
# We should unpack the source that we patch before we patch it.
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    87
$$(PATCH_STAMPS$(1)::	$$(UNPACK_STAMP$(1)) unpack
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    88
4357
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
    89
# Adding MAKEFILE_PREREQ because gmake seems to evaluate the need to patch
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
    90
# before re-unpacking if the Makefile changed.  The various stamps are
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
    91
# removed as part of the unpacking process, and it doesn't appear to
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
    92
# re-evaluate the need for patching.  If we ever move the stamps to the build
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
    93
# directory, we may not need the dependency any more.
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
    94
$$(SOURCE_DIR$(1))/.patched-%:	$(PATCH_DIR)/% $(MAKEFILE_PREREQ)
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    95
	$(GPATCH) -d $$(@D) $$(GPATCH_FLAGS) < $$<
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    96
	$(TOUCH) $$(@)
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
    97
4357
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
    98
$$(SOURCE_DIR$(1))/.patched-%:	$(PARFAIT_PATCH_DIR)/% $(MAKEFILE_PREREQ)
4254
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
    99
	$(GPATCH) -d $$(@D) $$(GPATCH_FLAGS) < $$<
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
   100
	$(TOUCH) $$(@)
f1fca132ea31 21020731 parfait-only patching seems broken
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4252
diff changeset
   101
4357
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
   102
$$(SOURCE_DIR$(1))/.patched:	$$(PATCH_STAMPS$(1))
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
   103
	$(TOUCH) $$(@)
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
   104
417c7cb1b3aa 21086455 gmake prep doesn't always apply patches
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 4254
diff changeset
   105
patch::	$$(SOURCE_DIR$(1))/.patched
4196
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
   106
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
   107
REQUIRED_PACKAGES += text/gnu-patch
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
   108
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
   109
endif
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
   110
endef
d697072a92f5 19782029 userland should be able to build from SCM repositories
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents:
diff changeset
   111
6911
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   112
# Evaluate the variable assignments immediately.
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   113
$(foreach suffix, $(PCH_SUFFIXES), $(eval $(call patch-variables,_$(suffix))))
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   114
$(eval $(call patch-variables,))	# this must be last so we don't drop *.patch_%.
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   115
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   116
# Put the rule evaluations in a variable for deferred evaluation.
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   117
define eval-patch-rules
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   118
$(foreach suffix, $(PCH_SUFFIXES), $(eval $(call patch-rules,_$(suffix))))
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   119
$(eval $(call patch-rules,))	# this must be last so we don't drop *.patch_%.
7b878dfe6f0d 24661161 COMPONENT_SRC and COMPONENT_ARCHIVE are un-overridable in prep-*.mk
Danek Duvall <danek.duvall@oracle.com>
parents: 6869
diff changeset
   120
endef