[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#53424: tftp-hpa: Fails to build (multiple definition of 'toplevel' w
From: |
Ivan Vilata i Balaguer |
Subject: |
bug#53424: tftp-hpa: Fails to build (multiple definition of 'toplevel' when linking) |
Date: |
Fri, 21 Jan 2022 22:06:08 +0100 |
Hi! When trying to upgrade package `tftp-hpa 5.2` from Guix commit `404f6953`
to that of commit `4a943cfd`, the build fails showing these warnings and
error:
```
starting phase `build'
[…]
gcc -g -O2 -W -Wall -Wpointer-arith -Wbad-function-cast -Wstrict-prototypes
-Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline
-Wwrite-strings -Wundef -Wshadow -Wsign-compare -pipe -fno-strict-aliasing
-I/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2 -c main.c
tftp.c: In function ‘tftp_sendfile’:
tftp.c:88:5: warning: implicit declaration of function ‘bsd_signal’; did you
mean ‘ssignal’? [-Wimplicit-function-declaration]
88 | bsd_signal(SIGALRM, timer);
| ^~~~~~~~~~
| ssignal
tftp.c:88:5: warning: nested extern declaration of ‘bsd_signal’
[-Wnested-externs]
main.c: In function ‘main’:
main.c:308:5: warning: implicit declaration of function ‘bsd_signal’; did you
mean ‘ssignal’? [-Wimplicit-function-declaration]
308 | bsd_signal(SIGINT, intr);
| ^~~~~~~~~~
| ssignal
main.c:308:5: warning: nested extern declaration of ‘bsd_signal’
[-Wnested-externs]
gcc -g -O2 -W -Wall -Wpointer-arith -Wbad-function-cast -Wstrict-prototypes
-Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline
-Wwrite-strings -Wundef -Wshadow -Wsign-compare -pipe -fno-strict-aliasing
-I/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2 -c misc.c
sed -e 's/@@VERSION@@/5.2/g' < tftp.1.in > tftp.1
gcc -g -O2 -W -Wall -Wpointer-arith -Wbad-function-cast -Wstrict-prototypes
-Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline
-Wwrite-strings -Wundef -Wshadow -Wsign-compare -pipe -fno-strict-aliasing
-I/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2 -c remap.c
sed -e 's/@@VERSION@@/5.2/g' < tftpd.8.in > tftpd.8
tftpd.c: In function ‘tftp_recvfile’:
tftpd.c:1647:69: warning: argument ‘oap’ might be clobbered by ‘longjmp’ or
‘vfork’ [-Wclobbered]
1647 | static void tftp_recvfile(const struct formats *pf, struct tftphdr
*oap, int oacklen)
| ~~~~~~~~~~~~~~~~^~~
main.c:191:20: warning: inlining failed in call to ‘usage’: call is unlikely
and code size would grow [-Winline]
191 | static inline void usage(int errcode)
| ^~~~~
main.c:244:25: note: called from here
244 | usage(EX_USAGE);
| ^~~~~~~~~~~~~~~
main.c:191:20: warning: inlining failed in call to ‘usage’: call is unlikely
and code size would grow [-Winline]
191 | static inline void usage(int errcode)
| ^~~~~
main.c:266:25: note: called from here
266 | usage(EX_USAGE);
| ^~~~~~~~~~~~~~~
main.c:191:20: warning: inlining failed in call to ‘usage’: call is unlikely
and code size would grow [-Winline]
191 | static inline void usage(int errcode)
| ^~~~~
main.c:279:21: note: called from here
279 | usage(*optx == 'h' ? 0 : EX_USAGE);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
main.c:191:20: warning: inlining failed in call to ‘usage’: call is unlikely
and code size would grow [-Winline]
191 | static inline void usage(int errcode)
| ^~~~~
main.c:284:17: note: called from here
284 | usage(EX_USAGE);
| ^~~~~~~~~~~~~~~
gcc tftp.o main.o ../common/libcommon.a
/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2/lib/libxtra.a -o tftp
ld: main.o:/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2/tftp/main.c:98:
multiple definition of `toplevel';
tftp.o:/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2/tftp/tftp.c:51: first
defined here
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile:12: tftp] Error 1
make[1]: Leaving directory
'/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2/tftp'
make: *** [Makefile:7: tftp.build] Error 2
make: *** Waiting for unfinished jobs....
gcc tftpd.o recvfrom.o misc.o remap.o ../common/libcommon.a
/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2/lib/libxtra.a -o tftpd
make[1]: Leaving directory
'/tmp/guix-build-tftp-hpa-5.2.drv-0/tftp-hpa-5.2/tftpd'
error: in phase 'build': uncaught exception:
%exception #<&invoke-error program: "make" arguments: ("-j" "4") exit-status: 2
term-signal: #f stop-signal: #f>
phase `build' failed after 0.8 seconds
command "make" "-j" "4" failed with status 2
```
Maybe something changed with the compiler which causes `toplevel` to be
defined twice, not sure whether the warnings are relevant. Attaching whole
`/var/log/guix/drvs/n7/mi9pqbpgad3gnz97s02zd056qnzcfg-tftp-hpa-5.2.drv.bz2`.
Thanks a lot!
--
Ivan Vilata i Balaguer -- https://elvil.net/
mi9pqbpgad3gnz97s02zd056qnzcfg-tftp-hpa-5.2.drv.bz2
Description: Binary data
signature.asc
Description: PGP signature
- bug#53424: tftp-hpa: Fails to build (multiple definition of 'toplevel' when linking),
Ivan Vilata i Balaguer <=