Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-common
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Timo Koch
dune-common
Commits
1c5437af
Commit
1c5437af
authored
20 years ago
by
Thimo Neubauer
Browse files
Options
Downloads
Patches
Plain Diff
first check if ug-libs work on their own. If that fails, pass MPI-libs
and try again [[Imported from SVN: r1023]]
parent
cd50b9f9
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
m4/ug.m4
+27
-26
27 additions, 26 deletions
m4/ug.m4
with
27 additions
and
26 deletions
m4/ug.m4
+
27
−
26
View file @
1c5437af
...
...
@@ -2,23 +2,11 @@
# $Id$
# searches for UG headers and libs
# TODO:
#
# - nicht nur X suchen, sondern auch Xaw (und Xt?)
# - $UGROOT auswerten, wenn es schon gesetzt ist
# - gefundenes $MAKE verwenden, nicht einfach "make"
# - ug.conf auswerten
# IF = X|S
# DOM_MODULE -> -D...
# GRAPE
# DIM?
AC_DEFUN
([
DUNE_PATH_UG],[
AC_REQUIRE
([
AC_PROG_CC]
)
AC_REQUIRE
([
AC_PATH_XTRA]
)
AC_REQUIRE
([
DUNE_DIMENSION]
)
AC_REQUIRE
([
DUNE_MPI]
)
AC_ARG_WITH
(
ug,
AC_HELP_STRING
([
--with-ug
=
PATH],[directory with UG inside]
))
...
...
@@ -28,12 +16,6 @@ AC_DEFUN([DUNE_PATH_UG],[
ac_save_CPPFLAGS
=
"
$CPPFLAGS
"
ac_save_LIBS
=
"
$LIBS
"
if
test
"x
$X_LIBS
"
!=
x
;
then
LIBS
=
"
$X_PRE_LIBS
-lX11
$X_LIBS
$X_EXTRA_LIBS
-lXt -lXaw"
else
LIBS
=
""
fi
## do nothing if --without-ug is used
if
test
x
$with_ug
!=
xno
;
then
...
...
@@ -123,24 +105,43 @@ AC_DEFUN([DUNE_PATH_UG],[
AC_LANG_PUSH
([
C++]
)
if
test
x
$HAVE_UG
=
x1
;
then
AC_MSG_CHECKING
(
libug
$UG_DIM
)
# prepare test
CPPFLAGS
=
"
$UG_CPPFLAGS
"
LIBS
=
"-lug
$UG_DIM
-ldomS
$UG_DIM
-lgg
$UG_DIM
-ldevS"
CPPFLAGS
=
"
$UG_CPPFLAGS
"
UG_LIBS
=
"-lug
$UG_DIM
-ldomS
$UG_DIM
-lgg
$UG_DIM
-ldevS"
AC_MSG_CHECKING
([
libug
$UG_DIM
(
without MPI
)])
LIBS
=
"
$UG_LIBS
"
AC_TRY_LINK
(
[
#define INT int
#include "initug.h"],
[
int i
=
UG
${
UG_DIM
}
d::InitUg
(
0,0
)]
,
[
UG_LDFLAGS
=
"
$LDFLAGS
"
UG_LIBS
=
"
$LIBS
"
HAVE_UG
=
"1
"
AC_MSG_RESULT
(
yes
)
]
,
[
AC_MSG_RESULT
(
no
)
HAVE_UG
=
"0"
]
)
# sequential lib not found/does not work?
if
test
x
$HAVE_UG
!=
x1
&&
test
x
"
$MPI_LDFLAGS
"
!=
x
""
;
then
# try again with added MPI-libs
UG_LIBS
=
"
$UG_LIBS
$MPI_LDFLAGS
"
AC_MSG_CHECKING
([
libug
$UG_DIM
(
with MPI
)])
LIBS
=
"
$UG_LIBS
"
AC_TRY_LINK
(
[
#define INT int
#include "initug.h"],
[
int i
=
UG
${
UG_DIM
}
d::InitUg
(
0,0
)]
,
[
UG_LDFLAGS
=
"
$LDFLAGS
"
HAVE_UG
=
"1"
AC_MSG_RESULT
(
yes
)
]
,
[
AC_MSG_RESULT
(
no
)
HAVE_UG
=
"0"
]
)
fi
fi
AC_LANG_POP
([
C++]
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment