All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10
@ 2021-03-06 15:56 Fabrice Fontaine
  2021-03-06 19:37 ` Peter Korsgaard
  2021-03-16 22:20 ` Peter Korsgaard
  0 siblings, 2 replies; 6+ messages in thread
From: Fabrice Fontaine @ 2021-03-06 15:56 UTC (permalink / raw)
  To: buildroot

Fixes:
 - http://autobuild.buildroot.org/results/fd5ee2b52a3cfaec268fafd3ffe4c30e51465c7e

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 .../quagga/0003-Fix-build-with-gcc-10.patch   | 127 ++++++++++++++++++
 1 file changed, 127 insertions(+)
 create mode 100644 package/quagga/0003-Fix-build-with-gcc-10.patch

diff --git a/package/quagga/0003-Fix-build-with-gcc-10.patch b/package/quagga/0003-Fix-build-with-gcc-10.patch
new file mode 100644
index 0000000000..fbe85165ee
--- /dev/null
+++ b/package/quagga/0003-Fix-build-with-gcc-10.patch
@@ -0,0 +1,127 @@
+From 7a446434302d7b71211b81b3c6cd12a7b35223d1 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Sat, 6 Mar 2021 16:28:37 +0100
+Subject: [PATCH] Fix build with gcc 10
+
+Fix the following build failure with gcc 10 (which defaults to
+-fno-common):
+
+  CCLD     pimd
+/home/buildroot/autobuild/run/instance-3/output-1/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/10.2.0/../../../../arm-buildroot-linux-gnueabihf/bin/ld: pimd.o:(.bss+0x8): multiple definition of `qpim_static_route_list'; pim_main.o:(.bss+0x8): first defined here
+/home/buildroot/autobuild/run/instance-3/output-1/host/opt/ext-toolchain/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/10.2.0/../../../../arm-buildroot-linux-gnueabihf/bin/ld: pimd.o:(.bss+0x28): multiple definition of `qpim_mroute_del_last'; pim_main.o:(.bss+0x10): first defined here
+
+Fixes:
+ - http://autobuild.buildroot.org/results/fd5ee2b52a3cfaec268fafd3ffe4c30e51465c7e
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+[Upstream status: https://bugzilla.quagga.net/show_bug.cgi?id=1014]
+---
+ pimd/pim_version.h |  2 +-
+ pimd/pimd.c        |  1 +
+ pimd/pimd.h        | 66 +++++++++++++++++++++++-----------------------
+ 3 files changed, 35 insertions(+), 34 deletions(-)
+
+diff --git a/pimd/pim_version.h b/pimd/pim_version.h
+index ef9f370c..891d4314 100644
+--- a/pimd/pim_version.h
++++ b/pimd/pim_version.h
+@@ -25,6 +25,6 @@
+ 
+ #define PIMD_VERSION_STR "0.166"
+ 
+-const char * const PIMD_VERSION;
++extern const char * const PIMD_VERSION;
+ 
+ #endif /* PIM_VERSION_H */
+diff --git a/pimd/pimd.c b/pimd/pimd.c
+index 97fb2233..d7340cc0 100644
+--- a/pimd/pimd.c
++++ b/pimd/pimd.c
+@@ -50,6 +50,7 @@ int64_t                   qpim_mroute_socket_creation = 0; /* timestamp of creat
+ struct thread            *qpim_mroute_socket_reader = 0;
+ int                       qpim_mroute_oif_highest_vif_index = -1;
+ struct list              *qpim_channel_oil_list = 0;
++struct in_addr            qpim_all_pim_routers_addr;
+ int                       qpim_t_periodic = PIM_DEFAULT_T_PERIODIC; /* Period between Join/Prune Messages */
+ struct list              *qpim_upstream_list = 0;
+ struct zclient           *qpim_zclient_update = 0;
+diff --git a/pimd/pimd.h b/pimd/pimd.h
+index 9a7e6058..8b3496fd 100644
+--- a/pimd/pimd.h
++++ b/pimd/pimd.h
+@@ -68,39 +68,39 @@
+ #define PIM_MASK_PIM_J_P             (1 << 12)
+ #define PIM_MASK_STATIC              (1 << 13)
+ 
+-const char *const PIM_ALL_SYSTEMS;
+-const char *const PIM_ALL_ROUTERS;
+-const char *const PIM_ALL_PIM_ROUTERS;
+-const char *const PIM_ALL_IGMP_ROUTERS;
+-
+-struct thread_master     *master;
+-uint32_t                  qpim_debugs;
+-int                       qpim_mroute_socket_fd;
+-int64_t                   qpim_mroute_socket_creation; /* timestamp of creation */
+-struct thread            *qpim_mroute_socket_reader;
+-int                       qpim_mroute_oif_highest_vif_index;
+-struct list              *qpim_channel_oil_list; /* list of struct channel_oil */
+-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 */
+-struct zclient           *qpim_zclient_update;
+-struct zclient           *qpim_zclient_lookup;
+-struct pim_assert_metric  qpim_infinite_assert_metric;
+-long                      qpim_rpf_cache_refresh_delay_msec;
+-struct thread            *qpim_rpf_cache_refresher;
+-int64_t                   qpim_rpf_cache_refresh_requests;
+-int64_t                   qpim_rpf_cache_refresh_events;
+-int64_t                   qpim_rpf_cache_refresh_last;
+-struct in_addr            qpim_inaddr_any;
+-struct list              *qpim_ssmpingd_list; /* list of struct ssmpingd_sock */
+-struct in_addr            qpim_ssmpingd_group_addr;
+-int64_t                   qpim_scan_oil_events;
+-int64_t                   qpim_scan_oil_last;
+-int64_t                   qpim_mroute_add_events;
+-int64_t                   qpim_mroute_add_last;
+-int64_t                   qpim_mroute_del_events;
+-int64_t                   qpim_mroute_del_last;
+-struct list              *qpim_static_route_list; /* list of routes added statically */
++extern const char *const PIM_ALL_SYSTEMS;
++extern const char *const PIM_ALL_ROUTERS;
++extern const char *const PIM_ALL_PIM_ROUTERS;
++extern const char *const PIM_ALL_IGMP_ROUTERS;
++
++extern struct thread_master     *master;
++extern uint32_t                  qpim_debugs;
++extern int                       qpim_mroute_socket_fd;
++extern int64_t                   qpim_mroute_socket_creation; /* timestamp of creation */
++extern struct thread            *qpim_mroute_socket_reader;
++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;
++extern int                       qpim_t_periodic; /* Period between Join/Prune Messages */
++extern struct list              *qpim_upstream_list; /* list of struct pim_upstream */
++extern struct zclient           *qpim_zclient_update;
++extern struct zclient           *qpim_zclient_lookup;
++extern struct pim_assert_metric  qpim_infinite_assert_metric;
++extern long                      qpim_rpf_cache_refresh_delay_msec;
++extern struct thread            *qpim_rpf_cache_refresher;
++extern int64_t                   qpim_rpf_cache_refresh_requests;
++extern int64_t                   qpim_rpf_cache_refresh_events;
++extern int64_t                   qpim_rpf_cache_refresh_last;
++extern struct in_addr            qpim_inaddr_any;
++extern struct list              *qpim_ssmpingd_list; /* list of struct ssmpingd_sock */
++extern struct in_addr            qpim_ssmpingd_group_addr;
++extern int64_t                   qpim_scan_oil_events;
++extern int64_t                   qpim_scan_oil_last;
++extern int64_t                   qpim_mroute_add_events;
++extern int64_t                   qpim_mroute_add_last;
++extern int64_t                   qpim_mroute_del_events;
++extern int64_t                   qpim_mroute_del_last;
++extern struct list              *qpim_static_route_list; /* list of routes added statically */
+ 
+ #define PIM_JP_HOLDTIME (qpim_t_periodic * 7 / 2)
+ 
+-- 
+2.30.0
+
-- 
2.30.0

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10
  2021-03-06 15:56 [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10 Fabrice Fontaine
@ 2021-03-06 19:37 ` Peter Korsgaard
  2021-03-16 22:20 ` Peter Korsgaard
  1 sibling, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2021-03-06 19:37 UTC (permalink / raw)
  To: buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > Fixes:
 >  - http://autobuild.buildroot.org/results/fd5ee2b52a3cfaec268fafd3ffe4c30e51465c7e

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Committed, thanks.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10
  2021-03-06 15:56 [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10 Fabrice Fontaine
  2021-03-06 19:37 ` Peter Korsgaard
@ 2021-03-16 22:20 ` Peter Korsgaard
  1 sibling, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2021-03-16 22:20 UTC (permalink / raw)
  To: buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > Fixes:
 >  - http://autobuild.buildroot.org/results/fd5ee2b52a3cfaec268fafd3ffe4c30e51465c7e

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Committed to 2020.11.x, thanks.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10
  2020-09-21 21:30 Fabrice Fontaine
  2020-09-22 19:28 ` Thomas Petazzoni
@ 2020-09-29 18:54 ` Peter Korsgaard
  1 sibling, 0 replies; 6+ messages in thread
From: Peter Korsgaard @ 2020-09-29 18:54 UTC (permalink / raw)
  To: buildroot

>>>>> "Fabrice" == Fabrice Fontaine <fontaine.fabrice@gmail.com> writes:

 > Fixes:
 >  - http://autobuild.buildroot.org/results/82b15cff3f7b943eb93d8270790f1b8561d31d6a

 > Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

Committed to 2020.08.x, thanks.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10
  2020-09-21 21:30 Fabrice Fontaine
@ 2020-09-22 19:28 ` Thomas Petazzoni
  2020-09-29 18:54 ` Peter Korsgaard
  1 sibling, 0 replies; 6+ messages in thread
From: Thomas Petazzoni @ 2020-09-22 19:28 UTC (permalink / raw)
  To: buildroot

On Mon, 21 Sep 2020 23:30:30 +0200
Fabrice Fontaine <fontaine.fabrice@gmail.com> wrote:

> + struct ethaddr {
> +     u_char octet[ETHER_ADDR_LEN];
> +-} __packed;

I think the intentation was to use the packed gcc attribute, and
perhaps in the past there was a __packed defined to
__attribute__((packed)) or something like that. When this define went
away, __packed became the name of a variable :)

That being said, I'm not sure the packed attribute makes anything
special on a structure that has a single member, so I've applied. We'll
also see what upstream says.

Thanks,

Thomas
-- 
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10
@ 2020-09-21 21:30 Fabrice Fontaine
  2020-09-22 19:28 ` Thomas Petazzoni
  2020-09-29 18:54 ` Peter Korsgaard
  0 siblings, 2 replies; 6+ messages in thread
From: Fabrice Fontaine @ 2020-09-21 21:30 UTC (permalink / raw)
  To: buildroot

Fixes:
 - http://autobuild.buildroot.org/results/82b15cff3f7b943eb93d8270790f1b8561d31d6a

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 ...2-lib-prefix.h-fix-build-with-gcc-10.patch | 36 +++++++++++++++++++
 1 file changed, 36 insertions(+)
 create mode 100644 package/quagga/0002-lib-prefix.h-fix-build-with-gcc-10.patch

diff --git a/package/quagga/0002-lib-prefix.h-fix-build-with-gcc-10.patch b/package/quagga/0002-lib-prefix.h-fix-build-with-gcc-10.patch
new file mode 100644
index 0000000000..f2fc9cc647
--- /dev/null
+++ b/package/quagga/0002-lib-prefix.h-fix-build-with-gcc-10.patch
@@ -0,0 +1,36 @@
+From 01bcd0f7411f86eea44247bf91b48882cae35519 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Mon, 21 Sep 2020 23:12:25 +0200
+Subject: [PATCH] lib/prefix.h: fix build with gcc 10
+
+Remove __packed to fix the following build failure with gcc 10 (which
+defaults to -fno-common):
+
+  CCLD     libzebra.la
+/tmp/instance-1/output-1/host/lib/gcc/arm-buildroot-linux-gnueabihf/10.2.0/../../../../arm-buildroot-linux-gnueabihf/bin/ld: .libs/sockunion.o:(.bss+0x0): multiple definition of `__packed'; .libs/vty.o:(.bss+0x6c): first defined here
+
+Fixes:
+ - http://autobuild.buildroot.org/results/82b15cff3f7b943eb93d8270790f1b8561d31d6a
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+[Upstream status: https://bugzilla.quagga.net/show_bug.cgi?id=1014]
+---
+ lib/prefix.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/lib/prefix.h b/lib/prefix.h
+index 2cf0b20b..a5306eee 100644
+--- a/lib/prefix.h
++++ b/lib/prefix.h
+@@ -44,7 +44,7 @@
+  */
+ struct ethaddr {
+     u_char octet[ETHER_ADDR_LEN];
+-} __packed;
++};
+ 
+ 
+ /*
+-- 
+2.28.0
+
-- 
2.28.0

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-03-16 22:20 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-06 15:56 [Buildroot] [PATCH 1/1] package/quagga: fix build with gcc 10 Fabrice Fontaine
2021-03-06 19:37 ` Peter Korsgaard
2021-03-16 22:20 ` Peter Korsgaard
  -- strict thread matches above, loose matches on Subject: below --
2020-09-21 21:30 Fabrice Fontaine
2020-09-22 19:28 ` Thomas Petazzoni
2020-09-29 18:54 ` Peter Korsgaard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.