summaryrefslogtreecommitdiff
path: root/packages/frr
diff options
context:
space:
mode:
authorChristian Poessinger <christian@poessinger.com>2020-06-28 11:16:46 +0200
committerChristian Poessinger <christian@poessinger.com>2020-06-28 20:33:00 +0200
commit65f32962f1c7ba102674fdad59d3c9c68ec37dc2 (patch)
tree69d002b38c8a6491ee194615a0002228afd558e5 /packages/frr
parent99974b73202e5cf44cc944ec1b0507c0c5a53dca (diff)
downloadvyos-build-65f32962f1c7ba102674fdad59d3c9c68ec37dc2.tar.gz
vyos-build-65f32962f1c7ba102674fdad59d3c9c68ec37dc2.zip
T2638: frr: use "git am" to apply patches
Diffstat (limited to 'packages/frr')
-rwxr-xr-xpackages/frr/build-frr.sh14
1 files changed, 5 insertions, 9 deletions
diff --git a/packages/frr/build-frr.sh b/packages/frr/build-frr.sh
index 59134832..477c41e3 100755
--- a/packages/frr/build-frr.sh
+++ b/packages/frr/build-frr.sh
@@ -17,19 +17,15 @@ cd ${FRR_SRC}
PATCH_DIR=${CWD}/patches
+echo "I: Apply FRRouting patches not in main repository:"
for patch in $(ls ${PATCH_DIR})
do
- echo "I: Apply FRR patch: ${PATCH_DIR}/${patch}"
- patch -p1 < ${PATCH_DIR}/${patch}
- git add $(lsdiff ${PATCH_DIR}/${patch} | sed -e 's#^[ab]/##')
if [ -z "$(git config --list | grep -e user.name -e user.email)" ]; then
- # if git user.name and user.email is not set, -c sets temorary user.name and
- # user.email variables as these is not set in the build container by default.
- git -c user.name="VyOS CI" -c user.email="ci@vyos.io" commit -m "Applied patch: ${patch}" --author "VyOS CI <ci@vyos.io>"
- else
- git commit -m "Applied patch: ${patch}" --author "VyOS CI <ci@vyos.io>"
+ # if git user.name and user.email is not set, -c sets temorary user.name and
+ # user.email variables as these is not set in the build container by default.
+ OPTS="-c user.name=VyOS-CI -c user.email=maintainers@vyos.io"
fi
-
+ git $OPTS am ${PATCH_DIR}/${patch}
done
# Prepare FRR source for building