summaryrefslogtreecommitdiff
path: root/recipes-kernel/rs9113
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-kernel/rs9113')
-rw-r--r--recipes-kernel/rs9113/rs9113-from-src_1.5.6.bb17
1 files changed, 10 insertions, 7 deletions
diff --git a/recipes-kernel/rs9113/rs9113-from-src_1.5.6.bb b/recipes-kernel/rs9113/rs9113-from-src_1.5.6.bb
index 0f05e82..a4867ec 100644
--- a/recipes-kernel/rs9113/rs9113-from-src_1.5.6.bb
+++ b/recipes-kernel/rs9113/rs9113-from-src_1.5.6.bb
@@ -56,13 +56,16 @@ do_patch () {
cd ${WORKDIR}/git
echo "patches" ${M}/patches/*
for f in ${M}/patches/* ; do
- # If no patches, * is not expanded.
- # Do not try to use "*" as a patch file.
- if ! [[ -r ${f} ]] ; then
- continue
- fi
- echo "Patching with ${f}"
- patch -p1 < ${f}
+ # Cannot use [[ $f =~ \.patch$ ]] here because the $ after patch breaks the recipe.
+ if echo ${f} | grep '\.patch$' >/dev/null 2>&1 ; then
+ echo found patch ${f}
+ patch -Np1 < ${f}
+ else
+ fname=$(basename ${f})
+ oldf=$(find . -name ${fname})
+ echo "copying $f to ${oldf}"
+ cp ${f} ${oldf}
+ fi
done
}