summaryrefslogtreecommitdiffstats
path: root/Source/kwsys/kwsysPlatformTestsC.c
diff options
context:
space:
mode:
Diffstat (limited to 'Source/kwsys/kwsysPlatformTestsC.c')
-rw-r--r--Source/kwsys/kwsysPlatformTestsC.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/Source/kwsys/kwsysPlatformTestsC.c b/Source/kwsys/kwsysPlatformTestsC.c
new file mode 100644
index 0000000..36c5f4d
--- /dev/null
+++ b/Source/kwsys/kwsysPlatformTestsC.c
@@ -0,0 +1,25 @@
+/* Macros to define main() in a cross-platform way.
+ Usage:
+
+ int KWSYS_PLATFORM_TEST_C_MAIN()
+ {
+ return 0;
+ }
+
+ int KWSYS_PLATFORM_TEST_C_MAIN_ARGS(argc, argv)
+ {
+ (void)argc; (void)argv;
+ return 0;
+ }
+*/
+#if defined(__CLASSIC_C__)
+# define KWSYS_PLATFORM_TEST_C_MAIN() \
+ main()
+# define KWSYS_PLATFORM_TEST_C_MAIN_ARGS(argc, argv) \
+ main(argc,argv) int argc; char* argv[];
+#else
+# define KWSYS_PLATFORM_TEST_C_MAIN() \
+ main(void)
+# define KWSYS_PLATFORM_TEST_C_MAIN_ARGS(argc, argv) \
+ main(int argc, char* argv[])
+#endif