| Summary: | BR2_PACKAGE_LINUX_TOOLS_GPIO fails for MIPS with "gpio-hammer.o: ABI is incompatible with that of the selected emulation" | ||
|---|---|---|---|
| Product: | buildroot | Reporter: | Ciro Santilli <ciro.santilli> |
| Component: | Other | Assignee: | Yann E. MORIN <yann.morin.1998> |
| Status: | RESOLVED MOVED | ||
| Severity: | normal | CC: | buildroot, yann.morin.1998 |
| Priority: | P5 | ||
| Version: | 2017.05.1 | ||
| Target Milestone: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Host: | Target: | ||
| Build: | |||
|
Description
Ciro Santilli
2017-08-30 05:38:17 UTC
Could you try to adapt https://patchwork.ozlabs.org/patch/729154/ to the gpio linux-tools package, and see if it works for you ? Given the following:
CC gpio-utils.o
LD gpio-event-mon-in.o
gpio-utils.o: file not recognized: File truncated
/data/git/buildroot/output/build/linux-4.11.3/tools/build/Make
file.build:149: recipe for target 'gpio-event-mon-in.o' failed
it looks like it might be a parallel build issue, where gpio-event-mon-in.o
needs gpio-utils.o, but it is not yet built.
Well, I'm pretty sure its the issue fixed for perf by https://patchwork.ozlabs.org/patch/729154/. When ld is used directly for linking, it needs to be explicitly told the endianness. Thomas, I can very easily reproduce the truncated file issue, and it
indeed always happen with parallel builds, but not always.
And I can even reproduce it in a native build, on Linus' linux master:
$ make -j1000
mkdir -p include/linux 2>&1 || true
ln -sf /home/ymorin/dev/linux/linux/tools/gpio/../../include/uapi/linux/gpio.h include/linux/gpio.h
make -f /home/ymorin/dev/linux/linux/tools/build/Makefile.build dir=. obj=lsgpio
make -f /home/ymorin/dev/linux/linux/tools/build/Makefile.build dir=. obj=gpio-hammer
make -f /home/ymorin/dev/linux/linux/tools/build/Makefile.build dir=. obj=gpio-event-mon
make[1]: Entering directory '/home/ymorin/dev/linux/linux/tools/gpio'
make[1]: Entering directory '/home/ymorin/dev/linux/linux/tools/gpio'
make[1]: Entering directory '/home/ymorin/dev/linux/linux/tools/gpio'
CC gpio-event-mon.o
CC lsgpio.o
CC gpio-hammer.o
CC gpio-utils.o
CC gpio-utils.o
CC gpio-utils.o
gpio-event-mon.c: In function ‘monitor_device’:
gpio-event-mon.c:100:19: warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘__u64 {aka long long unsigned int}’ [-Wformat=]
fprintf(stdout, "GPIO EVENT %" PRIu64 ": ", event.timestamp);
^~~~~~~~~~~~~~
LD gpio-event-mon-in.o
gpio-utils.o: file not recognized: File truncated
/home/ymorin/dev/linux/linux/tools/build/Makefile.build:143: recipe for target 'gpio-event-mon-in.o' failed
make[1]: *** [gpio-event-mon-in.o] Error 1
make[1]: Leaving directory '/home/ymorin/dev/linux/linux/tools/gpio'
Makefile:58: recipe for target 'gpio-event-mon-in.o' failed
make: *** [gpio-event-mon-in.o] Error 2
make: *** Waiting for unfinished jobs....
LD lsgpio-in.o
make[1]: Leaving directory '/home/ymorin/dev/linux/linux/tools/gpio'
LD gpio-hammer-in.o
make[1]: Leaving directory '/home/ymorin/dev/linux/linux/tools/gpio'
Yet, you are right that there is also (and more importantly) a
problem with using ld instead of gcc.
So, there are two issues in one. ;-)
THank you for your report.
The issue tracker for the Buildroot project has been moved to
the Gitlab.com issue tracker:
https://gitlab.com/buildroot.org/buildroot/-/issues
We are taking this opportunity to close old issues in this old
tracker. If you believe your issue is still relevant, please
open one in the new issue tracker.
Thank you!
|