Without the corresponding include file, these macros get always defined
locally and thus, shadows the ones from the system. This change ensures,
if the macros are found already defined in the system, then they are used.
Signed-off-by: Juergen Borleis <jbe@pengutronix.de>
It works on dev coredump data generated by the mcp251xfd driver in
case of failures, as well as on regmap based register dumps.
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
With glibc versions before 2.17, we get following build error:
canfdtest.o: In function `millisleep':
canfdtest.c:(.text+0x212): undefined reference to `clock_nanosleep'
collect2: error: ld returned 1 exit status
make[1]: *** [canfdtest] Error 1
make[1]: *** Waiting for unfinished jobs....
glibc versions before 2.17 needs to link with -lrt for
clock_nanosleep(). This patch adds support to detect if linking with
librt is required.
This build issue is detected by Buildroot autobuilder:
http://autobuild.buildroot.net/results/0e5/0e5242376ff6aa82e89ed1172350e05009d48156/build-end.log
Signed-off-by: Rahul Bedarkar <rahul.bedarkar@imgtec.com>