diff options
author | Joseph Poirier <jdpoirier@gmail.com> | 2015-01-08 13:40:06 -0600 |
---|---|---|
committer | Joseph Poirier <jdpoirier@gmail.com> | 2015-01-08 13:40:06 -0600 |
commit | e9f9f6f369f54f13eb94a126695989cdc35787a0 (patch) | |
tree | ae9d20e69f975916a3a685ef88a8c1292e40f553 /tests/realtimeGC | |
parent | 5f3d7e8940779cc2f03374d3e29650c6e7dc3d34 (diff) | |
download | Nim-e9f9f6f369f54f13eb94a126695989cdc35787a0.tar.gz |
proper windows get process function name, fix batch file, add echoes back
Diffstat (limited to 'tests/realtimeGC')
-rw-r--r-- | tests/realtimeGC/main.c | 6 | ||||
-rwxr-xr-x | tests/realtimeGC/make.bat | 2 | ||||
-rw-r--r-- | tests/realtimeGC/shared.nim | 1 |
3 files changed, 5 insertions, 4 deletions
diff --git a/tests/realtimeGC/main.c b/tests/realtimeGC/main.c index 8bf7aed19..a7ac19dda 100644 --- a/tests/realtimeGC/main.c +++ b/tests/realtimeGC/main.c @@ -25,9 +25,9 @@ int main(int argc, char* argv[]) #ifdef WIN hndl = (void*) LoadLibrary((char const*)"./shared.dll"); - status = (pFunc)GetProcessAddress((HMODULE) hndl, (char const*)"status"); - count = (pFunc)GetProcessAddress((HMODULE) hndl, (char const*)"count"); - occupiedMem = (pFunc)GetProcessAddress((HMODULE) hndl, (char const*)"occupiedMem"); + status = (pFunc)GetProcAddress((HMODULE) hndl, (char const*)"status"); + count = (pFunc)GetProcAddress((HMODULE) hndl, (char const*)"count"); + occupiedMem = (pFunc)GetProcAddress((HMODULE) hndl, (char const*)"occupiedMem"); #else /* OSX || NIX */ hndl = (void*) dlopen((char const*)"./libshared.so", RTLD_LAZY); status = (pFunc) dlsym(hndl, (char const*)"status"); diff --git a/tests/realtimeGC/make.bat b/tests/realtimeGC/make.bat index 182595270..cce8292bf 100755 --- a/tests/realtimeGC/make.bat +++ b/tests/realtimeGC/make.bat @@ -7,4 +7,4 @@ set INC= nim c shared.nim nim c -o:nmain main.nim -%CXX% %INC) %DEFS% %CFLAGS% -o cmain main.c %LNFLAGS% %LIBS% +%CXX% %INC% %DEFS% %CFLAGS% -o cmain main.c %LNFLAGS% %LIBS% diff --git a/tests/realtimeGC/shared.nim b/tests/realtimeGC/shared.nim index df11b4ef9..345051bb5 100644 --- a/tests/realtimeGC/shared.nim +++ b/tests/realtimeGC/shared.nim @@ -57,4 +57,5 @@ proc count() {.exportc: "count", dynlib.} = proc occupiedMem() {.exportc: "occupiedMem", dynlib.} = #echo("Occupied Memmory: ", getOccupiedMem()) + discard |