Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error compiling, duplicate member on header, endian.h

Tags:

c++

c

linux

I am trying work with FingerPrinter SDK, it shows an example to runs it on linux, i run it on linux cuz its more customizable than windows, well i followed all instructions included to build and compile, but i get this error. These SDK uses libusb library and some usb rules, both are perfectly installed and allowed. Hope get some help.

this is the complete pack where you can find all codes and readmes.

Dowload code!

In file included from /usr/include/x86_64-linux-gnu/bits/waitstatus.h:64:0,
             from /usr/include/stdlib.h:42,
             from /usr/include/usb.h:15,
             from ../lnx/usbl.c:10:
../endian.h:44:10: error: #error Header <endian.h> should define macro __BYTE_ORDER.
     #error Header <endian.h> should define macro __BYTE_ORDER.
      ^
In file included from /usr/include/stdlib.h:42:0,
             from /usr/include/usb.h:15,
             from ../lnx/usbl.c:10:
/usr/include/x86_64-linux-gnu/bits/waitstatus.h:79:15: error: duplicate member ‘__w_retcode’


 unsigned int __w_retcode:8;
           ^
/usr/include/x86_64-linux-gnu/bits/waitstatus.h:80:15: error: duplicate member ‘__w_coredump’


 unsigned int __w_coredump:1;
           ^
/usr/include/x86_64-linux-gnu/bits/waitstatus.h:81:15: error: duplicate member ‘__w_termsig’


 unsigned int __w_termsig:7;
           ^
/usr/include/x86_64-linux-gnu/bits/waitstatus.h:93:15: error: duplicate member ‘__w_stopsig’


 unsigned int __w_stopsig:8; /* Stopping signal.  */
           ^
/usr/include/x86_64-linux-gnu/bits/waitstatus.h:94:15: error: duplicate member ‘__w_stopval’


 unsigned int __w_stopval:8; /* W_STOPPED if stopped.  */
               ^
like image 673
Azael Ortega Valdovinos Avatar asked Apr 12 '26 18:04

Azael Ortega Valdovinos


1 Answers

The stdlib.h is including the endian.h from your (or the SDK's) source code instead of the one from the standard include files, thus __BYTE_ORDER is never defined. Find the conflicting endian.h file and rename it. Or remove -I compilation flag from your tool chain.

https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=598600

Welcome to tool chain configuration hell.

like image 146
Shelby Moore III Avatar answered Apr 14 '26 11:04

Shelby Moore III



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!