forked from OpenModelica/OMCompiler
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.in
118 lines (102 loc) · 3.87 KB
/
Makefile.in
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
all: omc
autoconfGeneratedFiles = @GENERATED_AUTOCONF_FILES@
OMBUILDDIR=@OMBUILDDIR@
prefix = @prefix@
exec_prefix = @exec_prefix@
bindir = @bindir@
libdir = @libdir@
includedir = @includedir@
datadir = @datadir@
datarootdir = @datarootdir@
docdir = @docdir@
CMAKE = CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" LDFLAGS="@CMAKE_LDFLAGS@" cmake
CMAKE_RPATH = CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS)" CXXFLAGS="$(CXXFLAGS)" CPPFLAGS="$(CPPFLAGS)" LDFLAGS="@RPATH_QMAKE@ @CMAKE_LDFLAGS@" cmake
CMAKE_TARGET = "Unix Makefiles"
OPENCL = @OPENCL@
AR = @AR@
host = @host@
host_short = @host_short@
FC = @FC@
defaultMakefileTarget = Makefile
MAKEFILE_BOOT = LinkMain.makefile
QMAKE=@QMAKE@
APP=@APP@
CC=@CC@
CXX=@CXX@
CFLAGS=@CFLAGS@
MSGPACK_CFLAGS =
CPPFLAGS=@CPPFLAGS@
CXXFLAGS=@CXXFLAGS@
LDFLAGS=@LDFLAGS@
LDFLAGS_LIBSTDCXX=@LDFLAGS_LIBSTDCXX@
LINK=@LINK@
MSL_EXTRA_ARGS=@MSL_EXTRA_ARGS@
# LIBGC configuration is different for Linux (this file) and Windows (Makefile.omdev.mingw)
# Do not use munmap; it crashes processes...
LIBGC_EXTRA_CONFIGURATION=--enable-threads=posix --enable-parallel-mark
LIBFMILIB=@LIBFMILIB@
LIBCMINPACKLIB=@LIBCMINPACKLIB@
LD_LAPACK=@LD_LAPACK@
LAPACK_TARGET=@LAPACK_TARGET@
OPENBLAS_EXTRA_ARGS=@OPENBLAS_EXTRA_ARGS@
IPOPT_TARGET=ipopt
UMFPACK_TARGET=@UMFPACK_TARGET@
UMFPACK_SHARED=ON
# We don't want the shared version, but symbols are not exported if we use the static version
# This compiles the shared and static versions, but we only copy the static version...
FMILIB_SHARED = @FMILIB_SHARED@
CMINPACKLIB_SHARED = @CMINPACKLIB_SHARED@
MODELICA_SPEC_PLATFORM=@MODELICA_SPEC_PLATFORM@
SHREXT = @SHREXT@
BOOST_INCLUDE = @BOOST_INCLUDE@
WITH_FMIL=@WITH_FMIL@
ifeq ($(WITH_FMIL),yes)
BOOTSTRAP_FMIL_DEP=fmil
endif
LIB_OMC=lib/@host_short@/omc
LIBMODELICAEXTERNALC=@OMBUILDDIR@/lib/@host_short@/omc/libModelicaExternalC@SHREXT@
LIBMODELICASTANDARDTABLES=@OMBUILDDIR@/lib/@host_short@/omc/libModelicaStandardTables@SHREXT@
include Makefile.common
# We don't need OMDEV hacks, but using the same Makefile sure is nice!
.testvariables:
settings:
omc: omc-bootstrapped
boehm-gc-lib: @LIBGC@
$(OMBUILDDIR)/$(LIB_OMC)/libomcgc.so: 3rdParty/gc/.libs/libomcgc.so
mkdir -p $(OMBUILDDIR)/$(LIB_OMC)
cp -pPR $< $<.* $(OMBUILDDIR)/$(LIB_OMC)/
3rdParty/gc/.libs/libomcgc.so: 3rdParty/gc/Makefile
$(MAKE) -C 3rdParty/gc/ libomcgc.la
omc-bootstrapped: mkbuilddirs
$(MAKE) bootstrap-dependencies interactive sim-dependencies
$(MAKE) -C Compiler/boot
omc-no-sim:
$(MAKE) bootstrap-dependencies interactive-short
$(MAKE) -C Compiler/boot
$(MAKE) omlibrary
lis: lis-configure
@echo Building Lis from sources
$(MAKE) -C 3rdParty/lis-1.4.12/src
# Copy the library; not headers (as they are not used by the runtime system)
cp -Pp 3rdParty/lis-1.4.12/src/.libs/liblis@SHREXT@* $(OMBUILDDIR)/$(LIB_OMC)/
@# FreeBSD lis does not create the symlinks...
! test -f build/lib/omc/liblis.so.0.0 -a ! -f $(OMBUILDDIR)/lib/omc/liblis.so.0 || ln -s liblis.so.0.0 $(OMBUILDDIR)/lib/omc/liblis.so.0
! test -f build/lib/omc/liblis.so.0.0 -a ! -f $(OMBUILDDIR)/lib/omc/liblis.so || ln -s liblis.so.0.0 $(OMBUILDDIR)/lib/omc/liblis.so
lis-configure:
# Configure and build lis
if ! test -f 3rdParty/lis-1.4.12/Makefile; then cd 3rdParty/lis-1.4.12 && autoconf && ./configure "--host=$(host)" --enable-shared --disable-static MPICC="false" CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS)" CPPFLAGS="$(CPPFLAGS)" LDFLAGS="$(LDFLAGS) @LIS_LDFLAGS@" && $(MAKE) clean; fi
lis-clean:
if test -f 3rdParty/lis-1.4.12/Makefile; then $(MAKE) -C 3rdParty/lis-1.4.12 clean; fi
rm -f 3rdParty/lis-1.4.12/Makefile
.PRECIOUS: Makefile
Makefile: Makefile.in config.status common/m4/*.m4
./config.status
config.status: configure
./config.status -recheck
configure: configure.ac
autoconf
emcc: msl-external-libs-emcc emcc-simulationruntime
emcc-simulationruntime:
mkdir -p build/lib/omc/emcc/
$(MAKE) -C SimulationRuntime/c emcc
copycppheader: