Yun Peng | a93e9de | 2016-06-30 14:27:38 +0000 | [diff] [blame] | 1 | #include <stdio.h> |
Yun Peng | a65ce6d | 2019-02-12 01:41:08 -0800 | [diff] [blame] | 2 | #include <time.h> |
Yun Peng | a93e9de | 2016-06-30 14:27:38 +0000 | [diff] [blame] | 3 | #include <windows.h> |
| 4 | |
Yun Peng | a65ce6d | 2019-02-12 01:41:08 -0800 | [diff] [blame] | 5 | #include "examples/windows/dll/hello-library.h" |
Yun Peng | a93e9de | 2016-06-30 14:27:38 +0000 | [diff] [blame] | 6 | |
Yun Peng | a65ce6d | 2019-02-12 01:41:08 -0800 | [diff] [blame] | 7 | DLLEXPORT char *get_time() { |
Yun Peng | a93e9de | 2016-06-30 14:27:38 +0000 | [diff] [blame] | 8 | time_t ltime; |
| 9 | time(<ime); |
| 10 | return ctime(<ime); |
| 11 | } |
| 12 | |
Yun Peng | a65ce6d | 2019-02-12 01:41:08 -0800 | [diff] [blame] | 13 | DLLEXPORT void say_hello(char *message) { |
Yun Peng | a93e9de | 2016-06-30 14:27:38 +0000 | [diff] [blame] | 14 | printf("Hello from dll!\n%s", message); |
| 15 | } |