Crow  0.3
A C++ microframework for the web
settings.h
1 #pragma once
2 // settings for crow
3 // TODO - replace with runtime config. libucl?
4 
5 /* #ifdef - enables debug mode */
6 //#define CROW_ENABLE_DEBUG
7 
8 /* #ifdef - enables logging */
9 #define CROW_ENABLE_LOGGING
10 
11 /* #ifdef - enables ssl */
12 //#define CROW_ENABLE_SSL
13 
14 /* #define - specifies log level */
15 /*
16  Debug = 0
17  Info = 1
18  Warning = 2
19  Error = 3
20  Critical = 4
21 
22  default to INFO
23 */
24 #ifndef CROW_LOG_LEVEL
25 #define CROW_LOG_LEVEL 1
26 #endif
27 
28 #ifndef CROW_STATIC_DIRECTORY
29 #define CROW_STATIC_DIRECTORY "static/"
30 #endif
31 #ifndef CROW_STATIC_ENDPOINT
32 #define CROW_STATIC_ENDPOINT "/static/<path>"
33 #endif
34 
35 // compiler flags
36 #if defined(_MSVC_LANG) && _MSVC_LANG >= 201402L
37 #define CROW_CAN_USE_CPP14
38 #endif
39 #if __cplusplus >= 201402L
40 #define CROW_CAN_USE_CPP14
41 #endif
42 
43 #if defined(_MSC_VER)
44 #if _MSC_VER < 1900
45 #define CROW_MSVC_WORKAROUND
46 #define constexpr const
47 #define noexcept throw()
48 #endif
49 #endif