Makefile: add -W to produce even stricter warnings
[flog.git] / config.h
blobfb92b4df75355c5dca13db74df7fe08a5235761a
1 //! Config file for Flog
3 //! @file config.h
4 //! @author Nabeel Sowan (nabeel.sowan@vibes.se)
5 //!
6 //! Set these defines according to the needs of your project.
9 //! @def FLOG_CONFIG_ALLOW_NULL_MESSAGES
10 //! If defined, then messages with msg_id=0 and a NULL text string will
11 //! be passed on as valid flog messages.
12 #define FLOG_CONFIG_ALLOW_NULL_MESSAGES
15 //! @def FLOG_CONFIG_MSG_TYPE_ENUM_API
16 //! If defined, allows using an enum API for flog message types.
17 //! What this means is that FLOG_MSG_TYPE_T will be defined as an int
18 //! (instead of unsigned char) In return, enums may yield stronger
19 //! type checking and therefore easier debugging.
20 #define FLOG_CONFIG_MSG_TYPE_ENUM_API
23 //! @def FLOG_CONFIG_ABORT_ON_ASSERT
24 //! If defined then flog_assert() will call abort() on assertion failure.
25 //! This behaviour can be switched off for deeply embedded systems where
26 //! calling abort() doesn't make any sense.
27 #define FLOG_CONFIG_ABORT_ON_ASSERT
30 //! @def FLOG_CONFIG_TIMESTAMP
31 //! If defined, then this activates timestamping of flog messages,
32 //! using time.h. This requires working time routines in libc.
33 #define FLOG_CONFIG_TIMESTAMP
36 //! @def FLOG_CONFIG_TIMESTAMP_USEC
37 //! If defined, then this activates timestamping of flog messages with
38 //! millisecond (usec) accuracy. Requires sys/time.h support.
39 #define FLOG_CONFIG_TIMESTAMP_USEC
42 //! @def FLOG_CONFIG_SRC_INFO
43 //! If defined, then each flog message will contain information about the
44 //! specific file, line and function name where flog_print(f) was called.
45 #define FLOG_CONFIG_SRC_INFO
48 //! @def FLOG_CONFIG_STRING_OUTPUT
49 //! If defined, then string output routines will be included in the
50 //! flog_string module. Omitting this will save a few k by avoiding
51 //! some code from stdio etc. Useful for cases where a deeply embedded
52 //! system should only transmit flog messages in binary form over a network.
53 #define FLOG_CONFIG_STRING_OUTPUT
56 //! @def FLOG_CONFIG_MSG_ID_STRINGS
57 //! If defined, then the FLOG_MSG_ID string data will be included.
58 //! This can be omitted for deeply embedded systems where string generation
59 //! isn't strictly necessary, and can be decoded by the receiver.
60 #define FLOG_CONFIG_MSG_ID_STRINGS
63 //! @def FLOG_CONFIG_ERRNO_STRINGS
64 //! If defined, then setting msg_id to a valid libc errno will fetch the
65 //! correct string from libc when outputing a string.
66 #define FLOG_CONFIG_ERRNO_STRINGS
69 //! @def FLOG_CONFIG_OUTPUT_SHOW_MSG_ID
70 //! If defined, then output of msg_id messages will print the msg_id
71 //! number (be it errno or a flog msg id)
72 #define FLOG_CONFIG_OUTPUT_SHOW_MSG_ID
75 //! @def FLOG_CONFIG_OUTPUT_STDIO
76 //! If defined, then flog will include the stdio output module (stdout and stderr)
77 #define FLOG_CONFIG_OUTPUT_STDIO
80 //! @def FLOG_CONFIG_OUTPUT_FILE
81 //! If defined, then flog will include the simple file output module.
82 #define FLOG_CONFIG_OUTPUT_FILE