forked from OpenModelica/OpenModelica
-
Notifications
You must be signed in to change notification settings - Fork 1
/
configure.ac
65 lines (53 loc) · 1.7 KB
/
configure.ac
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
dnl Process this file with autoconf to produce a configure script.
AC_PREREQ([2.63])
AC_INIT([OpenModelica],[dev],[https://trac.openmodelica.org/OpenModelica],[openmodelica],[https://openmodelica.org])
AC_LANG([C])
AC_PROG_CC
AC_PROG_CXX
AC_PROG_CPP
m4_include([common/m4/pre-commit.m4])
m4_include([common/m4/ombuilddir.m4])
m4_include([common/m4/omhome.m4])
AC_SUBST(RPATH_QMAKE)
AC_SUBST(SHREXT)
AC_SUBST(APP)
AC_SUBST(CMAKE)
AC_SUBST(OMC_TARGET)
AC_ARG_WITH(cppruntime, [ --with-cppruntime (build the optional cppruntime simulation libraries)],[OMC_TARGET="$withval"],[OMC_TARGET="no"])
AC_MSG_CHECKING([if cppruntime is requested])
if test "$OMC_TARGET" = "yes"; then
OMC_TARGET=all-runtimeCPPinstall
AC_MSG_RESULT([yes])
else
OMC_TARGET=
AC_MSG_RESULT([no])
fi
AC_SUBST(CMAKE_LDFLAGS)
if echo $host | grep -i darwin; then
CMAKE_LDFLAGS="-Wl,-U,libintl_gettext"
fi
m4_include([common/m4/corba.m4])
AC_SUBST(ALL_TARGETS)
if test ! -z "$USE_CORBA"; then
CORBA_TARGETS="OMOptim-omoptim"
fi
for dir_target in OMCompiler-omc OMPlot-omplot OMEdit-omedit OMNotebook-omnotebook OMShell-omshell OMSens_Qt-omsens_qt $CORBA_TARGETS; do
dir=`echo $dir_target | cut -d- -f1`
if test ! -f "$dir/configure.ac"; then
AC_MSG_NOTICE("Subproject $dir does not exist")
else
if !(cd "$dir" && autoconf); then
AC_MSG_ERROR("Failed to autoconf $dir")
fi
ALL_TARGETS="$ALL_TARGETS `echo $dir_target | cut -d- -f2-`"
fi
done
AC_SUBST(ALL_TARGETS)
if test -f testsuite/Makefile; then
ALL_TARGETS="$ALL_TARGETS testsuite-depends"
fi
AC_CONFIG_SUBDIRS([OMCompiler OMPlot OMEdit OMNotebook OMShell OMSens_Qt])
if test ! -z "$USE_CORBA"; then
AC_CONFIG_SUBDIRS([OMOptim])
fi
AC_OUTPUT(Makefile)