From 9a89e57d76144d11621096914b28b582cb2e1a12 Mon Sep 17 00:00:00 2001 From: Rosen Penev Date: Tue, 18 Aug 2020 02:18:18 -0700 Subject: [PATCH] quagga: update to 1.2.4 Refreshed patches. Removed one since OpenWrt no longer uses union mounts. Fixed up gcc10 patch as well. Signed-off-by: Rosen Penev --- quagga/Makefile | 6 +-- quagga/patches/140-holdtimer-set.patch | 16 ++++---- quagga/patches/150-no-cross-fs-link.patch | 40 ------------------- quagga/patches/170-use-supported-pagers.patch | 6 +-- quagga/patches/200-gcc10.patch | 2 +- 5 files changed, 15 insertions(+), 55 deletions(-) delete mode 100644 quagga/patches/150-no-cross-fs-link.patch diff --git a/quagga/Makefile b/quagga/Makefile index 29af28b..b259a3d 100644 --- a/quagga/Makefile +++ b/quagga/Makefile @@ -8,9 +8,9 @@ include $(TOPDIR)/rules.mk PKG_NAME:=quagga -PKG_VERSION:=1.1.0 -PKG_RELEASE:=2 -PKG_HASH:=f7a43a9c59bfd3722002210530b2553c8d5cc05bfea5acd56d4f102b9f55dc63 +PKG_VERSION:=1.2.4 +PKG_RELEASE:=1 +PKG_HASH:=e364c082c3309910e1eb7b068bf39ee298e2f2f3f31a6431a5c115193bd653d3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=@SAVANNAH/quagga/ diff --git a/quagga/patches/140-holdtimer-set.patch b/quagga/patches/140-holdtimer-set.patch index 6d1c1ea..2494ad8 100644 --- a/quagga/patches/140-holdtimer-set.patch +++ b/quagga/patches/140-holdtimer-set.patch @@ -1,22 +1,22 @@ --- a/bgpd/bgp_network.c +++ b/bgpd/bgp_network.c -@@ -257,8 +257,7 @@ bgp_accept (struct thread *thread) - peer->fd = bgp_sock; - peer->status = Active; +@@ -255,8 +255,7 @@ bgp_accept (struct thread *thread) + + /* Config state that should affect OPEN packet must be copied over */ peer->local_id = peer1->local_id; - peer->v_holdtime = peer1->v_holdtime; - peer->v_keepalive = peer1->v_keepalive; + peer->v_holdtime = BGP_LARGE_HOLDTIME; - - /* Make peer's address string. */ - sockunion2str (&su, buf, SU_ADDRSTRLEN); + peer->local_as = peer1->local_as; + peer->change_local_as = peer1->change_local_as; + peer->flags = peer1->flags; --- a/bgpd/bgpd.h +++ b/bgpd/bgpd.h -@@ -752,6 +752,7 @@ struct bgp_nlri +@@ -754,6 +754,7 @@ struct bgp_nlri /* BGP timers default value. */ #define BGP_INIT_START_TIMER 1 +#define BGP_LARGE_HOLDTIME 240 #define BGP_DEFAULT_HOLDTIME 180 #define BGP_DEFAULT_KEEPALIVE 60 - #define BGP_DEFAULT_EBGP_ROUTEADV 30 + #define BGP_DEFAULT_EBGP_ROUTEADV 3 diff --git a/quagga/patches/150-no-cross-fs-link.patch b/quagga/patches/150-no-cross-fs-link.patch deleted file mode 100644 index 8445103..0000000 --- a/quagga/patches/150-no-cross-fs-link.patch +++ /dev/null @@ -1,40 +0,0 @@ ---- a/lib/command.c -+++ b/lib/command.c -@@ -3198,6 +3198,13 @@ DEFUN (config_write_file, - VTY_NEWLINE); - goto finished; - } -+ -+#if 0 -+ /* This code fails on UNION MOUNTs and similar filesystems if the -+ * config file is still on the RO layer. Hardlinks across layers -+ * will not work and cause quagga to fail saving the configuration... -+ * should use rename() to move files around... -+ */ - if (link (config_file, config_file_sav) != 0) - { - vty_out (vty, "Can't backup old configuration file %s.%s", config_file_sav, -@@ -3211,7 +3218,23 @@ DEFUN (config_write_file, - VTY_NEWLINE); - goto finished; - } -+#else -+ /* And this is the code that hopefully does work */ -+ if (rename (config_file, config_file_sav) != 0) -+ { -+ vty_out (vty, "Can't backup old configuration file %s.%s", config_file_sav, -+ VTY_NEWLINE); -+ goto finished; -+ } -+ sync (); -+#endif -+ -+#if 0 -+ /* same here. Please no cross-filesystem hardlinks... */ - if (link (config_file_tmp, config_file) != 0) -+#else -+ if (rename (config_file_tmp, config_file) != 0) -+#endif - { - vty_out (vty, "Can't save configuration file %s.%s", config_file, - VTY_NEWLINE); diff --git a/quagga/patches/170-use-supported-pagers.patch b/quagga/patches/170-use-supported-pagers.patch index ad4c4db..250837f 100644 --- a/quagga/patches/170-use-supported-pagers.patch +++ b/quagga/patches/170-use-supported-pagers.patch @@ -1,6 +1,6 @@ --- a/vtysh/vtysh.c +++ b/vtysh/vtysh.c -@@ -251,7 +251,7 @@ vtysh_pager_init (void) +@@ -253,7 +253,7 @@ vtysh_pager_init (void) if (pager_defined) vtysh_pager_name = strdup (pager_defined); else @@ -9,7 +9,7 @@ } /* Command execution over the vty interface. */ -@@ -2047,7 +2047,7 @@ DEFUN (vtysh_terminal_length, +@@ -2214,7 +2214,7 @@ DEFUN (vtysh_terminal_length, { int lines; char *endptr = NULL; @@ -18,7 +18,7 @@ lines = strtol (argv[0], &endptr, 10); if (lines < 0 || lines > 512 || *endptr != '\0') -@@ -2064,7 +2064,7 @@ DEFUN (vtysh_terminal_length, +@@ -2231,7 +2231,7 @@ DEFUN (vtysh_terminal_length, if (lines != 0) { diff --git a/quagga/patches/200-gcc10.patch b/quagga/patches/200-gcc10.patch index 3a05255..74f0e58 100644 --- a/quagga/patches/200-gcc10.patch +++ b/quagga/patches/200-gcc10.patch @@ -26,7 +26,7 @@ -struct in_addr qpim_all_pim_routers_addr; +extern int qpim_mroute_oif_highest_vif_index; +extern struct list *qpim_channel_oil_list; /* list of struct channel_oil */ -+extern struct in_addr qpim_all_pim_routers_addr; ++static struct in_addr qpim_all_pim_routers_addr; int qpim_t_periodic; /* Period between Join/Prune Messages */ -struct list *qpim_upstream_list; /* list of struct pim_upstream */ +extern struct list *qpim_upstream_list; /* list of struct pim_upstream */ -- 2.30.2