about summary refs log tree commit diff
path: root/Src/mkmakemod.sh
diff options
context:
space:
mode:
Diffstat (limited to 'Src/mkmakemod.sh')
-rw-r--r--Src/mkmakemod.sh9
1 files changed, 7 insertions, 2 deletions
diff --git a/Src/mkmakemod.sh b/Src/mkmakemod.sh
index 6c9e8bcf1..0e8702ce3 100644
--- a/Src/mkmakemod.sh
+++ b/Src/mkmakemod.sh
@@ -427,8 +427,13 @@ if $first_stage; then
 	    echo "	    done; \\"
 	    if test "$CYGWIN" = yes; then
 		echo "	    echo '# ifndef IMPORTING_MODULE_${q_name} '; \\"
-		echo "	    echo '#  undef mod_import_variable'; \\"
-		echo "	    echo '#  define mod_import_variable __attribute__((__dllimport__))'; \\"
+		echo "      echo '#  ifdef MODULE'; \\"
+		echo "	    echo '#   undef mod_import_variable'; \\"
+		echo "	    echo '#   define mod_import_variable __attribute__((__dllimport__))'; \\"
+		echo "      echo '#  else /* MODULE */'; \\"
+		echo "      echo '#   undef mod_import_variable'; \\"
+		echo "      echo '#   define mod_import_variable'; \\"
+		echo "      echo '#  endif /* MODULE */'; \\"
 		echo "	    echo '# endif /* IMPORTING_MODULE_${q_name} */'; \\"
 	    fi
 	    echo "	    echo; \\"