added some code & compiler information to cmd_netinfo
[NeonServV5.git] / main.h
diff --git a/main.h b/main.h
index bf72d283d5dd345a76771d234ba4045f5ec60a5e..71b98db1beb5f2795212420e43155b649dc91461 100644 (file)
--- a/main.h
+++ b/main.h
@@ -1,6 +1,8 @@
 #ifndef _main_h
 #define _main_h
 
+#define NEONSERV_VERSION "5.0.1-dev"
+
 #include "config.h"
 
 #include <stdio.h>
 #define UNUSED_ARG(ARG) ARG
 #endif
 
+#define STRINGIFY_(x) #x
+#define STRINGIFY(x) STRINGIFY_(x)
+#if defined(__GNUC__)
+#if defined(__GNUC_PATCHLEVEL__)
+#define COMPILER "GCC" " " STRINGIFY(__GNUC__) "." STRINGIFY(__GNUC_MINOR__) "." STRINGIFY(__GNUC_PATCHLEVEL__)
+#else
+#define COMPILER "GCC" " " STRINGIFY(__GNUC__) "." STRINGIFY(__GNUC_MINOR__)
+#endif
+#elif defined (__IMAGECRAFT__)
+#define COMPILER "ICCAVR"
+#else
+#define COMPILER "Unknown"
+#endif
+
 #define SOCKET_SELECT_TIME 2
 
 #define NICKLEN         30