From 649559bfcccbf86e662972af3c4062b655695455 Mon Sep 17 00:00:00 2001
From: Ian Douglas Scott <ian@iandouglasscott.com>
Date: Thu, 8 Jun 2017 12:40:23 -0700
Subject: [PATCH] Handle patches in prepare

---
 cook.sh                    | 5 +++++
 recipes/gnu-make/recipe.sh | 1 -
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/cook.sh b/cook.sh
index 8fc93feb6..2a72a4339 100755
--- a/cook.sh
+++ b/cook.sh
@@ -88,6 +88,11 @@ function op {
         prepare)
             rm -rf build
             cp -r source build
+
+            for patch in *.patch
+            do
+                patch -p1 -d build < "$patch"
+            done
             ;;
         unprepare)
             rm -rf build
diff --git a/recipes/gnu-make/recipe.sh b/recipes/gnu-make/recipe.sh
index fe52243c5..74db2aeb1 100644
--- a/recipes/gnu-make/recipe.sh
+++ b/recipes/gnu-make/recipe.sh
@@ -26,7 +26,6 @@ function recipe_update {
 }
 
 function recipe_build {
-    patch -p1 < ../make.patch
     ./configure --host=${HOST} --prefix=/ CFLAGS=-DPOSIX --without-guile
     make
     return 1
-- 
GitLab