Skip to content

Commit

Permalink
Share build dirs between projects
Browse files Browse the repository at this point in the history
  • Loading branch information
sjoelund committed May 5, 2015
1 parent d6652d4 commit d41c2b1
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 4 deletions.
14 changes: 14 additions & 0 deletions m4/ombuilddir.m4
@@ -0,0 +1,14 @@
AC_SUBST(OMBUILDDIR)
AC_ARG_WITH(ombuilddir, [ --with-ombuilddir=[build] (where build files are generated; OPENMODELICAHOME)],[OMBUILDDIR="$withval"],[OMBUILDDIR="no"])
if test "$OMBUILDDIR" = "no"; then
OMBUILDDIR=$ac_pwd/build
ac_configure_args="$ac_configure_args --with-ombuilddir=$OMBUILDDIR"
fi

if test "$prefix" = "NONE"; then
PREFIX="$OMBUILDDIR"
else
PREFIX=$prefix
fi
AC_PREFIX_DEFAULT($PREFIX)
prefix=$PREFIX
6 changes: 2 additions & 4 deletions m4/omhome.m4
@@ -1,7 +1,5 @@
AC_SUBST(OPENMODELICAHOME)
AC_ARG_WITH(openmodelicahome, [ --with-openmodelicahome=[$OPENMODELICAHOME|$prefix] (Find OPENMODELICAHOME - the directory where all OpenModelica dependencies are installed.)],[OMHOME="$withval"],[OMHOME=no])

test "$prefix" = NONE && prefix=$ac_default_prefix
AC_ARG_WITH(openmodelicahome, [ --with-openmodelicahome=[$OPENMODELICAHOME|$PREFIX] (Find OPENMODELICAHOME - the directory where all OpenModelica dependencies are installed.)],[OMHOME="$withval"],[OMHOME=no])

if echo $host | grep -iq darwin; then
APP=".app"
Expand All @@ -28,7 +26,7 @@ define(FIND_OPENMODELICAHOME, [
AC_MSG_CHECKING([for OPENMODELICAHOME])
if test "$OMHOME" = "no"; then
if test -z "$OPENMODELICAHOME"; then
OPENMODELICAHOME="$prefix"
OPENMODELICAHOME="$PREFIX"
else
OPENMODELICAHOME="$OPENMODELICAHOME"
fi
Expand Down

0 comments on commit d41c2b1

Please sign in to comment.