Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.4:ARM
packETH
e72195b573.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File e72195b573.patch of Package packETH
From e72195b573a17e68632e5461db72dc2a4d142c94 Mon Sep 17 00:00:00 2001 From: Jeroen Roovers <jer@gentoo.org> Date: Mon, 3 Feb 2020 20:48:26 +0100 Subject: [PATCH] Fix GCC-10 / CFLAGS=-fno-common GCC 10 will enable -fno-common by default[0], which causes the linker to fail like this [1], even for older GCC versions for which it is explicitly enabled: ``` ld: src/function_send.o:(.bss+0x0): multiple definition of `iftext'; src/callbacks.o:(.bss+0x0): first defined here ``` Fix[2] this by declaring iftext as extern in the header and by defining it just once. [0] https://gcc.gnu.org/gcc-10/porting_to.html#common [1] https://bugs.gentoo.org/708048 [2] Note that src/function.h uses CRLF line endings. --- src/callbacks.c | 1 - src/function.c | 2 +- src/function.h | 2 ++ src/function_send.c | 1 - 4 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/callbacks.c b/src/callbacks.c index ef02fb1..5efde80 100644 --- a/src/callbacks.c +++ b/src/callbacks.c @@ -65,7 +65,6 @@ extern int number; extern int stop_flag; extern long desired_bw; gint row_number;/* this is because i cant get the selected row number*/ -gchar iftext[20]; gchar address_filename[100] = "addresslist"; static GtkWidget *entry_field; static GtkWidget *entry_field_ip; diff --git a/src/function.c b/src/function.c index 1d7dfe2..96e4d8f 100644 --- a/src/function.c +++ b/src/function.c @@ -66,7 +66,7 @@ int ipv4_start = 0; int ipv6_start = 0; int eth_start = 0; gboolean stop_flag = 0; -extern char iftext[20]; +char iftext[20]; static unsigned long crc32_table[256]; int crc32_table_init = 0; int ip_proto_used = 0; // 0 - none, 4 - ipv4, 6- IPv6, 806 - ARP diff --git a/src/function.h b/src/function.h index 304caf5..461ce01 100644 --- a/src/function.h +++ b/src/function.h @@ -22,6 +22,8 @@ #include <gtk/gtk.h> +extern char iftext[20]; + signed int char2x(char *p); char c4(int value); guint32 get_checksum32(int start, int stop); diff --git a/src/function_send.c b/src/function_send.c index ca49639..5d3f1f6 100644 --- a/src/function_send.c +++ b/src/function_send.c @@ -55,7 +55,6 @@ extern long li_last_packets_sent; extern long li_packets_sent_lastsec; extern long sentstream[10]; extern long sendtime; -char iftext[20]; struct params { long long del;
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor