-
Notifications
You must be signed in to change notification settings - Fork 3
Open
Description
Hi,
I've been trying to compile snppit under linux (gcc 12.2.0) by running Compile_snppit.sh.
This failed with these errors:
src/pbt_C_fb.c: In function ‘ForwardStep’:
src/pbt_C_fb.c:250:48: warning: argument 1 range [18446744071562067968, 18446744073709551615] exceeds maximum object size 9223372036854775807 [-Walloc-size-larger-than=]
250 | ret->FB[t] = (struct fb_cell *)calloc(ret->Kt[t], sizeof(struct fb_cell));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from src/pbt_C_fb.c:4:
/usr/include/stdlib.h:556:14: note: in a call to allocation function ‘calloc’ declared here
556 | extern void *calloc (size_t __nmemb, size_t __size)
| ^~~~~~
/usr/bin/ld: /tmp/ccUQCvT1.o:(.bss+0x0): multiple definition of `gHasSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x0): first defined here
/usr/bin/ld: /tmp/ccUQCvT1.o:(.bss+0x20): multiple definition of `gSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x20): first defined here
/usr/bin/ld: /tmp/ccJt2mTE.o:(.bss+0x0): multiple definition of `gHasSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x0): first defined here
/usr/bin/ld: /tmp/ccJt2mTE.o:(.bss+0x20): multiple definition of `gSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x20): first defined here
/usr/bin/ld: /tmp/ccNp1FIn.o:(.bss+0x0): multiple definition of `gHasSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x0): first defined here
/usr/bin/ld: /tmp/ccNp1FIn.o:(.bss+0x20): multiple definition of `gSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x20): first defined here
/usr/bin/ld: /tmp/ccbyE1VZ.o:(.bss+0x0): multiple definition of `gHasSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x0): first defined here
/usr/bin/ld: /tmp/ccbyE1VZ.o:(.bss+0x20): multiple definition of `gSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x20): first defined here
/usr/bin/ld: /tmp/ccC37iJn.o:(.bss+0x64): multiple definition of `gHasSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x0): first defined here
/usr/bin/ld: /tmp/ccC37iJn.o:(.bss+0x80): multiple definition of `gSnpSumPedPath'; /tmp/ccNqPloF.o:(.bss+0x20): first defined here
collect2: error: ld returned 1 exit status
My fix was to add the flag "-fcommon" to the gcc command, and it now compiles successfully. I've ran the tests, and they almost all pass.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels