Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
cookbook
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
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
redox-os
cookbook
Commits
f18c0f69
Unverified
Commit
f18c0f69
authored
7 years ago
by
Ian Douglas Scott
Browse files
Options
Downloads
Patches
Plain Diff
Add --debug argument to cook.sh to build in debug mode, unstripped
parent
5f961f88
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!73
Add --debug argument to cook.sh to build in debug mode, unstripped
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
cook.sh
+43
-5
43 additions, 5 deletions
cook.sh
with
43 additions
and
5 deletions
cook.sh
+
43
−
5
View file @
f18c0f69
...
...
@@ -169,10 +169,17 @@ function op {
then
recipe_build
fi
release_flag
=
"--release"
if
[
"
$cargo_build_debug_mode
"
==
1
]
then
release_flag
=
fi
if
[
"
$skip
"
-eq
"0"
]
then
cp
-r
"
$ROOT
/Xargo.toml"
.
xargo build
--target
"
$TARGET
"
--
release
$CARGOFLAGS
xargo build
--target
"
$TARGET
"
$
release
_flag
$CARGOFLAGS
fi
popd
>
/dev/null
;;
...
...
@@ -183,10 +190,17 @@ function op {
then
recipe_test
fi
release_flag
=
"--release"
if
[
"
$cargo_build_debug_mode
"
==
1
]
then
release_flag
=
fi
if
[
"
$skip
"
-eq
"0"
]
then
cp
-r
"
$ROOT
/Xargo.toml"
.
xargo
test
--no-run
--target
"
$TARGET
"
--
release
$CARGOFLAGS
xargo
test
--no-run
--target
"
$TARGET
"
$
release
_flag
$CARGOFLAGS
fi
popd
>
/dev/null
;;
...
...
@@ -215,13 +229,24 @@ function op {
if
[
"
$skip
"
-eq
"0"
]
then
#TODO xargo install --root "../stage" $CARGOFLAGS
bins
=
"
$(
find target/
$TARGET
/release/
-maxdepth
1
-type
f
!
-name
'*.*'
)
"
if
[
"
$cargo_build_debug_mode
"
==
1
]
then
build
=
debug
else
build
=
release
fi
bins
=
"
$(
find target/
$TARGET
/
$build
/
-maxdepth
1
-type
f
!
-name
'*.*'
)
"
if
[
-n
"
$bins
"
]
then
mkdir
-p
"../stage/
$BINDIR
"
for
bin
in
$bins
do
strip
-v
"
$bin
"
-o
"../stage/
$BINDIR
/
$(
basename
$bin
)
"
if
[
"
$cargo_build_debug_mode
"
==
1
]
then
cp
-v
"
$bin
"
"../stage/
$BINDIR
/
$(
basename
$bin
)
"
else
strip
-v
"
$bin
"
-o
"../stage/
$BINDIR
/
$(
basename
$bin
)
"
fi
done
fi
fi
...
...
@@ -262,9 +287,22 @@ then
then
cd
"
$ROOT
/recipes/
$1
"
source
recipe.sh
ops
=()
cargo_build_debug_mode
=
for
arg
in
"
${
@
:2
}
"
do
op
"
$1
"
"
$arg
"
if
[
"
$arg
"
==
"--debug"
]
then
cargo_build_debug_mode
=
1
else
ops[
${#
ops
[@]
}
]=
"
$arg
"
fi
done
for
i
in
"
${
ops
[@]
}
"
do
op
"
$1
"
"
$i
"
done
else
echo
"cook.sh: recipe '
$1
' not found"
>
&2
...
...
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