summaryrefslogtreecommitdiff
path: root/tools/gbagfx/global.h
diff options
context:
space:
mode:
authorMarcus Huderle <huderlem@gmail.com>2018-10-13 15:49:44 -0500
committerMarcus Huderle <huderlem@gmail.com>2018-10-13 15:49:44 -0500
commitc4fc85ce9e843e419ef9e3c1c2f888529c7e40d8 (patch)
tree36f91072a7471ea189132feffddc888a0c0cb937 /tools/gbagfx/global.h
parent10896eccf02894afd3ab1b164280c892bdf7ec49 (diff)
Add graphics capabilities
Diffstat (limited to 'tools/gbagfx/global.h')
-rwxr-xr-xtools/gbagfx/global.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/tools/gbagfx/global.h b/tools/gbagfx/global.h
new file mode 100755
index 0000000..65dd351
--- /dev/null
+++ b/tools/gbagfx/global.h
@@ -0,0 +1,31 @@
+// Copyright (c) 2015 YamaArashi
+
+#ifndef GLOBAL_H
+#define GLOBAL_H
+
+#include <stdio.h>
+#include <stdlib.h>
+
+#ifdef _MSC_VER
+
+#define FATAL_ERROR(format, ...) \
+do { \
+ fprintf(stderr, format, __VA_ARGS__); \
+ exit(1); \
+} while (0)
+
+#define UNUSED
+
+#else
+
+#define FATAL_ERROR(format, ...) \
+do { \
+ fprintf(stderr, format, ##__VA_ARGS__); \
+ exit(1); \
+} while (0)
+
+#define UNUSED __attribute__((__unused__))
+
+#endif // _MSC_VER
+
+#endif // GLOBAL_H