summaryrefslogtreecommitdiffhomepage
path: root/subr/pkg_patch_pre.subr
blob: 566299a2228b9fa0f9a6b201260eda106106081e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#
# set -o errexit -o noglob are assumed.
#

pkg_patch_pre() {
	local __;
	for __ in 											\
			${MIDIPIX_BUILD_PWD}/../${PKG_SUBDIR}_pre.local.patch				\
			${MIDIPIX_BUILD_PWD}/../${PKG_SUBDIR}_pre.local@${BUILD_HNAME}.patch		\
			${WORKDIR}/chainport/${PKG_SUBDIR}_pre.midipix.patch				\
			${MIDIPIX_BUILD_PWD}/patches/${PKG_SUBDIR}_pre.local.patch			\
			${MIDIPIX_BUILD_PWD}/patches/${PKG_SUBDIR}_pre.local@${BUILD_HNAME}.patch; do
		if [ -r "${__}" ]; then
			patch -b -d ${PKG_SUBDIR} -p1 < ${__};
		fi;
	done;
	if test_cmd pkg_${PKG_NAME}_patch_pre_post; then
		pkg_${PKG_NAME}_patch_pre_post;
	fi;
};

# vim:filetype=sh