main: Fix redeclaration linking error

Fix linking error as the "store" global variable gets redeclared in
each C file that includes the header. Move the actual declaration to
main.c.

Fixes:
 /usr/bin/ld: ./.libs/libfprintd.a(device.o):/builds/libfprint/fprintd/src/storage.h:51: multiple definition of `store'; main.o:/builds/libfprint/fprintd/src/storage.h:51: first defined here
This commit is contained in:
Bastien Nocera
2020-01-23 17:37:33 +01:00
parent b99afd19f0
commit 0c6bab8640
2 changed files with 3 additions and 1 deletions

View File

@ -46,4 +46,4 @@ struct storage {
typedef struct storage fp_storage;
/* The currently setup store */
fp_storage store;
extern fp_storage store;