diff --git a/core/sched.c b/core/sched.c index 50f2527629..a06c9cf41f 100644 --- a/core/sched.c +++ b/core/sched.c @@ -38,6 +38,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + volatile int sched_num_threads = 0; volatile unsigned int sched_context_switch_request; diff --git a/cpu/atmega_common/avr-libc-extra/inttypes.h b/cpu/atmega_common/avr-libc-extra/inttypes.h index 66af2f2ced..751fd025f9 100644 --- a/cpu/atmega_common/avr-libc-extra/inttypes.h +++ b/cpu/atmega_common/avr-libc-extra/inttypes.h @@ -24,10 +24,10 @@ extern "C" { #endif -#define PRIo64 "oll" /**< Format string for octal 64-bit number */ -#define PRIx64 "xll" /**< Format string for hexadecimal 64-bit number */ -#define PRIu64 "ull" /**< Format string for unsigned 64-bit number */ -#define PRId64 "dll" /**< Format string for signed 64-bit number */ +#define PRIo64 "llo" /**< Format string for octal 64-bit number */ +#define PRIx64 "llx" /**< Format string for hexadecimal 64-bit number */ +#define PRIu64 "llu" /**< Format string for unsigned 64-bit number */ +#define PRId64 "lld" /**< Format string for signed 64-bit number */ #ifdef __cplusplus } diff --git a/examples/ng_networking/udp.c b/examples/ng_networking/udp.c index 13862f998b..22a5335337 100644 --- a/examples/ng_networking/udp.c +++ b/examples/ng_networking/udp.c @@ -19,6 +19,7 @@ */ #include +#include #include "kernel.h" #include "net/ng_netbase.h" diff --git a/examples/rpl_udp/rpl.c b/examples/rpl_udp/rpl.c index 0973238995..64b7a96c83 100644 --- a/examples/rpl_udp/rpl.c +++ b/examples/rpl_udp/rpl.c @@ -20,6 +20,8 @@ #include #include +#include + #include "vtimer.h" #include "thread.h" #include "net_if.h" diff --git a/sys/net/application_layer/ng_zep/ng_zep.c b/sys/net/application_layer/ng_zep/ng_zep.c index f313928912..4b3a887440 100644 --- a/sys/net/application_layer/ng_zep/ng_zep.c +++ b/sys/net/application_layer/ng_zep/ng_zep.c @@ -37,6 +37,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + #define _EVENT_RX_STARTED (1) #define _EVENT_RX_COMPLETE (2) #define _RX_BUF_SIZE (16U * sizeof(ng_pktsnip_t *)) diff --git a/sys/net/ccn_lite/ccnl-ext-appserver.c b/sys/net/ccn_lite/ccnl-ext-appserver.c index a8055c0179..d5418ba7f5 100644 --- a/sys/net/ccn_lite/ccnl-ext-appserver.c +++ b/sys/net/ccn_lite/ccnl-ext-appserver.c @@ -20,6 +20,8 @@ #if RIOT_CCN_APPSERVER +#include + #include "msg.h" #include "thread.h" #include "ccnl-riot-compat.h" diff --git a/sys/net/crosslayer/ng_netif/hdr/ng_netif_hdr_print.c b/sys/net/crosslayer/ng_netif/hdr/ng_netif_hdr_print.c index 9f1386269b..c1caccc897 100644 --- a/sys/net/crosslayer/ng_netif/hdr/ng_netif_hdr_print.c +++ b/sys/net/crosslayer/ng_netif/hdr/ng_netif_hdr_print.c @@ -13,6 +13,7 @@ */ #include +#include #include "net/ng_netif.h" #include "net/ng_netif/hdr.h" diff --git a/sys/net/link_layer/net_if/net_if.c b/sys/net/link_layer/net_if/net_if.c index b2b9990e9b..e26e3cc27c 100644 --- a/sys/net/link_layer/net_if/net_if.c +++ b/sys/net/link_layer/net_if/net_if.c @@ -26,6 +26,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + net_if_t interfaces[NET_IF_MAX]; #if ENABLE_DEBUG diff --git a/sys/net/link_layer/ng_nomac/ng_nomac.c b/sys/net/link_layer/ng_nomac/ng_nomac.c index 6f753c7de2..90ea92048d 100644 --- a/sys/net/link_layer/ng_nomac/ng_nomac.c +++ b/sys/net/link_layer/ng_nomac/ng_nomac.c @@ -27,6 +27,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + /** * @brief Function called by the device driver on device events * diff --git a/sys/net/network_layer/fib/fib.c b/sys/net/network_layer/fib/fib.c index 95c5541347..7a088111cc 100644 --- a/sys/net/network_layer/fib/fib.c +++ b/sys/net/network_layer/fib/fib.c @@ -18,6 +18,7 @@ #include #include #include +#include #include #include "thread.h" #include "mutex.h" diff --git a/sys/net/network_layer/ng_icmpv6/echo/ng_icmpv6_echo.c b/sys/net/network_layer/ng_icmpv6/echo/ng_icmpv6_echo.c index 746dc57e47..36e18cd8c0 100644 --- a/sys/net/network_layer/ng_icmpv6/echo/ng_icmpv6_echo.c +++ b/sys/net/network_layer/ng_icmpv6/echo/ng_icmpv6_echo.c @@ -22,6 +22,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + ng_pktsnip_t *ng_icmpv6_echo_build(uint8_t type, uint16_t id, uint16_t seq, uint8_t *data, size_t data_len) { diff --git a/sys/net/network_layer/ng_ipv6/hdr/ng_ipv6_hdr_print.c b/sys/net/network_layer/ng_ipv6/hdr/ng_ipv6_hdr_print.c index c8140e8c7c..b74b486bc7 100644 --- a/sys/net/network_layer/ng_ipv6/hdr/ng_ipv6_hdr_print.c +++ b/sys/net/network_layer/ng_ipv6/hdr/ng_ipv6_hdr_print.c @@ -13,6 +13,7 @@ */ #include +#include #include "net/ng_ipv6/hdr.h" diff --git a/sys/net/network_layer/ng_ipv6/nc/ng_ipv6_nc.c b/sys/net/network_layer/ng_ipv6/nc/ng_ipv6_nc.c index c76ec8d8ea..98a125bf15 100644 --- a/sys/net/network_layer/ng_ipv6/nc/ng_ipv6_nc.c +++ b/sys/net/network_layer/ng_ipv6/nc/ng_ipv6_nc.c @@ -29,6 +29,9 @@ #include "debug.h" #if ENABLE_DEBUG +/* For PRIu8 etc. */ +#include + static char addr_str[NG_IPV6_ADDR_MAX_STR_LEN]; #endif diff --git a/sys/net/network_layer/ng_ipv6/netif/ng_ipv6_netif.c b/sys/net/network_layer/ng_ipv6/netif/ng_ipv6_netif.c index 6a4d57df1c..bbdca7631e 100644 --- a/sys/net/network_layer/ng_ipv6/netif/ng_ipv6_netif.c +++ b/sys/net/network_layer/ng_ipv6/netif/ng_ipv6_netif.c @@ -32,6 +32,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + static ng_ipv6_netif_t ipv6_ifs[NG_NETIF_NUMOF]; #if ENABLE_DEBUG diff --git a/sys/net/network_layer/ng_ndp/ng_ndp.c b/sys/net/network_layer/ng_ndp/ng_ndp.c index 6372db23c3..1ee1599def 100644 --- a/sys/net/network_layer/ng_ndp/ng_ndp.c +++ b/sys/net/network_layer/ng_ndp/ng_ndp.c @@ -34,7 +34,10 @@ #define ENABLE_DEBUG (0) #include "debug.h" -#if (ENABLE_DEBUG) +#if ENABLE_DEBUG +/* For PRIu8 etc. */ +#include + static char addr_str[NG_IPV6_ADDR_MAX_STR_LEN]; #endif diff --git a/sys/net/network_layer/ng_sixlowpan/frag/ng_sixlowpan_frag.c b/sys/net/network_layer/ng_sixlowpan/frag/ng_sixlowpan_frag.c index b2a8dfc87a..e9bb35ecd8 100644 --- a/sys/net/network_layer/ng_sixlowpan/frag/ng_sixlowpan_frag.c +++ b/sys/net/network_layer/ng_sixlowpan/frag/ng_sixlowpan_frag.c @@ -25,6 +25,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + static uint16_t _tag; static inline uint16_t _floor8(uint16_t length) diff --git a/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan.c b/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan.c index d6c7bb3874..9dd7051aff 100644 --- a/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan.c +++ b/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan.c @@ -25,6 +25,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + static kernel_pid_t _pid = KERNEL_PID_UNDEF; #if ENABLE_DEBUG diff --git a/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan_print.c b/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan_print.c index 673e48d37e..b1c28c3106 100644 --- a/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan_print.c +++ b/sys/net/network_layer/ng_sixlowpan/ng_sixlowpan_print.c @@ -13,6 +13,7 @@ */ #include +#include #include "od.h" #include "net/ng_ipv6/hdr.h" diff --git a/sys/net/routing/aodvv2/reader.c b/sys/net/routing/aodvv2/reader.c index bb8fedba3f..fea8a77b87 100644 --- a/sys/net/routing/aodvv2/reader.c +++ b/sys/net/routing/aodvv2/reader.c @@ -27,6 +27,11 @@ #define ENABLE_DEBUG (0) #include "debug.h" +#if ENABLE_DEBUG +/* For PRIu16 etc. */ +#include +#endif + #define VERBOSE_DEBUG (0) #if VERBOSE_DEBUG #define VDEBUG(...) AODV_DEBUG(__VA_ARGS__) diff --git a/sys/net/routing/aodvv2/routingtable.c b/sys/net/routing/aodvv2/routingtable.c index d2cd845176..87c0a954a6 100644 --- a/sys/net/routing/aodvv2/routingtable.c +++ b/sys/net/routing/aodvv2/routingtable.c @@ -17,6 +17,9 @@ * @author Lotte Steenbrink */ +#include +#include + #include "routingtable.h" #include "aodv_debug.h" diff --git a/sys/net/transport_layer/ng_udp/ng_udp_hdr_print.c b/sys/net/transport_layer/ng_udp/ng_udp_hdr_print.c index a43c0004dc..1701038b08 100644 --- a/sys/net/transport_layer/ng_udp/ng_udp_hdr_print.c +++ b/sys/net/transport_layer/ng_udp/ng_udp_hdr_print.c @@ -19,6 +19,7 @@ */ #include +#include #include "net/ng_udp.h" diff --git a/sys/shell/commands/sc_icmpv6_echo.c b/sys/shell/commands/sc_icmpv6_echo.c index eb3f55fabb..21744bd83d 100644 --- a/sys/shell/commands/sc_icmpv6_echo.c +++ b/sys/shell/commands/sc_icmpv6_echo.c @@ -17,6 +17,7 @@ #include #include +#include #ifdef MODULE_NG_ICMPV6 diff --git a/sys/shell/commands/sc_l2_ping.c b/sys/shell/commands/sc_l2_ping.c index a3be5af841..844ecc70e6 100644 --- a/sys/shell/commands/sc_l2_ping.c +++ b/sys/shell/commands/sc_l2_ping.c @@ -21,6 +21,7 @@ #include #include #include +#include #include "l2_ping.h" #include "transceiver.h" diff --git a/sys/shell/commands/sc_netif.c b/sys/shell/commands/sc_netif.c index 2bfda29960..370b677db8 100644 --- a/sys/shell/commands/sc_netif.c +++ b/sys/shell/commands/sc_netif.c @@ -22,6 +22,7 @@ #include #include #include +#include #include "thread.h" #include "net/ng_ipv6/addr.h" diff --git a/sys/shell/commands/sc_zep.c b/sys/shell/commands/sc_zep.c index f5005b4f49..39139f4fb4 100644 --- a/sys/shell/commands/sc_zep.c +++ b/sys/shell/commands/sc_zep.c @@ -15,6 +15,7 @@ #include #include #include +#include #include "net/ng_ipv6/addr.h" #include "net/ng_ipv6/netif.h" diff --git a/tests/driver_mpu9150/main.c b/tests/driver_mpu9150/main.c index e172774f00..43b1fc36ef 100644 --- a/tests/driver_mpu9150/main.c +++ b/tests/driver_mpu9150/main.c @@ -29,6 +29,7 @@ #endif #include +#include #include "mpu9150.h" #include "vtimer.h" diff --git a/tests/netdev/main.c b/tests/netdev/main.c index 9c824a8d0a..f6d298e1ba 100644 --- a/tests/netdev/main.c +++ b/tests/netdev/main.c @@ -22,6 +22,7 @@ #include #include #include +#include #ifdef MODULE_NATIVENET #include "nativenet.h" diff --git a/tests/pthread_barrier/main.c b/tests/pthread_barrier/main.c index 54a90e1b8c..fcb44ae6d9 100644 --- a/tests/pthread_barrier/main.c +++ b/tests/pthread_barrier/main.c @@ -19,6 +19,7 @@ */ #include +#include #include "pthread.h" #include "random.h" diff --git a/tests/vtimer_msg/main.c b/tests/vtimer_msg/main.c index bfdfefca46..5af1324774 100644 --- a/tests/vtimer_msg/main.c +++ b/tests/vtimer_msg/main.c @@ -21,6 +21,7 @@ #include #include +#include #include "vtimer.h" #include "thread.h" diff --git a/tests/vtimer_msg_diff/Makefile b/tests/vtimer_msg_diff/Makefile index fbdae6b891..8df2c2e5c6 100644 --- a/tests/vtimer_msg_diff/Makefile +++ b/tests/vtimer_msg_diff/Makefile @@ -1,10 +1,6 @@ APPLICATION = vtimer_msg_diff include ../Makefile.tests_common -BOARD_BLACKLIST := arduino-mega2560 -# arduino-mega2560: missing define for PRId64, avr-libc's printf function -# possibly not compatible at all - BOARD_INSUFFICIENT_RAM := mbed_lpc1768 stm32f0discovery pca10000 pca10005 USEMODULE += vtimer diff --git a/tests/vtimer_msg_diff/main.c b/tests/vtimer_msg_diff/main.c index 59f530a5f7..0cd42d6d07 100644 --- a/tests/vtimer_msg_diff/main.c +++ b/tests/vtimer_msg_diff/main.c @@ -23,6 +23,7 @@ #include #include +#include #include "vtimer.h" #include "thread.h"