Skip to content

Commit

Permalink
- fixes for OMDev MinGW
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@7135 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adrpo committed Nov 20, 2010
1 parent f71200e commit ec69d87
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Compiler/runtime/Makefile.common
Expand Up @@ -11,6 +11,12 @@ builddir_lib=$(top_builddir)/build/lib
builddir_inc=$(top_builddir)/build/include
builddir_doc=$(top_builddir)/build/doc

ifndef OMDEV
configUnix = config.unix.h
else
configUnix =
endif

SRC = RTOpts_rml.c Print_rml.c System_rml.c Settings_rml.c \
SimulationResults.c IOStreamExt_rml.c rtclock.c Database.c Socket_rml.c

Expand Down Expand Up @@ -48,8 +54,8 @@ Print_rml.o : printimpl.c
Print_omc.o : printimpl.c
Error_rml.o : errorext.cpp
Error_omc.o : errorext.cpp
System_rml.o : systemimpl.c config.unix.h config.h
System_omc.o : systemimpl.c config.unix.h config.h
System_rml.o : systemimpl.c config.h $(configUnix)
System_omc.o : systemimpl.c config.h $(configUnix)
RTOpts_rml.o : rtoptsimpl.c
RTOpts_omc.o : rtoptsimpl.c
IOStreamExt_rml.o : IOStreamExt.c
Expand Down
4 changes: 4 additions & 0 deletions Compiler/runtime/systemimpl.c
Expand Up @@ -514,6 +514,8 @@ double SystemImpl__getCurrentTime()
return difftime(t, 0); // the current time
}

#if !defined(__MINGW32__) && !defined(_MSC_VER)

#ifdef __APPLE_CC__
static int file_select_mo(struct dirent *entry)
#else
Expand All @@ -538,6 +540,7 @@ static int file_select_mo(const struct dirent *entry)
}
}

#endif

#if defined(__MINGW32__) || defined(_MSC_VER)
int setenv(const char* envname, const char* envvalue, int overwrite)
Expand All @@ -554,3 +557,4 @@ int setenv(const char* envname, const char* envvalue, int overwrite)
#ifdef __cplusplus
}
#endif

0 comments on commit ec69d87

Please sign in to comment.