Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix foreign test for i3nt #860

Merged
merged 1 commit into from
Aug 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions mats/build.zuo
Original file line number Diff line number Diff line change
Expand Up @@ -363,9 +363,6 @@
"cc")))
(cons "FTYPE_CFLAGS"
(build-shell (or (lookup 'CPPFLAGS) "")
(if (eq? 'windows (system-type))
"-DWIN32"
"")
(or (lookup 'mdinclude) "")
(or (lookup 'CFLAGS) "")
(or (lookup 'mdcflags) "")))
Expand Down
6 changes: 3 additions & 3 deletions mats/foreign3.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#include <stdio.h>
#include <stdlib.h>

#ifndef WIN32
#ifndef _WIN32
#include <string.h>
#endif

Expand Down Expand Up @@ -178,7 +178,7 @@ EXPORT char Srvtest_char(ptr code, ptr x1) {
return (*((char (*)(ptr))Sforeign_callable_entry_point(code)))(x1);
}

#ifdef WIN32
#ifdef _WIN32
EXPORT int __stdcall sum_stdcall(int a, int b) {
return a + b;
}
Expand Down Expand Up @@ -208,7 +208,7 @@ EXPORT com_instance_t *get_com_instance(void) {
com_instance.data = -31;
return &com_instance;
}
#endif /* WIN32 */
#endif /* _WIN32 */

/* foreign_callable example adapted from foreign.stex */
typedef void (*CB)(char);
Expand Down
2 changes: 1 addition & 1 deletion mats/ftype.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ typedef unsigned long long uint64_t;

#endif

#ifdef WIN32
#ifdef _WIN32
#define EXPORT extern __declspec (dllexport)
#else
#define EXPORT extern
Expand Down