|
1 | | -# Adrian Pop, adrpo@ida.liu.se, 2006-02-01 |
2 | | -# Makefile for compilation of OMC using OMDev-mingw |
3 | | -# OMDev-mingw: http://www.ida.liu.se/~adrpo/omc/omdev/ |
4 | | -# |
5 | | -# $Id: Makefile.omdev.mingw.in 1817 2006-02-01 12:21:26Z adrpo $ |
6 | | -# |
7 | | -
|
8 | | -# The path to the OMDev-mingw package MUST BE SET! |
9 | | -#OMDEV=$OMDEV |
10 | | -# Test if the needed variables are there... |
11 | | -
|
12 | | -.testvariables: |
13 | | -ifndef OMDEV |
14 | | - @echo You have to set the OMDEV variabile pointing to your OMDev package root! Exiting.... |
15 | | - @echo Take the OMDev package from: http://www.ida.liu.se/~adrpo/omc/omdev/ |
16 | | - @echo For questions or problems email Adrian Pop, adrpo@ida.liu.se |
17 | | - ABORT |
18 | | -endif |
19 | | -
|
20 | | -srcdir= . |
21 | | -top_builddir= .. |
22 | | -builddir_bin=$(top_builddir)/build/bin |
23 | | -builddir_scripts=$(top_builddir)/build/share/omc/scripts |
24 | | -builddir_lib=$(top_builddir)/build/lib/omc |
25 | | -
|
26 | | -# adrpo, libsocket should be -lwsock32 but is not needed! |
27 | | -LIBSOCKET = -lwsock32 |
28 | | -
|
29 | | -SHELL = /bin/sh |
30 | | -CC = cc |
31 | | -override CFLAGS += $(USE_CORBA) |
32 | | -
|
33 | | -USE_CORBA = -DUSE_CORBA |
34 | | -CORBAHOME = $(OMDEV) |
35 | | -
|
36 | | -SCRIPT_FILES = Compile.bat openmodelica.lefty default_profiling.xsl replace-startValue.* simcodedump.xsl ngspicetoModelica.py |
37 | | -
|
38 | | -SUBDIRS = runtime Script |
39 | | -
|
40 | | -.SUFFIXES: |
41 | | -.SUFFIXES: .o .mo .h |
42 | | -.PHONY: all subdirs report vctarget release clean test reallyclean builtin |
43 | | -
|
44 | | -all : .testvariables release simcode builtin |
45 | | -
|
46 | | -include Makefile.common |
47 | | -
|
48 | | -release: .testvariables install |
49 | | -
|
50 | | -install_scripts: |
51 | | - cd scripts; cp -puf $(SCRIPT_FILES) ../$(builddir_scripts) |
52 | | -
|
53 | | -install: install_scripts # install_doc |
54 | | - cp OpenModelicaBootstrappingHeader.h $(top_builddir)/build/include/omc/ |
55 | | -
|
56 | | -clean: |
57 | | - @for d in $(SUBDIRS); do \ |
58 | | - (cd $$d ; $(MAKE) -f Makefile.omdev.mingw clean) \ |
59 | | - done |
60 | | - -cd $(builddir_bin) && rm -f $(SCRIPT_FILES) |
61 | | -
|
62 | | -reallyclean: |
63 | | - @for d in $(SUBDIRS); do \ |
64 | | - (cd $$d ; $(MAKE) -f Makefile.omdev.mingw reallyclean) \ |
65 | | - done |
66 | | -
|
67 | | -report: |
68 | | - @(cd report ; $(MAKE)) |
69 | | -
|
70 | | -ifeq ($(wildcard ../build/bin/omc.exe),) |
71 | | -simcode: |
72 | | - @echo OpenModelica has not been compiled yet. Using previously generated SimCode files. |
73 | | -else |
74 | | -simcode: OpenModelicaBootstrappingHeader.h |
75 | | - $(MAKE) -C Template/ -f Makefile.omdev.mingw |
76 | | -OpenModelicaBootstrappingHeader.h: FrontEnd/Absyn.mo Script/GlobalScript.mo FrontEnd/Values.mo Util/Error.mo Util/Util.mo Util/FMI.mo GenerateOMCHeader.mos |
77 | | - ../build/bin/omc +g=MetaModelica GenerateOMCHeader.mos > $@.log || (cat $@.log && false) |
78 | | - @mv $@.new $@ |
79 | | -endif |
80 | | -$(SUSANMO): simcode |
81 | | -
|
82 | | -builtin: |
83 | | - cp FrontEnd/ModelicaBuiltin.mo FrontEnd/MetaModelicaBuiltin.mo $(builddir_lib) |
84 | | -
|
85 | | -#.PRECIOUS: Makefile.omdev.mingw |
86 | | -# |
87 | | -#Makefile.omdev.mingw: Makefile.omdev.mingw.in |
88 | | -# $(top_builddir)/config.status Makefile.omdev.mingw |
| 1 | +# Adrian Pop, adrpo@ida.liu.se, 2006-02-01 |
| 2 | +# Makefile for compilation of OMC using OMDev-mingw |
| 3 | +# OMDev-mingw: http://www.ida.liu.se/~adrpo/omc/omdev/ |
| 4 | +# |
| 5 | +# $Id: Makefile.omdev.mingw.in 1817 2006-02-01 12:21:26Z adrpo $ |
| 6 | +# |
| 7 | + |
| 8 | +# The path to the OMDev-mingw package MUST BE SET! |
| 9 | +#OMDEV=$OMDEV |
| 10 | +# Test if the needed variables are there... |
| 11 | + |
| 12 | +.testvariables: |
| 13 | +ifndef OMDEV |
| 14 | + @echo You have to set the OMDEV variabile pointing to your OMDev package root! Exiting.... |
| 15 | + @echo Take the OMDev package from: http://www.ida.liu.se/~adrpo/omc/omdev/ |
| 16 | + @echo For questions or problems email Adrian Pop, adrpo@ida.liu.se |
| 17 | + ABORT |
| 18 | +endif |
| 19 | + |
| 20 | +srcdir= . |
| 21 | +top_builddir= .. |
| 22 | +builddir_bin=$(top_builddir)/build/bin |
| 23 | +builddir_scripts=$(top_builddir)/build/share/omc/scripts |
| 24 | +builddir_lib=$(top_builddir)/build/lib/omc |
| 25 | + |
| 26 | +# adrpo, libsocket should be -lwsock32 but is not needed! |
| 27 | +LIBSOCKET = -lwsock32 |
| 28 | + |
| 29 | +SHELL = /bin/sh |
| 30 | +CC = cc |
| 31 | +override CFLAGS += $(USE_CORBA) |
| 32 | + |
| 33 | +USE_CORBA = -DUSE_CORBA |
| 34 | +CORBAHOME = $(OMDEV) |
| 35 | + |
| 36 | +SCRIPT_FILES = Compile.bat openmodelica.lefty default_profiling.xsl replace-startValue.* simcodedump.xsl ngspicetoModelica.py |
| 37 | + |
| 38 | +SUBDIRS = runtime Script |
| 39 | + |
| 40 | +.SUFFIXES: |
| 41 | +.SUFFIXES: .o .mo .h |
| 42 | +.PHONY: all subdirs report vctarget release clean test reallyclean builtin |
| 43 | + |
| 44 | +all : .testvariables release simcode builtin |
| 45 | + |
| 46 | +include Makefile.common |
| 47 | + |
| 48 | +release: .testvariables install |
| 49 | + |
| 50 | +install_scripts: |
| 51 | + cd scripts; cp -puf $(SCRIPT_FILES) ../$(builddir_scripts) |
| 52 | + |
| 53 | +install: install_scripts # install_doc |
| 54 | + cp OpenModelicaBootstrappingHeader.h $(top_builddir)/build/include/omc/ |
| 55 | + |
| 56 | +clean: |
| 57 | + @for d in $(SUBDIRS); do \ |
| 58 | + (cd $$d ; $(MAKE) -f Makefile.omdev.mingw clean) \ |
| 59 | + done |
| 60 | + -cd $(builddir_bin) && rm -f $(SCRIPT_FILES) |
| 61 | + |
| 62 | +reallyclean: |
| 63 | + @for d in $(SUBDIRS); do \ |
| 64 | + (cd $$d ; $(MAKE) -f Makefile.omdev.mingw reallyclean) \ |
| 65 | + done |
| 66 | + |
| 67 | +report: |
| 68 | + @(cd report ; $(MAKE)) |
| 69 | + |
| 70 | +ifeq ($(wildcard ../build/bin/omc.exe),) |
| 71 | +simcode: |
| 72 | + @echo OpenModelica has not been compiled yet. Using previously generated SimCode files. |
| 73 | +else |
| 74 | +simcode: OpenModelicaBootstrappingHeader.h |
| 75 | + $(MAKE) -C Template/ -f Makefile.omdev.mingw |
| 76 | +OpenModelicaBootstrappingHeader.h: FrontEnd/Absyn.mo Script/GlobalScript.mo FrontEnd/Values.mo Util/Error.mo Util/Util.mo Util/FMI.mo GenerateOMCHeader.mos |
| 77 | + ../build/bin/omc +g=MetaModelica GenerateOMCHeader.mos > $@.log || (cat $@.log && false) |
| 78 | + @mv $@.new $@ |
| 79 | +endif |
| 80 | +$(SUSANMO): simcode |
| 81 | + |
| 82 | +builtin: |
| 83 | + cp FrontEnd/ModelicaBuiltin.mo FrontEnd/MetaModelicaBuiltin.mo $(builddir_lib) |
| 84 | + |
| 85 | +#.PRECIOUS: Makefile.omdev.mingw |
| 86 | +# |
| 87 | +#Makefile.omdev.mingw: Makefile.omdev.mingw.in |
| 88 | +# $(top_builddir)/config.status Makefile.omdev.mingw |
0 commit comments