summaryrefslogtreecommitdiffhomepage
path: root/subr/pkg_patch_pre.subr
diff options
context:
space:
mode:
Diffstat (limited to 'subr/pkg_patch_pre.subr')
-rw-r--r--subr/pkg_patch_pre.subr23
1 files changed, 23 insertions, 0 deletions
diff --git a/subr/pkg_patch_pre.subr b/subr/pkg_patch_pre.subr
new file mode 100644
index 00000000..2671d32c
--- /dev/null
+++ b/subr/pkg_patch_pre.subr
@@ -0,0 +1,23 @@
+#
+# . ./build.vars and set -o errexit -o noglob are assumed.
+# See warning at the top of build.vars.
+#
+
+pkg_patch_pre() {
+ 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; unset __;
+ if test_cmd pkg_${PKG_NAME}_patch_pre_post; then
+ pkg_${PKG_NAME}_patch_pre_post;
+ fi;
+ set_build_script_done patch_pre -autoconf;
+};
+
+# vim:filetype=sh