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
4f283762
Commit
4f283762
authored
11 years ago
by
Markus Blatt
Browse files
Options
Downloads
Patches
Plain Diff
Fixes BUILDDIR variable treatment in opts file.
parent
da269488
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
bin/dunecontrol
+22
-18
22 additions, 18 deletions
bin/dunecontrol
with
22 additions
and
18 deletions
bin/dunecontrol
+
22
−
18
View file @
4f283762
...
...
@@ -163,17 +163,21 @@ load_opts() {
local
COMMAND
=
$(
echo
$command
|
tr
'[:lower:]'
'[:upper:]'
)
CMD_FLAGS
=
"
$(
eval echo
\$
${
COMMAND
}
_FLAGS
)
"
local
CMD_FLAGS_FROM_FILE
=
""
BUILDDIR
=
$DUNE_BUILDDIR
if
test
"x
$DUNE_OPTS_FILE
"
!=
"x"
;
then
if
test
-z
"
$BUILDDIR
"
;
then
# no builddir set yet, use build dir from opts file if set
# Note: if --use-buiddir is used BUILDDIR will be set already
OPTS_FILE_BUILDDIR
=
"
$(
eval
BUILDDIR
=
""
;
.
$DUNE_OPTS_FILE
;
eval echo
\$
BUILDDIR
)
"
if
test
-n
"
$OPTS_FILE_BUILDDIR
"
;
then
BUILDDIR
=
"
$OPTS_FILE_BUILDDIR
"
if
test
"
$command
"
=
"NONE"
;
then
BUILDDIR
=
$DUNE_BUILDDIR
if
test
-z
"
$BUILDDIR
"
;
then
# no builddir set yet, use build dir from opts file if set
# Note: if --use-buiddir is used BUILDDIR will be set already
OPTS_FILE_BUILDDIR
=
"
$(
eval
BUILDDIR
=
""
;
.
$DUNE_OPTS_FILE
;
eval echo
\$
BUILDDIR
)
"
if
test
-n
"
$OPTS_FILE_BUILDDIR
"
;
then
BUILDDIR
=
"
$OPTS_FILE_BUILDDIR
"
fi
fi
fi
CMAKE_FLAGS
=
"
$(
.
$DUNE_OPTS_FILE
;
eval echo
\$
CMAKE_FLAGS
)
"
if
test
"
$command
"
=
"configure"
;
then
CMAKE_FLAGS
=
"
$(
.
$DUNE_OPTS_FILE
;
eval echo
\$
CMAKE_FLAGS
)
"
fi
CMD_FLAGS_FROM_FILE
=
"
$(
eval
${
COMMAND
}
_FLAGS
=
""
;
.
$DUNE_OPTS_FILE
;
eval echo
\$
${
COMMAND
}
_FLAGS
)
"
fi
if
test
-n
"
$CMD_FLAGS_FROM_FILE
"
;
then
...
...
@@ -182,6 +186,14 @@ load_opts() {
elif
test
-n
"
$CMD_FLAGS
"
;
then
echo
"----- using default flags
\$
${
COMMAND
}
_FLAGS from environment -----"
fi
if
test
"x
$USE_CMAKE
"
=
"xyes"
;
then
if
test
-z
"
$BUILDDIR
"
;
then
echo
"No build directory provided. Defaulting to the sub directory build-cmake"
export
BUILDDIR
=
build-cmake
fi
fi
}
###############################################
...
...
@@ -585,6 +597,7 @@ run_default_configure () {
PREPARAMS
=
"
$PREPARAMS
$cflags
"
fi
done
# create build directory if requested
test
-d
"
$BUILDDIR
"
||
mkdir
"
$BUILDDIR
"
SRCDIR
=
"
$PWD
"
cd
"
$BUILDDIR
"
...
...
@@ -593,7 +606,7 @@ run_default_configure () {
else
PARAMS
=
"
$PARAMS
ACLOCAL_AMFLAGS=
\"
$ACLOCAL_FLAGS
\"
"
echo
./configure
"
$PARAMS
"
# create build directory
o
f requested
# create build directory
i
f requested
if
test
-n
"
$BUILDDIR
"
;
then
test
-d
"
$BUILDDIR
"
||
mkdir
"
$BUILDDIR
"
SRCDIR
=
"
$PWD
"
...
...
@@ -886,15 +899,6 @@ while test $# -gt 0; do
shift
done
if
test
"x
$USE_CMAKE
"
=
"xyes"
;
then
# load general options. DUNE_BUILDDIR might be overwritten in the opts file
load_opts NONE
if
test
-z
"
$BUILDDIR
"
;
then
echo
"No build directory provided. Defaulting to the sub directory build-cmake"
export
BUILDDIR
=
build-cmake
fi
fi
# we assume there should be a command...
if
test
"x
$command
"
=
"x"
;
then
usage
...
...
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