From e690320b1d9fdac941a280dbe5146b0071d31c22 Mon Sep 17 00:00:00 2001
From: michel <michel@ac1d8469-bf42-47a9-8791-bf33cf982152>
Date: Sun, 6 Dec 2009 11:56:11 +0000
Subject: [PATCH] 4.1: more defined __CYGWIN32__

git-svn-id: https://www.dynare.org/svn/dynare/trunk@3196 ac1d8469-bf42-47a9-8791-bf33cf982152
---
 mex/sources/k_order_perturbation/dynamic_dll.h | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/mex/sources/k_order_perturbation/dynamic_dll.h b/mex/sources/k_order_perturbation/dynamic_dll.h
index 2c1657c2fe..f12996b3c8 100644
--- a/mex/sources/k_order_perturbation/dynamic_dll.h
+++ b/mex/sources/k_order_perturbation/dynamic_dll.h
@@ -24,7 +24,7 @@
 // K_ORDER_PERTURBATION_API functions as being imported from a DLL, wheras this DLL sees symbols
 // defined with this macro as being exported.
 
-#ifdef _WIN32
+#if (defined _WIN32) || (defined __CYGWIN32__)
 # include <windows.h>
 # ifdef _MSC_VER
 #  define K_ORDER_PERTURBATION_API __declspec(dllexport)
@@ -39,7 +39,7 @@
 #include "dynare_exception.h"
 
 // <model>_Dynamic DLL pointer
-#ifdef _WIN32
+#if (defined _WIN32) || (defined __CYGWIN32__)
 typedef void  *(DynamicFn)
 #else // Linux or Mac
 typedef void  (*DynamicFn)
@@ -56,7 +56,7 @@ typedef void *(mexFunctionPtr)(int nlhs, mxArray *plhs[], int nrhs, const mxArra
 class DynamicModelDLL
 {
 private:
-#ifdef _WIN32
+#if (defined _WIN32) || (defined __CYGWIN32__)
   DynamicFn  *Dynamic; // pointer to the Dynamic function in DLL
 #else
   DynamicFn  Dynamic; // pointer to the Dynamic function in DLL
@@ -65,7 +65,7 @@ private:
   const int jcols;  // tot num var t-1, t and t+1 instances + exogs = Num of Jacobian columns
   const int nMax_lag; // no of lags
   const int nExog; // no of exogenous
-#ifdef _WIN32
+#if (defined _WIN32) || (defined __CYGWIN32__)
   HINSTANCE dynamicHinstance;  // DLL instance pointer in Windows
 #else
   void *dynamicHinstance; // and in Linux or Mac
-- 
GitLab