From: Timothy Redaelli Date: Wed, 5 Feb 2020 12:50:42 +0000 (+0100) Subject: test: fix build with gcc 10 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=53ba646a0a63c053974548cf03a7537538042b85;p=dpdk.git test: fix build with gcc 10 GCC 10 defaults to -fno-common, this means a linker error will now be reported if the same global variable is defined in more than one compilation unit. Fixes: 08e0c7581468 ("test/fib: add performance autotests") Cc: stable@dpdk.org Signed-off-by: Timothy Redaelli Acked-by: Vladimir Medvedkin --- diff --git a/app/test/test_fib_perf.c b/app/test/test_fib_perf.c index 573087c3c0..dd2e54db8b 100644 --- a/app/test/test_fib_perf.c +++ b/app/test/test_fib_perf.c @@ -35,7 +35,7 @@ struct route_rule { uint8_t depth; }; -struct route_rule large_route_table[MAX_RULE_NUM]; +static struct route_rule large_route_table[MAX_RULE_NUM]; static uint32_t num_route_entries; #define NUM_ROUTE_ENTRIES num_route_entries diff --git a/app/test/test_lpm_perf.c b/app/test/test_lpm_perf.c index a2578fe90e..489719c40b 100644 --- a/app/test/test_lpm_perf.c +++ b/app/test/test_lpm_perf.c @@ -34,7 +34,7 @@ struct route_rule { uint8_t depth; }; -struct route_rule large_route_table[MAX_RULE_NUM]; +static struct route_rule large_route_table[MAX_RULE_NUM]; static uint32_t num_route_entries; #define NUM_ROUTE_ENTRIES num_route_entries