Skip to content

Commit

Permalink
- Compile FMIL.
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@12496 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
adeas31 committed Aug 13, 2012
1 parent 060c012 commit b40e6bb
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 11 deletions.
3 changes: 2 additions & 1 deletion Compiler/omc_release/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ CXX = @CXX@
CFLAGS = @CFLAGS@
RMLHOME = @rmlhome@
RMLINC = -I$(RMLHOME)/include/plain
FMILIB = -L../../3rdParty/FMIL/install/lib -lfmilib_shared

EXEEXT = @EXEEXT@

Expand Down Expand Up @@ -42,4 +43,4 @@ include $(srcdir)/Makefile.compiler_subdirs.common
# You're using the proper Unix Makefile. Thanks for making my life easier.

$(PROG): $(SRCO) $(SUBDIRS)
$(CXX) $(CFLAGS) -o $(PROG)$(EXEEXT) $(SRCO) $(AST) $(RTOBJ) $(LDFLAGS)
$(CXX) $(CFLAGS) -o $(PROG)$(EXEEXT) $(SRCO) $(AST) $(RTOBJ) $(LDFLAGS) $(FMILIB)
7 changes: 0 additions & 7 deletions Compiler/runtime/FMIimpl.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
extern "C" {
#endif

#if defined(__MINGW32__) || defined(_MSC_VER)
#include <stdio.h>

#include "systemimpl.h"
Expand Down Expand Up @@ -114,12 +113,6 @@ int FMIImpl__importFMU(char *fileName, char* workingDirectory)
fmi_import_free_context(context);
return 1;
}
#else
int FMIImpl__importFMU(char *fileName, char* workingDirectory)
{
return 1;
}
#endif

#ifdef __cplusplus
}
Expand Down
3 changes: 2 additions & 1 deletion Compiler/runtime/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
USE_CORBA = @USE_CORBA@

RMLINCLUDE = @rmlinc@
FMIINCLUDE = ../../3rdParty/FMIL/install/include
CFLAGS = @CFLAGS@ $(USE_CORBA)

ifdef USE_CORBA
Expand All @@ -27,7 +28,7 @@ CXX = @CXX@
IDL = @IDLCMD@
IDLPYTHON = @IDLPYTHONCMD@
CXXFLAGS = $(CFLAGS)
CPPFLAGS = -I$(RMLINCLUDE) -I$(top_builddir)/SimulationRuntime/c -I$(top_builddir)/SimulationRuntime/c/simulation/results -I$(top_builddir)/SimulationRuntime/c/util -I$(top_builddir)/SimulationRuntime/c/meta -I$(top_builddir)/SimulationRuntime/c/meta/gc -I$(srcdir) -I. $(CORBAINCL)
CPPFLAGS = -I$(RMLINCLUDE) -I$(top_builddir)/SimulationRuntime/c -I$(top_builddir)/SimulationRuntime/c/simulation/results -I$(top_builddir)/SimulationRuntime/c/util -I$(top_builddir)/SimulationRuntime/c/meta -I$(top_builddir)/SimulationRuntime/c/meta/gc -I$(srcdir) -I. $(CORBAINCL) -I$(FMIINCLUDE)

include Makefile.common

Expand Down
10 changes: 8 additions & 2 deletions Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ libdir = @libdir@
includedir = @includedir@
datadir = @datadir@
docdir = @docdir@
CMAKE = cmake
CMAKE_TARGET = "Unix Makefiles"

defaultMakefileTarget = Makefile
QMAKE=@QMAKE@
Expand All @@ -24,12 +26,16 @@ settings:

difftool: mkbuilddirs
$(MAKE) -C testsuite/difftool
omc: difftool interactive docs fmi
omc: difftool interactive docs fmi fmil
(cd Compiler && $(MAKE) -f Makefile release)

omcd: difftool interactive docs fmi
omcd: difftool interactive docs fmi fmil
(cd Compiler && $(MAKE) -f Makefile debug)

fmil:
mkdir -p 3rdParty/FMIL/build
(cd 3rdParty/FMIL/build; $(CMAKE) .. -G $(CMAKE_TARGET); $(MAKE); $(MAKE) install)

qtclean-common:
rm -rf OMShell/bin/OMShell$(EXE) OMShell/OMShellGUI/omc_communication.*
rm -rf OMNotebook/bin/OMNotebook$(EXE) OMNotebook/OMNotebookGUI/omc_communication.*
Expand Down

0 comments on commit b40e6bb

Please sign in to comment.