mirror of
https://github.com/openwrt-xiaomi/builder.git
synced 2026-11-02 20:38:44 +05:00
xmake: Add support install custom patches
This commit is contained in:
1 parent
d625301034
commit
8889b52c08
1 file changed
+13
@@ -240,6 +240,19 @@ function build_target {
|
||||
fi
|
||||
fi
|
||||
|
||||
XPATCHES=$XDIR/patches
|
||||
for incfn in $XPATCHES/*.patch; do
|
||||
[ ! -f "$incfn" ] && continue
|
||||
inc=`patch -p1 -N -r - < "$incfn"`
|
||||
if [ $? != 0 ]; then
|
||||
if ! echo "$inc" | grep -q "patch detected! Skipping patch."; then
|
||||
echo "Patch '$(basename $incfn)' FAILED"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
echo "Patch '$(basename $incfn)' result: OK"
|
||||
done
|
||||
|
||||
OPKG_DIR=$XDIR/files/etc/opkg
|
||||
if [ -d $OPKG_DIR ]; then
|
||||
rm -rf $OPKG_DIR
|
||||
|
||||
Reference in new issue
Block a user