branch: development
commit 46b9dbe50c4d5796203a063d54c2ea47ec3089d2
Author: Ileana Dumitrescu <[email protected]>
AuthorDate: Wed Dec 11 18:43:47 2024 +0200
tests: Include check for __CYGWIN__ for crossbuilds
* tests/demo.at, tests/lt_dlexit.at: Add __CYGWIN__ to check for
crossbuilds of build cygwin with host mingw and the MSVC toolchain.
---
tests/demo.at | 2 +-
tests/lt_dlexit.at | 8 ++++++--
2 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/tests/demo.at b/tests/demo.at
index 036e434e..1b4a2e89 100644
--- a/tests/demo.at
+++ b/tests/demo.at
@@ -152,7 +152,7 @@ AT_DATA([foo.h],
# endif
#endif
-#if (defined _WIN32 || defined _WIN32_WCE) && !defined __GNUC__
+#if (defined _WIN32 || defined _WIN32_WCE || __CYGWIN__) && !defined __GNUC__
# ifdef BUILDING_LIBHELLO
# ifdef DLL_EXPORT
# define LIBHELLO_SCOPE extern __declspec (dllexport)
diff --git a/tests/lt_dlexit.at b/tests/lt_dlexit.at
index 19adeec4..51f26f23 100644
--- a/tests/lt_dlexit.at
+++ b/tests/lt_dlexit.at
@@ -115,8 +115,12 @@ AT_DATA([b1.c],
[[#ifdef __cplusplus
extern "C" {
#endif
-#if defined DLL_EXPORT && defined _WIN32 && defined _MSC_VER
-# define LIBA1_SCOPE extern __declspec (dllimport)
+#if defined DLL_EXPORT
+# if defined __CYGWIN__ || defined _WIN32 || defined WIN32
+# if defined _MSC_VER
+# define LIBA1_SCOPE extern __declspec (dllimport)
+# endif
+# endif
#endif
#if !defined LIBA1_SCOPE
# define LIBA1_SCOPE extern